From: Janne Grunau <j@jannau.net>
To: Sven Peter <sven@kernel.org>
Cc: Neal Gompa <neal@gompa.dev>,
asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] soc: apple: Fix swapped paddr and size shift
Date: Sun, 8 Nov 2026 15:58:20 +0100 [thread overview]
Message-ID: <20261108145820.GA1462246@robin.jannau.net> (raw)
In-Reply-To: <20261108-b4-sart-fix-v1-1-dab7dc1e9adb@kernel.org>
On Sun, Nov 08, 2026 at 03:35:11PM +0100, Sven Peter wrote:
> Right now we assign the paddr shift to the size shift and vice-versa.
> Luckily, this doesn't matter because they are the same for all SART
> versions but fixing this doesn't hurt.
>
> Fixes: b170143ae111 ("soc: apple: Add SART driver")
> Signed-off-by: Sven Peter <sven@kernel.org>
> ---
> drivers/soc/apple/sart.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/soc/apple/sart.c b/drivers/soc/apple/sart.c
> index 66b99955b395..5f1f9ec5d311 100644
> --- a/drivers/soc/apple/sart.c
> +++ b/drivers/soc/apple/sart.c
> @@ -258,8 +258,8 @@ static int sart_set_entry(struct apple_sart *sart, int index, u8 flags,
> if (paddr & ((1 << sart->ops->paddr_shift) - 1))
> return -EINVAL;
>
> - paddr >>= sart->ops->size_shift;
> - size >>= sart->ops->paddr_shift;
> + paddr >>= sart->ops->paddr_shift;
> + size >>= sart->ops->size_shift;
>
> if (size > sart->ops->size_max)
> return -EINVAL;
Reviewed-by: Janne Grunau <j@jannau.net>
Janne
next prev parent reply other threads:[~2026-11-08 14:58 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-08 14:35 Sven Peter
2026-11-08 14:58 ` Janne Grunau [this message]
2026-11-08 15:07 ` Sven Peter
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=20261108145820.GA1462246@robin.jannau.net \
--to=j@jannau.net \
--cc=asahi@lists.linux.dev \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=neal@gompa.dev \
--cc=sven@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
all inboxes | Powered by JetHome®