diff options
author | Jae Hyun Yoo <jae.hyun.yoo@linux.intel.com> | 2018-07-24 13:36:15 -0700 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2018-08-04 23:12:31 +0200 |
commit | 5799c4b2f1dbc0166d9b1d94443deaafc6e7a070 (patch) | |
tree | ffc5b6398e4ff9bb91e0163631be93580c5065ed /drivers/i2c | |
parent | 2f471d90249551d4b2dab3c7f0527640a3395f2e (diff) | |
download | linux-5799c4b2f1dbc0166d9b1d94443deaafc6e7a070.tar.bz2 |
i2c: aspeed: Add an explicit type casting for *get_clk_reg_val
This commit fixes this sparse warning:
drivers/i2c/busses/i2c-aspeed.c:875:38: warning: incorrect type in assignment (different modifiers)
drivers/i2c/busses/i2c-aspeed.c:875:38: expected unsigned int ( *get_clk_reg_val )( ... )
drivers/i2c/busses/i2c-aspeed.c:875:38: got void const *const data
Reported-by: Wolfram Sang <wsa@the-dreams.de>
Signed-off-by: Jae Hyun Yoo <jae.hyun.yoo@linux.intel.com>
Reviewed-by: Brendan Higgins <brendanhiggins@google.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c')
-rw-r--r-- | drivers/i2c/busses/i2c-aspeed.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/busses/i2c-aspeed.c b/drivers/i2c/busses/i2c-aspeed.c index efb89422d496..a4f956c6d567 100644 --- a/drivers/i2c/busses/i2c-aspeed.c +++ b/drivers/i2c/busses/i2c-aspeed.c @@ -872,7 +872,7 @@ static int aspeed_i2c_probe_bus(struct platform_device *pdev) if (!match) bus->get_clk_reg_val = aspeed_i2c_24xx_get_clk_reg_val; else - bus->get_clk_reg_val = match->data; + bus->get_clk_reg_val = (u32 (*)(u32))match->data; /* Initialize the I2C adapter */ spin_lock_init(&bus->lock); |