[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <7f00d364a5b07ca23f9b5def42df8ab70bb06cfb.camel@mediatek.com>
Date: Sat, 25 Oct 2025 09:18:34 +0000
From: Yong Wu (吴勇) <Yong.Wu@...iatek.com>
To: "joro@...tes.org" <joro@...tes.org>, "will@...nel.org" <will@...nel.org>,
"johan@...nel.org" <johan@...nel.org>
CC: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"j@...nau.net" <j@...nau.net>, "vdumpa@...dia.com" <vdumpa@...dia.com>,
"robin.murphy@....com" <robin.murphy@....com>, "m.szyprowski@...sung.com"
<m.szyprowski@...sung.com>, "wens@...e.org" <wens@...e.org>,
"thierry.reding@...il.com" <thierry.reding@...il.com>,
"iommu@...ts.linux.dev" <iommu@...ts.linux.dev>, "matthias.bgg@...il.com"
<matthias.bgg@...il.com>, "robin.clark@....qualcomm.com"
<robin.clark@....qualcomm.com>, "sven@...nel.org" <sven@...nel.org>,
AngeloGioacchino Del Regno <angelogioacchino.delregno@...labora.com>
Subject: Re: [PATCH v3 07/14] iommu/mediatek: simplify dt parsing error
handling
On Mon, 2025-10-20 at 06:53 +0200, Johan Hovold wrote:
> External email : Please do not click links or open attachments until
> you have verified the sender or the content.
>
>
> As previously documented by commit 26593928564c ("iommu/mediatek: Add
> error path for loop of mm_dts_parse"), the id mapping may not be
> linear
> so the whole larb array needs to be iterated on devicetree parsing
> errors.
>
> Simplify the loop by iterating from index zero while dropping the
> redundant NULL check for consistency with later cleanups.
>
> Also add back the comment which was removed by commit 462e768b55a2
> ("iommu/mediatek: Fix forever loop in error handling") to prevent
> anyone
> from trying to optimise the loop by iterating backwards from 'i'.
>
> Cc: Yong Wu <yong.wu@...iatek.com>
> Acked-by: Robin Murphy <robin.murphy@....com>
> Signed-off-by: Johan Hovold <johan@...nel.org>
Reviewed-by: Yong Wu <yong.wu@...iatek.com>
Powered by blists - more mailing lists