summaryrefslogtreecommitdiffstats
path: root/net/switchdev
diff options
context:
space:
mode:
authorFabien Parent <fparent@baylibre.com>2019-10-18 19:32:13 +0200
committerWolfram Sang <wsa@the-dreams.de>2019-10-24 20:52:11 +0200
commit62931ac2f9015ea38d80494ec37658ab3df6a6d7 (patch)
treeb64a85da8d6439c5c388a039a3077d00589d3c87 /net/switchdev
parent1f0d9cbeec9bb0a1c2013342836f2c9754d6502b (diff)
downloadlinux-62931ac2f9015ea38d80494ec37658ab3df6a6d7.tar.bz2
i2c: mt65xx: fix NULL ptr dereference
Since commit abf4923e97c3 ("i2c: mediatek: disable zero-length transfers for mt8183"), there is a NULL pointer dereference for all the SoCs that don't have any quirk. mtk_i2c_functionality is not checking that the quirks pointer is not NULL before starting to use it. This commit add a call to i2c_check_quirks which will check whether the quirks pointer is set, and if so will check if the IP has the NO_ZERO_LEN quirk. Fixes: abf4923e97c3 ("i2c: mediatek: disable zero-length transfers for mt8183") Signed-off-by: Fabien Parent <fparent@baylibre.com> Reviewed-by: Cengiz Can <cengiz@kernel.wtf> Reviewed-by: Hsin-Yi Wang <hsinyi@chromium.org> Tested-by: Ulrich Hecht <uli@fpond.eu> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'net/switchdev')
0 files changed, 0 insertions, 0 deletions