Re: [PATCH 2/2] Input: edt-ft5x06 - add support for iovcc-supply

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

 



Hi,

On Mon, Jan 11, 2021 at 11:10:16AM +0100, Stephan Gerhold wrote:
> On Mon, Jan 11, 2021 at 10:45:38AM +0100, Marco Felsch wrote:
> > On 21-01-11 10:26, Stephan Gerhold wrote:
> > > On Mon, Jan 11, 2021 at 09:36:12AM +0100, Marco Felsch wrote:
> > > > On 21-01-08 20:23, Stephan Gerhold wrote:
> > > > > diff --git a/drivers/input/touchscreen/edt-ft5x06.c b/drivers/input/touchscreen/edt-ft5x06.c
> > > > > index 2eefbc2485bc..bf2e208112fe 100644
> > > > > --- a/drivers/input/touchscreen/edt-ft5x06.c
> > > > > +++ b/drivers/input/touchscreen/edt-ft5x06.c
> > > > > @@ -103,7 +103,7 @@ struct edt_ft5x06_ts_data {
> > > > >  	struct touchscreen_properties prop;
> > > > >  	u16 num_x;
> > > > >  	u16 num_y;
> > > > > -	struct regulator *vcc;
> > > > > +	struct regulator_bulk_data regulators[2];
> > > > 
> > > > Is there an enabling order we must follow?
> > > > 
> > > 
> > > I don't know, sadly. The datasheets I was able to find do not mention
> > > anything about this; the power-on sequence only includes the VDD line.
> > 
> > I've goolged a bit :)
> > 
> > Check this: https://focuslcds.com/content/FT5X26.pdf, page 12 of 32
> > 
> 
> Thanks! I looked at several datasheets, that's probably one of the few I
> did not look at. :(
> 
> > There it is mentioned that we need to enable it first and add a 10us
> > delay till we can enable the vdd line. So unfortunately the bulk_api
> > can't be used as it is today. Another solution could be to extended the
> > bulk api to respect on/off delays.
> > 
> 
> I think for two regulators like here it's still manageable to
> get/enable/disable/put them separately, so I will just revert the bulk
> API change in v2.
> 

While implementing this I noticed that the power-up sequence in probe()
does not quite seem right. The power-up sequence implemented by Marco in
edt_ft5x06_ts_resume() seems to match the datasheet(s) but in probe() we
enable VCC before doing anything with the reset line.

So before I add the IOVCC regulator I will try to refactor the code a
bit to make this consistent. :)

Thanks,
Stephan



[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