From: Stephen Boyd <sboyd@kernel.org>
To: cuigaosheng <cuigaosheng1@huawei.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH -next] spmi: pmic-arb: Add check for return value of platform_get_resource_byname
Date: Tue, 06 Aug 2024 10:50:44 -0700 [thread overview]
Message-ID: <b34788391df96f39025d2b1ce47e6d26.sboyd@kernel.org> (raw)
In-Reply-To: <921e3180-231d-ff14-32a4-4bd5dbed2f32@huawei.com>
Quoting cuigaosheng (2024-08-06 05:06:40)
> Thanks for your time.
Please don't top post.
>
> I've made and submitted a patch v2, and I think the right fixes tag is
> as follows:
>
> Fixes: 39ae93e3a31d ("spmi: Add MSM PMIC Arbiter SPMI controller")
Don't think so. If the resource isn't there, the pointer returned is
NULL, devm_ioremap_resource() would bail out early if the resource is
NULL and return an error. I suggested that fixes tag because it removed
the size check. But now I see that resource_size() on a NULL pointer
would blow up. So the real fixes tag is
Fixes: 987a9f128b8a ("spmi: pmic-arb: Support more than 128 peripherals")
because that introduced the call to resource_size() on a potentially
NULL pointer.
prev parent reply other threads:[~2024-08-06 17:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-03 6:56 [PATCH -next] spmi: pmic-arb: Add check for return value of platform_get_resource_byname Gaosheng Cui
2024-08-05 21:55 ` Stephen Boyd
2024-08-06 12:06 ` cuigaosheng
2024-08-06 17:50 ` Stephen Boyd [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=b34788391df96f39025d2b1ce47e6d26.sboyd@kernel.org \
--to=sboyd@kernel.org \
--cc=cuigaosheng1@huawei.com \
--cc=linux-kernel@vger.kernel.org \
/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