From: "Rob Herring (Arm)" <robh@kernel.org>
To: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>
Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
Saravana Kannan <saravanak@google.com>
Subject: Re: [PATCH] of: address: Unify resource bounds overflow checking
Date: Fri, 6 Sep 2024 16:34:14 -0500 [thread overview]
Message-ID: <172565841388.2236408.1589932943840066610.robh@kernel.org> (raw)
In-Reply-To: <20240906-of-address-overflow-v1-1-19567aaa61da@linutronix.de>
On Fri, 06 Sep 2024 14:25:19 +0200, Thomas Weißschuh wrote:
> The members "start" and "end" of struct resource are of type
> "resource_size_t" which can be 32bit wide.
> Values read from OF however are always 64bit wide.
>
> Refactor the diff overflow checks into a helper function.
> Also extend the checks to validate each calculation step.
>
> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
> ---
> drivers/of/address.c | 45 ++++++++++++++++++++++++++-------------------
> 1 file changed, 26 insertions(+), 19 deletions(-)
>
Applied, thanks!
next prev parent reply other threads:[~2024-09-06 21:34 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-06 12:25 Thomas Weißschuh
2024-09-06 21:34 ` Rob Herring (Arm) [this message]
2024-09-13 13:15 ` Michael Ellerman
2024-09-13 18:56 ` Rob Herring
2024-09-13 23:10 ` Michael Ellerman
2025-01-08 14:04 ` Basharath Hussain Khaja
2025-01-08 22:43 ` Rob Herring
2025-01-17 6:53 ` Basharath Hussain Khaja
2025-01-17 13:06 ` Thomas Weißschuh
2025-01-20 10:09 ` Basharath Hussain Khaja
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=172565841388.2236408.1589932943840066610.robh@kernel.org \
--to=robh@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=saravanak@google.com \
--cc=thomas.weissschuh@linutronix.de \
/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®