software: kernel: i2c: Use 'idr' instead of 'pdev'
The si570 i2c handler is used only to configure the clock at an early
stage, and never after. Thus, we don't require to save platform related
data of the i2c handler, and only the 'idr' should be enough.
Also because we can't do much with 'struct platform_device' data, but
with 'idr', we can obtain adapter and do data transfer via i2c APIs.
We can always retrieve the 'struct platform_device' data related to this
i2c_handler from its 'idr' if needed, for example in *exit().
Signed-off-by: Vaibhav Gupta <vaibhav.gupta@cern.ch>
Showing
Please
register
or
sign in
to comment