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

2018-02-23 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: 928e9263492069ee ("tty: xuartps: Initialize ports according to aliases") Signed-off-by: Geert Uytterhoeven --- v2: - F

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

2018-02-23 Thread Michal Simek
On 23.2.2018 14:38, 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: 928e9263492069ee ("tty: xuartps: Initialize ports according to