[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <d67b03aa-5f9f-4cc5-adc4-549cc2e71688@mailbox.org>
Date: Mon, 19 Jan 2026 16:03:32 +0100
From: Marek Vasut <marek.vasut@...lbox.org>
To: Geert Uytterhoeven <geert@...ux-m68k.org>
Cc: linux-clk@...r.kernel.org, stable@...r.kernel.org,
Michael Turquette <mturquette@...libre.com>, Stephen Boyd
<sboyd@...nel.org>, linux-kernel@...r.kernel.org,
linux-renesas-soc@...r.kernel.org
Subject: Re: [PATCH] clk: rs9: Reserve 8 struct clk_hw slots for for 9FGV0841
On 1/19/26 2:55 PM, Geert Uytterhoeven wrote:
Hello Geert,
> On Sun, 18 Jan 2026 at 03:58, Marek Vasut
> <marek.vasut+renesas@...lbox.org> wrote:
>> The 9FGV0841 has 8 outputs and registers 8 struct clk_hw, make sure
>> there are 8 slots for those newly registered clk_hw pointers, else
>> there is going to be out of bounds write when pointers 4..7 are set
>> into struct rs9_driver_data .clk_dif[4..7] field.
>>
>> Since there are other structure members past this struct clk_hw
>> pointer array, writing to .clk_dif[4..7] fields only corrupts the
>> struct rs9_driver_data content, without crashing the kernel. However,
>
> I am not sure that is true. As the last 3 fields are just bytes, up to 3
> pointers may be written outside the structure, which is 32 or 64 bytes large.
> So any buffer overflow may corrupt another object from the 32-byte or
> 64-byte slab.
Indeed, updated in V2, thanks.
Powered by blists - more mailing lists