]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
staging: greybus: arche-apb-ctrl: declare struct of_device_id as const
authorEva Rachel Retuya <eraretuya@gmail.com>
Thu, 22 Sep 2016 15:33:33 +0000 (23:33 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 23 Sep 2016 12:11:46 +0000 (14:11 +0200)
Declare the 'arche_apb_ctrl_of_match' array as const. This array is only stored
in the .of_match_table field of a device_driver structure, which is declared as
const. This addresses the checkpatch warning:

WARNING: struct of_device_id should be normally const

Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/greybus/arche-apb-ctrl.c

index 59d9d422cf044d7260ce69e31e73d90f5a62cfa7..70323aa11f243baf831fe9c4510c9a0993ab4f52 100644 (file)
@@ -495,7 +495,7 @@ static void arche_apb_ctrl_shutdown(struct platform_device *pdev)
 static SIMPLE_DEV_PM_OPS(arche_apb_ctrl_pm_ops, arche_apb_ctrl_suspend,
                         arche_apb_ctrl_resume);
 
-static struct of_device_id arche_apb_ctrl_of_match[] = {
+static const struct of_device_id arche_apb_ctrl_of_match[] = {
        { .compatible = "usbffff,2", },
        { },
 };