Message ID | 20170703084003.31184-4-sebastian.reichel@collabora.co.uk (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
On Mon, 03 Jul 2017, Sebastian Reichel wrote: > Add register details an channels definition for using the TSI > registers in the hwmon driver. > > Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk> > --- > include/linux/mfd/da9052/da9052.h | 6 ++++++ > include/linux/mfd/da9052/reg.h | 11 ++++++++++- > 2 files changed, 16 insertions(+), 1 deletion(-) Do other patches in this set depend on this change?
On Mon, 17 Jul 2017, Lee Jones wrote: > On Mon, 03 Jul 2017, Sebastian Reichel wrote: > > > Add register details an channels definition for using the TSI > > registers in the hwmon driver. > > > > Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk> > > --- > > include/linux/mfd/da9052/da9052.h | 6 ++++++ > > include/linux/mfd/da9052/reg.h | 11 ++++++++++- > > 2 files changed, 16 insertions(+), 1 deletion(-) > > Do other patches in this set depend on this change? BTW: For my own reference: Acked-for-MFD-by: Lee Jones <lee.jones@linaro.org>
Hi, On Mon, Jul 17, 2017 at 03:32:45PM +0100, Lee Jones wrote: > On Mon, 03 Jul 2017, Sebastian Reichel wrote: > > > Add register details an channels definition for using the TSI > > registers in the hwmon driver. > > > > Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk> > > --- > > include/linux/mfd/da9052/da9052.h | 6 ++++++ > > include/linux/mfd/da9052/reg.h | 11 ++++++++++- > > 2 files changed, 16 insertions(+), 1 deletion(-) > > Do other patches in this set depend on this change? Patch 6 has a compile-time dependency on 3 (this one) + 5 and a runtime-dependency on patch 4. My proposed merge solution would be an immutable branch for the mfd changes, that can be pulled by hwmon. -- Sebastian
On Mon, 17 Jul 2017, Sebastian Reichel wrote: > Hi, > > On Mon, Jul 17, 2017 at 03:32:45PM +0100, Lee Jones wrote: > > On Mon, 03 Jul 2017, Sebastian Reichel wrote: > > > > > Add register details an channels definition for using the TSI > > > registers in the hwmon driver. > > > > > > Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk> > > > --- > > > include/linux/mfd/da9052/da9052.h | 6 ++++++ > > > include/linux/mfd/da9052/reg.h | 11 ++++++++++- > > > 2 files changed, 16 insertions(+), 1 deletion(-) > > > > Do other patches in this set depend on this change? > > Patch 6 has a compile-time dependency on 3 (this one) + 5 > and a runtime-dependency on patch 4. My proposed merge > solution would be an immutable branch for the mfd changes, > that can be pulled by hwmon. I'm happy to do that. Please fix patch 4 and I'll take them in.
diff --git a/include/linux/mfd/da9052/da9052.h b/include/linux/mfd/da9052/da9052.h index ce9230af09c2..ae5b663836d0 100644 --- a/include/linux/mfd/da9052/da9052.h +++ b/include/linux/mfd/da9052/da9052.h @@ -45,6 +45,12 @@ #define DA9052_ADC_TJUNC 8 #define DA9052_ADC_VBBAT 9 +/* TSI channel has its own 4 channel mux */ +#define DA9052_ADC_TSI_XP 70 +#define DA9052_ADC_TSI_XN 71 +#define DA9052_ADC_TSI_YP 72 +#define DA9052_ADC_TSI_YN 73 + #define DA9052_IRQ_DCIN 0 #define DA9052_IRQ_VBUS 1 #define DA9052_IRQ_DCINREM 2 diff --git a/include/linux/mfd/da9052/reg.h b/include/linux/mfd/da9052/reg.h index 5010f978725c..76780ea8849c 100644 --- a/include/linux/mfd/da9052/reg.h +++ b/include/linux/mfd/da9052/reg.h @@ -690,7 +690,10 @@ /* TSI CONTROL REGISTER B BITS */ #define DA9052_TSICONTB_ADCREF 0X80 #define DA9052_TSICONTB_TSIMAN 0X40 -#define DA9052_TSICONTB_TSIMUX 0X30 +#define DA9052_TSICONTB_TSIMUX_XP 0X00 +#define DA9052_TSICONTB_TSIMUX_YP 0X10 +#define DA9052_TSICONTB_TSIMUX_XN 0X20 +#define DA9052_TSICONTB_TSIMUX_YN 0X30 #define DA9052_TSICONTB_TSISEL3 0X08 #define DA9052_TSICONTB_TSISEL2 0X04 #define DA9052_TSICONTB_TSISEL1 0X02 @@ -705,8 +708,14 @@ /* TSI CO-ORDINATE LSB RESULT REGISTER BITS */ #define DA9052_TSILSB_PENDOWN 0X40 #define DA9052_TSILSB_TSIZL 0X30 +#define DA9052_TSILSB_TSIZL_SHIFT 4 +#define DA9052_TSILSB_TSIZL_BITS 2 #define DA9052_TSILSB_TSIYL 0X0C +#define DA9052_TSILSB_TSIYL_SHIFT 2 +#define DA9052_TSILSB_TSIYL_BITS 2 #define DA9052_TSILSB_TSIXL 0X03 +#define DA9052_TSILSB_TSIXL_SHIFT 0 +#define DA9052_TSILSB_TSIXL_BITS 2 /* TSI Z MEASUREMENT MSB RESULT REGISTER BIT */ #define DA9052_TSIZMSB_TSIZM 0XFF
Add register details an channels definition for using the TSI registers in the hwmon driver. Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk> --- include/linux/mfd/da9052/da9052.h | 6 ++++++ include/linux/mfd/da9052/reg.h | 11 ++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-)