]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
media: davinci: make ccdc_hw_device structures const
authorBhumika Goyal <bhumirks@gmail.com>
Tue, 17 Oct 2017 12:27:25 +0000 (08:27 -0400)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Tue, 31 Oct 2017 11:19:13 +0000 (07:19 -0400)
Make these structures const as they are only getting passed to the
functions vpfe_{register/unregister}_ccdc_device having the argument as
const.

Structures found using Coccinelle and changes done by hand.

Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/platform/davinci/dm355_ccdc.c
drivers/media/platform/davinci/dm644x_ccdc.c
drivers/media/platform/davinci/isif.c

index 6d492dc4c3a9cb0029d16b23eecc86dc3b4db230..89cb3094d7e661ef8633c4ccd194a9f669c91c4a 100644 (file)
@@ -841,7 +841,7 @@ static int ccdc_set_hw_if_params(struct vpfe_hw_if_param *params)
        return 0;
 }
 
-static struct ccdc_hw_device ccdc_hw_dev = {
+static const struct ccdc_hw_device ccdc_hw_dev = {
        .name = "DM355 CCDC",
        .owner = THIS_MODULE,
        .hw_ops = {
index 3b2d8a9317b8d872c894cfa46defd4006096ac59..5fa0a1f325361be537c254eb6394ee364a59639c 100644 (file)
@@ -776,7 +776,7 @@ static void ccdc_restore_context(void)
        regw(ccdc_ctx[CCDC_VP_OUT >> 2], CCDC_VP_OUT);
        regw(ccdc_ctx[CCDC_PCR >> 2], CCDC_PCR);
 }
-static struct ccdc_hw_device ccdc_hw_dev = {
+static const struct ccdc_hw_device ccdc_hw_dev = {
        .name = "DM6446 CCDC",
        .owner = THIS_MODULE,
        .hw_ops = {
index 5813b49391edb086b572d05e34bbd608eccf17ab..d5ff58494c1e141e4c3c0fa3ea256dcbb4dba2fd 100644 (file)
@@ -1000,7 +1000,7 @@ static int isif_close(struct device *device)
        return 0;
 }
 
-static struct ccdc_hw_device isif_hw_dev = {
+static const struct ccdc_hw_device isif_hw_dev = {
        .name = "ISIF",
        .owner = THIS_MODULE,
        .hw_ops = {