Re: [PATCH 9/9] serial: xuartps: Fix out-of-bounds access through DT alias

2018-02-20 Thread Michal Simek
On 20.2.2018 13:27, Geert Uytterhoeven wrote: > Hi Michal, > > On Tue, Feb 20, 2018 at 12:27 PM, Michal Simek > wrote: >> On 20.2.2018 11:38, Geert Uytterhoeven wrote: >>> On Tue, Feb 20, 2018 at 11:22 AM, Michal Simek >>> wrote: On 20.2.2018 10:40, Geert Uytterhoeven wrote: > The cdn

Re: [PATCH 9/9] serial: xuartps: Fix out-of-bounds access through DT alias

2018-02-20 Thread Geert Uytterhoeven
Hi Michal, On Tue, Feb 20, 2018 at 12:27 PM, Michal Simek wrote: > On 20.2.2018 11:38, Geert Uytterhoeven wrote: >> On Tue, Feb 20, 2018 at 11:22 AM, Michal Simek >> wrote: >>> On 20.2.2018 10:40, Geert Uytterhoeven wrote: The cdns_uart_port[] array is indexed using a value derived from th

Re: [PATCH 9/9] serial: xuartps: Fix out-of-bounds access through DT alias

2018-02-20 Thread Michal Simek
On 20.2.2018 11:38, Geert Uytterhoeven wrote: > Hi Michal, > > On Tue, Feb 20, 2018 at 11:22 AM, Michal Simek > wrote: >> On 20.2.2018 10:40, Geert Uytterhoeven wrote: >>> The cdns_uart_port[] array is indexed using a value derived from the >>> "serialN" alias in DT, which may lead to an out-of-

Re: [PATCH 9/9] serial: xuartps: Fix out-of-bounds access through DT alias

2018-02-20 Thread Geert Uytterhoeven
Hi Michal, On Tue, Feb 20, 2018 at 11:22 AM, Michal Simek wrote: > On 20.2.2018 10:40, Geert Uytterhoeven wrote: >> The cdns_uart_port[] array is indexed using a value derived from the >> "serialN" alias in DT, which may lead to an out-of-bounds access. >> >> Fix this by adding a range check. >>

Re: [PATCH 9/9] serial: xuartps: Fix out-of-bounds access through DT alias

2018-02-20 Thread Michal Simek
On 20.2.2018 10:40, Geert Uytterhoeven wrote: > The cdns_uart_port[] array is indexed using a value derived from the > "serialN" alias in DT, which may lead to an out-of-bounds access. > > Fix this by adding a range check. > > Fixes: 1f118c02a1819856 ("serial: xuartps: Fix out-of-bounds access th

[PATCH 9/9] serial: xuartps: Fix out-of-bounds access through DT alias

2018-02-20 Thread Geert Uytterhoeven
The cdns_uart_port[] array is indexed using a value derived from the "serialN" alias in DT, which may lead to an out-of-bounds access. Fix this by adding a range check. Fixes: 1f118c02a1819856 ("serial: xuartps: Fix out-of-bounds access through DT alias") Signed-off-by: Geert Uytterhoeven ---