mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Stanislaw Gruszka <stanislaw.gruszka@linux.intel.com>
To: Arnd Bergmann <arnd@kernel.org>
Cc: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>,
	Oded Gabbay <ogabbay@kernel.org>,
	Jeffrey Hugo <quic_jhugo@quicinc.com>,
	Karol Wachowski <karol.wachowski@linux.intel.com>,
	Arnd Bergmann <arnd@arndb.de>,
	Krystian Pradzynski <krystian.pradzynski@linux.intel.com>,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] accel/ivpu: avoid build failure with CONFIG_PM=n
Date: Mon, 30 Oct 2023 07:05:06 +0100	[thread overview]
Message-ID: <ZT9HkiflwVKnZlzk@linux.intel.com> (raw)
In-Reply-To: <20231027152633.528490-1-arnd@kernel.org>

On Fri, Oct 27, 2023 at 05:26:23PM +0200, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> The usage count of struct dev_pm_info is an implementation detail that
> is only available if CONFIG_PM is enabled, so printing it in a debug message
> causes a build failure in configurations without PM:
> 
> In file included from include/linux/device.h:15,
>                  from include/linux/pci.h:37,
>                  from drivers/accel/ivpu/ivpu_pm.c:8:
> drivers/accel/ivpu/ivpu_pm.c: In function 'ivpu_rpm_get_if_active':
> drivers/accel/ivpu/ivpu_pm.c:254:51: error: 'struct dev_pm_info' has no member named 'usage_count'
>   254 |                  atomic_read(&vdev->drm.dev->power.usage_count));
>       |                                                   ^
> include/linux/dev_printk.h:129:48: note: in definition of macro 'dev_printk'
>   129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
>       |                                                ^~~~~~~~~~~
> drivers/accel/ivpu/ivpu_drv.h:75:17: note: in expansion of macro 'dev_dbg'
>    75 |                 dev_dbg((vdev)->drm.dev, "[%s] " fmt, #type, ##args);          \
>       |                 ^~~~~~~
> drivers/accel/ivpu/ivpu_pm.c:253:9: note: in expansion of macro 'ivpu_dbg'
>   253 |         ivpu_dbg(vdev, RPM, "rpm_get_if_active count %d\n",
>       |         ^~~~~~~~
> 
> The print message does not seem essential, so the easiest workaround is
> to just remove it.
> 
> Fixes: c39dc15191c4 ("accel/ivpu: Read clock rate only if device is up")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Applied to drm-misc-next

Thanks
Stanislaw

           reply	other threads:[~2023-10-30  6:05 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <20231027152633.528490-1-arnd@kernel.org>]

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=ZT9HkiflwVKnZlzk@linux.intel.com \
    --to=stanislaw.gruszka@linux.intel.com \
    --cc=arnd@arndb.de \
    --cc=arnd@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jacek.lawrynowicz@linux.intel.com \
    --cc=karol.wachowski@linux.intel.com \
    --cc=krystian.pradzynski@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ogabbay@kernel.org \
    --cc=quic_jhugo@quicinc.com \
    /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

all inboxes | Powered by JetHome®