Linux ARM-MSM sub-architecture
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@linaro.org>
To: Vikash Garodia <quic_vgarodia@quicinc.com>
Cc: Tang Bin <tangbin@cmss.chinamobile.com>,
	Stanimir Varbanov <stanimir.k.varbanov@gmail.com>,
	Bryan O'Donoghue <bryan.odonoghue@linaro.org>,
	Andy Gross <agross@kernel.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Konrad Dybcio <konrad.dybcio@linaro.org>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org
Subject: Re: [PATCH] Revert "venus: pm_helpers: Fix error check in vcodec_domains_get()"
Date: Mon, 10 Jul 2023 11:30:52 +0300	[thread overview]
Message-ID: <8215b9e5-e7bb-4739-a39e-e7f39efb053b@kadam.mountain> (raw)
In-Reply-To: <73e7c244-02da-a275-f187-751c8d5b9816@quicinc.com>

On Mon, Jul 10, 2023 at 01:48:52PM +0530, Vikash Garodia wrote:
> > This is a video accelerator.  I would expect that it could still work
> > without power management.
> It won't, without those 2 power domains enabled for Venus. Does it work for you
> when you disabled the config ?

I have not tested this, I'm reviewing static checker bugs, as I
explained here:

> >>> This patch is also based on static analysis and review so probably best
> >>> to be cautious.  My guess is that very few people disable CONFIG_PM
> >>> these days so that's why the bug wasn't caught.


> Its better enforced in Kconfig. By allowing NULL for
> dev_pm_domain_attach_by_name does not still indicate that the functionality is
> dependent on CONFIG_PM to be enabled.

The way I'm writing it is the correct way.  I explain this better in
my blog.

https://staticthinking.wordpress.com/2022/08/01/mixing-error-pointers-and-null/

Currently it looks like the Kconfig does not have a dependency on
CONFIG_PM.  If we fix the the Kconfig, but leave the "harmless" bug here
then it will still show up as a static checker warning when COMPILE_TEST
is enabled.

We should just do it in the correct way even after we fix the Kconfig.

regards,
dan carpenter

      reply	other threads:[~2023-07-10  9:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-03 15:30 [PATCH] Revert "venus: pm_helpers: Fix error check in vcodec_domains_get()" Dan Carpenter
2023-07-10  7:29 ` Vikash Garodia
2023-07-10  8:03   ` Dan Carpenter
2023-07-10  8:18     ` Vikash Garodia
2023-07-10  8:30       ` Dan Carpenter [this message]

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=8215b9e5-e7bb-4739-a39e-e7f39efb053b@kadam.mountain \
    --to=dan.carpenter@linaro.org \
    --cc=agross@kernel.org \
    --cc=andersson@kernel.org \
    --cc=bryan.odonoghue@linaro.org \
    --cc=konrad.dybcio@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=quic_vgarodia@quicinc.com \
    --cc=stanimir.k.varbanov@gmail.com \
    --cc=tangbin@cmss.chinamobile.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