]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
memory: ti-aemif: fix a potential NULL-pointer dereference
authorBartosz Golaszewski <bgolaszewski@baylibre.com>
Thu, 6 Sep 2018 12:12:19 +0000 (14:12 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 19 Sep 2018 20:41:23 +0000 (22:41 +0200)
commitce987db2b52fd8ce551bb728f0a865dedff6fc83
treea495f2ec78c619b29e2e58a29c19ff7205b22178
parent8bf0dc8d0a6732339e28add75970b907fd238c59
memory: ti-aemif: fix a potential NULL-pointer dereference

commit 6b45a2b1c0bc2aec84d1c56a1976ca9c8a621ecb upstream.

Platform data pointer may be NULL. We check it everywhere but in one
place. Fix it.

Fixes: 8af70cd2ca50 ("memory: aemif: add support for board files")
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Cc: stable@vger.kernel.org
Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/memory/ti-aemif.c