i2c: versatile: Make i2c_algo_bit_data const
authorBhumika Goyal <bhumirks@gmail.com>
Mon, 21 Aug 2017 13:28:37 +0000 (18:58 +0530)
committerWolfram Sang <wsa@the-dreams.de>
Tue, 29 Aug 2017 20:34:12 +0000 (22:34 +0200)
Make this const as it is only used in a copy operation.
Done using Coccinelle.

Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-versatile.c

index c73d2d22009eb098549d3f3f278c559949e6b921..f1ab2a637ec004037b01ea5f1613675716fd0f78 100644 (file)
@@ -55,7 +55,7 @@ static int i2c_versatile_getscl(void *data)
        return !!(readl(i2c->base + I2C_CONTROL) & SCL);
 }
 
-static struct i2c_algo_bit_data i2c_versatile_algo = {
+static const struct i2c_algo_bit_data i2c_versatile_algo = {
        .setsda = i2c_versatile_setsda,
        .setscl = i2c_versatile_setscl,
        .getsda = i2c_versatile_getsda,