Messages in this thread | | | Subject | Re: [PATCH v5 7/8] i2c: iproc: add NIC I2C support | From | Ray Jui <> | Date | Tue, 2 Apr 2019 18:10:52 -0700 |
| |
On 4/2/2019 10:57 AM, Ray Jui wrote: > > > On 4/2/2019 3:27 AM, Wolfram Sang wrote:
[...]
>>> + iproc_i2c->type = >>> + (enum bcm_iproc_i2c_type) of_device_get_match_data(&pdev->dev); >> >> No need to cast a void*. >>
In fact, we do need to type cast here since 'iproc_i2c->type' is NOT a pointer:
drivers/i2c/busses/i2c-bcm-iproc.c:870:18: error: incompatible types when assigning to type ‘enum bcm_iproc_i2c_type’ from type ‘const void *’ iproc_i2c->type = of_device_get_match_data(&pdev->dev); ^ > > Yes will fix. > > Thanks, > > Ray >
| |