]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: dw_mmc: Fix out-of-bounds access for slot's caps
authorShawn Lin <shawn.lin@rock-chips.com>
Sat, 24 Feb 2018 06:17:23 +0000 (14:17 +0800)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 27 Feb 2018 14:12:25 +0000 (15:12 +0100)
commit8718f22eb5e4b093c4b3bf2ce44b70eca4348963
tree7f732b668625b722255a00f1e8da4a20143e7274
parent59b02d62a50bead3bfd63e8e22fa460f54570f3c
mmc: dw_mmc: Fix out-of-bounds access for slot's caps

Add num_caps field for dw_mci_drv_data to validate the controller
id from DT alias and non-DT ways.

Reported-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Fixes: 4b7c9950e8bf ("mmc: dw_mmc: add support for implementation specific callbacks")
Cc: <stable@vger.kernel.org>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/dw_mmc-exynos.c
drivers/mmc/host/dw_mmc-k3.c
drivers/mmc/host/dw_mmc-rockchip.c
drivers/mmc/host/dw_mmc-zx.c
drivers/mmc/host/dw_mmc.c
drivers/mmc/host/dw_mmc.h