summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorCorentin Labbe <clabbe@baylibre.com>2020-09-25 21:30:25 +0300
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2020-10-01 10:37:37 +0300
commit62d297ede7d02e3967c2b97ff96c5e1874e5fe14 (patch)
tree143adcf0fbe144caaa5d77226cadee6fb215ce58 /drivers
parente2b35ed6affc1183b03adf18ce24bdb5546071fd (diff)
downloadlinux-62d297ede7d02e3967c2b97ff96c5e1874e5fe14.tar.xz
media: zoran: do not print random guest 0
The slot 0 of guest is never initialized and so we print later random data. Signed-off-by: Corentin Labbe <clabbe@baylibre.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/media/zoran/zoran_device.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/staging/media/zoran/zoran_device.c b/drivers/staging/media/zoran/zoran_device.c
index 04ba22a915f0..dfc2551f2d71 100644
--- a/drivers/staging/media/zoran/zoran_device.c
+++ b/drivers/staging/media/zoran/zoran_device.c
@@ -158,6 +158,9 @@ static void dump_guests(struct zoran *zr)
if (zr36067_debug > 2) {
int i, guest[8];
+ /* do not print random data */
+ guest[0] = 0;
+
for (i = 1; i < 8; i++) /* Don't read jpeg codec here */
guest[i] = post_office_read(zr, i, 0);
@@ -170,6 +173,10 @@ void detect_guest_activity(struct zoran *zr)
int timeout, i, j, res, guest[8], guest0[8], change[8][3];
ktime_t t0, t1;
+ /* do not print random data */
+ guest[0] = 0;
+ guest0[0] = 0;
+
dump_guests(zr);
pci_info(zr->pci_dev, "Detecting guests activity, please wait...\n");
for (i = 1; i < 8; i++) /* Don't read jpeg codec here */