Skip to contentSkip to conversation

staging: gdm724x: constify tty_port_operations structs

PATCH New Aya Mahfouz 1 participant 1 message Dec 14, 2015 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: gdm724x: constify tty_port_operations structs

Constifies tty_port_operations structure in the tty code of the gdm724x driver since it is not modified after its initialization.

Detected and found using Coccinelle.

---
 drivers/staging/gdm724x/gdm_tty.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/gdm724x/gdm_tty.c +1 -1
index e2c0f22..eb7e252 100644
@@ -64,7 +64,7 @@ static void gdm_port_destruct(struct tty_port *port)
 	kfree(gdm);
 }
 
-static struct tty_port_operations gdm_port_ops = {
+static const struct tty_port_operations gdm_port_ops = {
 	.destruct = gdm_port_destruct,
 };
 
Signature · 6 lines
2.4.3


-- 
Kind Regards,
Aya Saif El-yazal Mahfouz