Skip to contentSkip to conversation

media: firewire: Make structure fdtv_ca constant

PATCH New Nishka Dasgupta 1 participant 1 message Aug 19, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 media: firewire: Make structure fdtv_ca constant

Static structure fdtv_ca, of type dvb_device, is only used when it is passed as the third argument to function dvb_register_device(). However, in the definition of dvb_register_device, the third parameter is declared as constant. Hence make fdtv_ca const as well. Issue found with Coccinelle.

---
 drivers/media/firewire/firedtv-ci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/firewire/firedtv-ci.c +1 -1
index a960a0ce9deb..9363d005e2b6 100644
@@ -217,7 +217,7 @@ static const struct file_operations fdtv_ca_fops = {
 	.llseek		= noop_llseek,
 };
 
-static struct dvb_device fdtv_ca = {
+static const struct dvb_device fdtv_ca = {
 	.users		= 1,
 	.readers	= 1,
 	.writers	= 1,
Signature · 1 line
2.19.1