Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

MIPS: Alchemy: Fix an out-of-bound access in db1550_dev_setup()

When calling spi_register_board_info(),

Fixes: f869d42e580f ("MIPS: Alchemy: Improved DB1550 support, with audio and serial busses.")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>

authored by

Christophe JAILLET and committed by
Thomas Bogendoerfer
3c1e5abc 89c4b588

+1 -1
+1 -1
arch/mips/alchemy/devboards/db1550.c
··· 589 589 i2c_register_board_info(0, db1550_i2c_devs, 590 590 ARRAY_SIZE(db1550_i2c_devs)); 591 591 spi_register_board_info(db1550_spi_devs, 592 - ARRAY_SIZE(db1550_i2c_devs)); 592 + ARRAY_SIZE(db1550_spi_devs)); 593 593 594 594 c = clk_get(NULL, "psc0_intclk"); 595 595 if (!IS_ERR(c)) {