Re: [PATCH v5 7/8] i2c: iproc: add NIC I2C support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




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
> 



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux