diff options
author | Gabor Juhos <juhosg@freemail.hu> | 2017-12-13 20:31:50 +0100 |
---|---|---|
committer | John Crispin <john@phrozen.org> | 2017-12-15 23:57:41 +0100 |
commit | 2ecc4131077b26ed8b95b88dea870b1f3a9444c2 (patch) | |
tree | c1470be1b05f52ae559b159f9908ff551dbd0dc8 /config | |
parent | c13b4ef2c8a796fb1d1fb95e2ab5185a69479b22 (diff) | |
download | upstream-2ecc4131077b26ed8b95b88dea870b1f3a9444c2.tar.gz upstream-2ecc4131077b26ed8b95b88dea870b1f3a9444c2.tar.bz2 upstream-2ecc4131077b26ed8b95b88dea870b1f3a9444c2.zip |
ar71xx: fix invalid pointer dereference in c60_nand_scan_fixup()
Since Linux 4.6, mtd->priv no longer points to the NAND specific
structure. Under 4.9 it contains NULL, thus using it to access
the fields of the nand_chip structure causes an invalid pointer
dereference.
Update the code to use the mtd_to_nand() helper under 4.9 to obtain
the address of the chip specific data.
Compile tested only.
Fixes: 7bbf4117c6fe ("ar71xx: Add kernel 4.9 support")
Signed-off-by: Gabor Juhos <juhosg@freemail.hu>
Tested-by: Christian Lamparter <chunkeey@gmail.com>
Diffstat (limited to 'config')
0 files changed, 0 insertions, 0 deletions