From: Arnd Bergmann <arnd@arndb.de>
To: Rob Clark <robdclark@gmail.com>, Sean Paul <sean@poorly.run>,
David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>,
Jordan Crouse <jcrouse@codeaurora.org>
Cc: Rob Clark <robdclark@chromium.org>, Arnd Bergmann <arnd@arndb.de>,
linux-arm-msm@vger.kernel.org,
"Kristian H. Kristensen" <hoegsberg@gmail.com>,
linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org,
Bjorn Andersson <bjorn.andersson@linaro.org>,
freedreno@lists.freedesktop.org,
Allison Randal <allison@lohutok.net>
Subject: [PATCH] drm/msm: fix link error without CONFIG_DEBUG_FS
Date: Wed, 8 Apr 2020 21:14:22 +0200 [thread overview]
Message-ID: <20200408191458.1260397-1-arnd@arndb.de> (raw)
I ran into a randconfig link error with debugfs disabled:
arm-linux-gnueabi-ld:
drivers/gpu/drm/msm/msm_gpu.o: in function `should_dump': msm_gpu.c:(.text+0x1cc): undefined reference to `rd_full'
Change the helper to only look at this variable if debugfs is present.
Fixes: e515af8d4a6f ("drm/msm: devcoredump should dump MSM_SUBMIT_BO_DUMP buffers")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/gpu/drm/msm/msm_gem.h | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/msm/msm_gem.h b/drivers/gpu/drm/msm/msm_gem.h
index 30584eaf8cc8..eb4aeaf291ea 100644
--- a/drivers/gpu/drm/msm/msm_gem.h
+++ b/drivers/gpu/drm/msm/msm_gem.h
@@ -167,7 +167,10 @@ static inline bool
should_dump(struct msm_gem_submit *submit, int idx)
{
extern bool rd_full;
- return rd_full || (submit->bos[idx].flags & MSM_SUBMIT_BO_DUMP);
+ if (IS_ENABLED(CONFIG_DEBUG_FS) && rd_full)
+ return true;
+
+ return submit->bos[idx].flags & MSM_SUBMIT_BO_DUMP;
}
#endif /* __MSM_GEM_H__ */
--
2.26.0
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next reply other threads:[~2020-04-08 19:15 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-08 19:14 Arnd Bergmann [this message]
2020-05-05 8:27 ` [PATCH] drm/msm: fix link error without CONFIG_DEBUG_FS Linus Walleij
2020-06-09 12:48 ` Linus Walleij
2020-06-09 14:04 ` Rob Clark
2020-06-09 19:53 ` Linus Walleij
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200408191458.1260397-1-arnd@arndb.de \
--to=arnd@arndb.de \
--cc=airlied@linux.ie \
--cc=allison@lohutok.net \
--cc=bjorn.andersson@linaro.org \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=hoegsberg@gmail.com \
--cc=jcrouse@codeaurora.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robdclark@chromium.org \
--cc=robdclark@gmail.com \
--cc=sean@poorly.run \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).