Messages in this thread | | | Date | Fri, 14 Feb 2014 15:00:43 -0800 | From | Christopher Heiny <> | Subject | Re: [PATCH 03/11] Input: synaptics-rmi4 - do not update configuration in rmi_f01_probe() |
| |
On 02/13/2014 01:54 PM, Dmitry Torokhov wrote: > On Thu, Feb 13, 2014 at 11:23:44AM -0800, Christopher Heiny wrote: >> >On 02/12/2014 09:27 PM, Dmitry Torokhov wrote: >>> > >Do not write configuration data in probe(), we have config() for that. >> > >> >Then we should call config() in rmi_function_probe() to ensure that >> >any platform data or device tree configuration settings get written >> >to the device. > > Well, yes, we may elect to update device configuration in probe, but > then we should not be doing that 2nd time in ->config(). We shoudl pick > either one or another.
But as the code currently stands, config() is only called when a device reset is detected, not during initialization. So if there's platform specific configuration data that needs to be written to a function, it won't get written until after a device reset occurs, which might never happen. So either we need to write that data (or call config()) in each function's probe(), or in rmi_function_probe().
| |