* re: [PATCH] v4l: 790: added support for terratec cinergy 250 usb
@ 2016-04-21 10:11 Dan Carpenter
0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2016-04-21 10:11 UTC (permalink / raw)
To: mrechberger; +Cc: linux-media
Hello Markus Rechberger,
The patch e43f14af1439: "[PATCH] v4l: 790: added support for terratec
cinergy 250 usb" from Nov 8, 2005, leads to the following static
checker warning:
drivers/media/usb/em28xx/em28xx-input.c:307 em28xx_i2c_ir_handle_key()
error: uninitialized symbol 'protocol'.
drivers/media/usb/em28xx/em28xx-input.c
84 static int em28xx_get_key_terratec(struct i2c_client *i2c_dev,
85 enum rc_type *protocol, u32 *scancode)
86 {
87 unsigned char b;
88
89 /* poll IR chip */
90 if (1 != i2c_master_recv(i2c_dev, &b, 1))
91 return -EIO;
92
93 /* it seems that 0xFE indicates that a button is still hold
94 down, while 0xff indicates that no button is hold down. */
95
96 if (b == 0xff)
97 return 0;
98
99 if (b == 0xfe)
100 /* keep old data */
101 return 1;
This is only called from em28xx_i2c_ir_handle_key() and the "old data"
is uninitialized garbage.
102
103 *protocol = RC_TYPE_UNKNOWN;
104 *scancode = b;
105 return 1;
106 }
regards,
dan carpenter
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-04-21 10:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-21 10:11 [PATCH] v4l: 790: added support for terratec cinergy 250 usb Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).