Skip to contentSkip to conversation

media: stv0900_core: remove redundant assignment to variable val

PATCH New Colin King 1 participant 1 message Apr 25, 2020

Subsystems (2)
lore
Share & tools
lore

Colin King

author
#0 lore raw

PATCH 1/1 media: stv0900_core: remove redundant assignment to variable val

From: Colin Ian King <[email protected]>

The variable val is being initializeed with a value that is never read and it is being updated later with a new value. The initialization is redundant and can be removed.

Addresses-Coverity: ("Unused value")

---
 drivers/media/dvb-frontends/stv0900_core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/dvb-frontends/stv0900_core.c +1 -1
index 7d93a1617e86..212312d20ff6 100644
@@ -193,7 +193,7 @@ void stv0900_write_bits(struct stv0900_internal *intp, u32 label, u8 val)
 
 u8 stv0900_get_bits(struct stv0900_internal *intp, u32 label)
 {
-	u8 val = 0xff;
+	u8 val;
 	u8 mask, pos;
 
 	extract_mask_pos(label, &mask, &pos);
Signature · 1 line
2.25.1