]> rtime.felk.cvut.cz Git - sojka/nv-tegra/linux-3.10.git/commit
video: host: vi: only do host1x_writel for vi.0
authorBryan Wu <pengw@nvidia.com>
Wed, 18 Dec 2013 19:21:11 +0000 (11:21 -0800)
committerTerje Bergstrom <tbergstrom@nvidia.com>
Thu, 19 Dec 2013 06:32:21 +0000 (22:32 -0800)
commite972e1b2e1ae60ec7ecef5e633e91ee95b0defa9
treeaf9fbfedaaceab3214e71a233eec1d137d6617a2
parent920d1b33e005f1924df542cef5333b7ca27cb4e1
video: host: vi: only do host1x_writel for vi.0

During module removing, vi.0 device will release the whole resources
and set aperture[0] to NULL. Then vi.1 device will try to call
host1x_writel(), which will access the master device vi.0's aperture.
This will cause kernel oops with NULL pointer access.

This patch will check the device id, only do the host1x_writel()
operation for vi.0.

Bug 1421146

Change-Id: I182b59063460900a3c747a9b4c7a93845a43d8ae
Signed-off-by: Bryan Wu <pengw@nvidia.com>
Reviewed-on: http://git-master/r/347133
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Jihoon Bang <jbang@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
drivers/video/tegra/host/vi/tegra_vi.c