mailbox: hi3660: constify mbox_chan_ops structure
authorJulia Lawall <Julia.Lawall@lip6.fr>
Fri, 2 Nov 2018 15:11:55 +0000 (16:11 +0100)
committerJassi Brar <jaswinder.singh@linaro.org>
Wed, 12 Dec 2018 02:29:40 +0000 (07:59 +0530)
The mbox_chan_ops structure can be const as it is only stored in the
ops field of an mbox_controller structure and this field is const.

Done with the help of Coccinelle.

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org>
drivers/mailbox/hi3660-mailbox.c

index 3eea6b6424841ad16a726382045a5e19fe8be0d0..c3fd1f2b797f43d5836b045de4325511f8d2ecf4 100644 (file)
@@ -206,7 +206,7 @@ static int hi3660_mbox_send_data(struct mbox_chan *chan, void *msg)
        return 0;
 }
 
-static struct mbox_chan_ops hi3660_mbox_ops = {
+static const struct mbox_chan_ops hi3660_mbox_ops = {
        .startup        = hi3660_mbox_startup,
        .send_data      = hi3660_mbox_send_data,
 };