diff for duplicates of <1520923865.3766.4.camel@intel.com> diff --git a/a/1.txt b/N1/1.txt index 442d5f3..ab05489 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -1,9 +1,9 @@ yeah, will review it and get back to you later. -On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: +On ?, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > Ping... > -> @rui.zhang@intel.com, can you help review this patch? +> @rui.zhang at intel.com, can you help review this patch? > > Anson Huang > Best Regards! @@ -11,18 +11,18 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > > > > -----Original Message----- -> > From: linux-arm-kernel [mailto:linux-arm-kernel-bounces@lists.infra +> > From: linux-arm-kernel [mailto:linux-arm-kernel-bounces at lists.infra > > dead.org] > > On Behalf Of Anson Huang > > Sent: Friday, March 2, 2018 10:00 AM -> > To: Leonard Crestez <leonard.crestez@nxp.com>; rui.zhang@intel.com; -> > edubezval@gmail.com; robh+dt@kernel.org; mark.rutland@arm.com; -> > shawnguo@kernel.org; kernel@pengutronix.de; Fabio Estevam -> > <fabio.estevam@nxp.com>; linux@armlinux.org.uk -> > Cc: linux-arm-kernel@lists.infradead.org; devicetree@vger.kernel.or +> > To: Leonard Crestez <leonard.crestez@nxp.com>; rui.zhang at intel.com; +> > edubezval at gmail.com; robh+dt at kernel.org; mark.rutland at arm.com; +> > shawnguo at kernel.org; kernel at pengutronix.de; Fabio Estevam +> > <fabio.estevam@nxp.com>; linux at armlinux.org.uk +> > Cc: linux-arm-kernel at lists.infradead.org; devicetree at vger.kernel.or > > g; -> > dl-linux-imx <linux-imx@nxp.com>; linux-kernel@vger.kernel.org; -> > linux-pm@vger.kernel.org +> > dl-linux-imx <linux-imx@nxp.com>; linux-kernel at vger.kernel.org; +> > linux-pm at vger.kernel.org > > Subject: [PATCH V6 2/2] thermal: imx: add i.MX7 thermal sensor > > support > > @@ -47,10 +47,10 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > --- > > changes since V5: > > no code change, just add Reviewed-by. -> > .../devicetree/bindings/thermal/imx-thermal.txt | 9 +- -> > drivers/thermal/imx_thermal.c | 295 +> > ?.../devicetree/bindings/thermal/imx-thermal.txt????|???9 +- +> > ?drivers/thermal/imx_thermal.c??????????????????????| 295 > > ++++++++++++++++----- -> > 2 files changed, 239 insertions(+), 65 deletions(-) +> > ?2 files changed, 239 insertions(+), 65 deletions(-) > > > > diff --git a/Documentation/devicetree/bindings/thermal/imx- > > thermal.txt @@ -59,32 +59,32 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > --- a/Documentation/devicetree/bindings/thermal/imx-thermal.txt > > +++ b/Documentation/devicetree/bindings/thermal/imx-thermal.txt > > @@ -1,8 +1,13 @@ -> > * Temperature Monitor (TEMPMON) on Freescale i.MX SoCs +> > ?* Temperature Monitor (TEMPMON) on Freescale i.MX SoCs > > -> > Required properties: +> > ?Required properties: > > -- compatible : "fsl,imx6q-tempmon" for i.MX6Q, "fsl,imx6sx- > > tempmon" for > > i.MX6SX. -> > - i.MX6SX has two more IRQs than i.MX6Q, one is IRQ_LOW and the +> > -??i.MX6SX has two more IRQs than i.MX6Q, one is IRQ_LOW and the > > other is > > IRQ_PANIC, > > +- compatible : must be one of following: -> > + - "fsl,imx6q-tempmon" for i.MX6Q, -> > + - "fsl,imx6sx-tempmon" for i.MX6SX, -> > + - "fsl,imx7d-tempmon" for i.MX7S/D. +> > +??- "fsl,imx6q-tempmon" for i.MX6Q, +> > +??- "fsl,imx6sx-tempmon" for i.MX6SX, +> > +??- "fsl,imx7d-tempmon" for i.MX7S/D. > > +- interrupts : the interrupt output of the controller: -> > + i.MX6Q has one IRQ which will be triggered when temperature is +> > +??i.MX6Q has one IRQ which will be triggered when temperature is > > higher > > +than high threshold, -> > + i.MX6SX and i.MX7S/D have two more IRQs than i.MX6Q, one is +> > +??i.MX6SX and i.MX7S/D have two more IRQs than i.MX6Q, one is > > IRQ_LOW > > +and the other is IRQ_PANIC, -> > when temperature is below than low threshold, IRQ_LOW will be +> > ???when temperature is below than low threshold, IRQ_LOW will be > > triggered, > > when temperature -> > is higher than panic threshold, system will auto reboot by SRC +> > ???is higher than panic threshold, system will auto reboot by SRC > > module. -> > - fsl,tempmon : phandle pointer to system controller that contains +> > ?- fsl,tempmon : phandle pointer to system controller that contains > > TEMPMON > > diff --git a/drivers/thermal/imx_thermal.c > > b/drivers/thermal/imx_thermal.c @@ -92,8 +92,8 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > --- a/drivers/thermal/imx_thermal.c > > +++ b/drivers/thermal/imx_thermal.c > > @@ -31,35 +31,57 @@ -> > #define REG_CLR 0x8 -> > #define REG_TOG 0xc +> > ?#define REG_CLR 0x8 +> > ?#define REG_TOG 0xc > > > > -#define MISC0 0x0150 > > -#define MISC0_REFTOP_SELBIASOFF (1 << 3) @@ -104,7 +104,7 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > +#define IMX6_MISC0_REFTOP_SELBIASOFF (1 << 3) > > +#define IMX6_MISC1 0x0160 > > +#define IMX6_MISC1_IRQ_TEMPHIGH (1 << 29) -> > /* Below LOW and PANIC bits are only for TEMPMON_IMX6SX */ +> > ?/* Below LOW and PANIC bits are only for TEMPMON_IMX6SX */ > > -#define MISC1_IRQ_TEMPLOW (1 << 28) > > -#define MISC1_IRQ_TEMPPANIC (1 << 27) > > - @@ -143,8 +143,8 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > +#define IMX6_TEMPSENSE1_MEASURE_FREQ 0xffff > > +#define IMX6_TEMPSENSE1_MEASURE_FREQ_SHIFT 0 > > -> > #define OCOTP_MEM0 0x0480 -> > #define OCOTP_ANA1 0x04e0 +> > ?#define OCOTP_MEM0 0x0480 +> > ?#define OCOTP_ANA1 0x04e0 > > > > +/* Below TEMPSENSE2 is only for TEMPMON_IMX6SX */ > > +#define IMX6_TEMPSENSE2 0x0290 @@ -173,18 +173,18 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > +#define IMX7_TEMPSENSE1_TEMP_VALUE_SHIFT 0 > > +#define IMX7_TEMPSENSE1_TEMP_VALUE_MASK 0x1ff > > + -> > /* The driver supports 1 passive trip point and 1 critical trip -> > point */ enum +> > ?/* The driver supports 1 passive trip point and 1 critical trip +> > point */??enum > > imx_thermal_trip { -> > IMX_TRIP_PASSIVE, +> > ? IMX_TRIP_PASSIVE, > > @@ -72,17 +94,114 @@ enum imx_thermal_trip { > > -> > #define TEMPMON_IMX6Q 1 -> > #define TEMPMON_IMX6SX 2 +> > ?#define TEMPMON_IMX6Q 1 +> > ?#define TEMPMON_IMX6SX 2 > > +#define TEMPMON_IMX7D 3 > > -> > struct thermal_soc_data { -> > u32 version; +> > ?struct thermal_soc_data { +> > ? u32 version; > > + > > + u32 sensor_ctrl; > > + u32 power_down_mask; @@ -210,10 +210,10 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > + u32 low_alarm_ctrl; > > + u32 low_alarm_mask; > > + u32 low_alarm_shift; -> > }; +> > ?}; > > -> > static struct thermal_soc_data thermal_imx6q_data = { -> > .version = TEMPMON_IMX6Q, +> > ?static struct thermal_soc_data thermal_imx6q_data = { +> > ? .version = TEMPMON_IMX6Q, > > + > > + .sensor_ctrl = IMX6_TEMPSENSE0, > > + .power_down_mask = IMX6_TEMPSENSE0_POWER_DOWN, @@ -231,10 +231,10 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > + .high_alarm_ctrl = IMX6_TEMPSENSE0, > > + .high_alarm_mask = IMX6_TEMPSENSE0_ALARM_VALUE_MASK, > > + .high_alarm_shift = IMX6_TEMPSENSE0_ALARM_VALUE_SHIFT, -> > }; +> > ?}; > > -> > static struct thermal_soc_data thermal_imx6sx_data = { -> > .version = TEMPMON_IMX6SX, +> > ?static struct thermal_soc_data thermal_imx6sx_data = { +> > ? .version = TEMPMON_IMX6SX, > > + > > + .sensor_ctrl = IMX6_TEMPSENSE0, > > + .power_down_mask = IMX6_TEMPSENSE0_POWER_DOWN, @@ -288,38 +288,38 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > + .low_alarm_ctrl = IMX7_TEMPSENSE0, > > + .low_alarm_mask = IMX7_TEMPSENSE0_LOW_ALARM_MASK, > > + .low_alarm_shift = IMX7_TEMPSENSE0_LOW_ALARM_SHIFT, -> > }; +> > ?}; > > -> > struct imx_thermal_data { -> > @@ -107,31 +226,42 @@ struct imx_thermal_data { static void +> > ?struct imx_thermal_data { +> > @@ -107,31 +226,42 @@ struct imx_thermal_data {??static void > > imx_set_panic_temp(struct imx_thermal_data *data, -> > int panic_temp) -> > { +> > ? ???????int panic_temp) +> > ?{ > > + const struct thermal_soc_data *soc_data = data->socdata; -> > struct regmap *map = data->tempmon; -> > int critical_value; +> > ? struct regmap *map = data->tempmon; +> > ? int critical_value; > > -> > critical_value = (data->c2 - panic_temp) / data->c1; +> > ? critical_value = (data->c2 - panic_temp) / data->c1; > > - regmap_write(map, TEMPSENSE2 + REG_CLR, > > TEMPSENSE2_PANIC_VALUE_MASK); > > - regmap_write(map, TEMPSENSE2 + REG_SET, critical_value << > > - TEMPSENSE2_PANIC_VALUE_SHIFT); > > + > > + regmap_write(map, soc_data->panic_alarm_ctrl + REG_CLR, -> > + soc_data->panic_alarm_mask); +> > + ?????soc_data->panic_alarm_mask); > > + regmap_write(map, soc_data->panic_alarm_ctrl + REG_SET, -> > + critical_value << soc_data- +> > + ?????critical_value << soc_data- > > >panic_alarm_shift); -> > } +> > ?} > > -> > static void imx_set_alarm_temp(struct imx_thermal_data *data, -> > int alarm_temp) -> > { -> > struct regmap *map = data->tempmon; +> > ?static void imx_set_alarm_temp(struct imx_thermal_data *data, +> > ? ???????int alarm_temp) +> > ?{ +> > ? struct regmap *map = data->tempmon; > > + const struct thermal_soc_data *soc_data = data->socdata; -> > int alarm_value; +> > ? int alarm_value; > > -> > data->alarm_temp = alarm_temp; +> > ? data->alarm_temp = alarm_temp; > > - alarm_value = (data->c2 - alarm_temp) / data->c1; > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_ALARM_VALUE_MASK); @@ -332,166 +332,166 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > + alarm_value = (data->c2 - alarm_temp) / data->c1; > > + > > + regmap_write(map, soc_data->high_alarm_ctrl + REG_CLR, -> > + soc_data->high_alarm_mask); +> > + ?????soc_data->high_alarm_mask); > > + regmap_write(map, soc_data->high_alarm_ctrl + REG_SET, -> > + alarm_value << soc_data->high_alarm_shift); -> > } +> > + ?????alarm_value << soc_data->high_alarm_shift); +> > ?} > > -> > static int imx_get_temp(struct thermal_zone_device *tz, int -> > *temp) { -> > struct imx_thermal_data *data = tz->devdata; +> > ?static int imx_get_temp(struct thermal_zone_device *tz, int +> > *temp)??{ +> > ? struct imx_thermal_data *data = tz->devdata; > > + const struct thermal_soc_data *soc_data = data->socdata; -> > struct regmap *map = data->tempmon; -> > unsigned int n_meas; -> > bool wait; +> > ? struct regmap *map = data->tempmon; +> > ? unsigned int n_meas; +> > ? bool wait; > > @@ -139,16 +269,18 @@ static int imx_get_temp(struct > > thermal_zone_device > > *tz, int *temp) > > -> > if (data->mode == THERMAL_DEVICE_ENABLED) { -> > /* Check if a measurement is currently in progress +> > ? if (data->mode == THERMAL_DEVICE_ENABLED) { +> > ? /* Check if a measurement is currently in progress > > */ > > - regmap_read(map, TEMPSENSE0, &val); > > - wait = !(val & TEMPSENSE0_FINISHED); > > + regmap_read(map, soc_data->temp_data, &val); > > + wait = !(val & soc_data->temp_valid_mask); -> > } else { -> > /* -> > * Every time we measure the temperature, we will +> > ? } else { +> > ? /* +> > ? ?* Every time we measure the temperature, we will > > power on the -> > * temperature sensor, enable measurements, take a +> > ? ?* temperature sensor, enable measurements, take a > > reading, -> > * disable measurements, power off the temperature +> > ? ?* disable measurements, power off the temperature > > sensor. -> > */ +> > ? ?*/ > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_POWER_DOWN); > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_MEASURE_TEMP); > > + regmap_write(map, soc_data->sensor_ctrl + REG_CLR, -> > + soc_data->power_down_mask); +> > + ????soc_data->power_down_mask); > > + regmap_write(map, soc_data->sensor_ctrl + REG_SET, -> > + soc_data->measure_temp_mask); +> > + ????soc_data->measure_temp_mask); > > -> > wait = true; -> > } +> > ? wait = true; +> > ? } > > @@ -160,22 +292,28 @@ static int imx_get_temp(struct > > thermal_zone_device > > *tz, int *temp) -> > if (wait) -> > usleep_range(20, 50); +> > ? if (wait) +> > ? usleep_range(20, 50); > > > > - regmap_read(map, TEMPSENSE0, &val); > > + regmap_read(map, soc_data->temp_data, &val); > > -> > if (data->mode != THERMAL_DEVICE_ENABLED) { +> > ? if (data->mode != THERMAL_DEVICE_ENABLED) { > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_MEASURE_TEMP); > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_POWER_DOWN); > > + regmap_write(map, soc_data->sensor_ctrl + REG_CLR, -> > + soc_data->measure_temp_mask); +> > + ?????soc_data->measure_temp_mask); > > + regmap_write(map, soc_data->sensor_ctrl + REG_SET, -> > + soc_data->power_down_mask); -> > } +> > + ?????soc_data->power_down_mask); +> > ? } > > > > - if ((val & TEMPSENSE0_FINISHED) == 0) { > > + if ((val & soc_data->temp_valid_mask) == 0) { -> > dev_dbg(&tz->device, "temp measurement never +> > ? dev_dbg(&tz->device, "temp measurement never > > finished\n"); -> > return -EAGAIN; -> > } +> > ? return -EAGAIN; +> > ? } > > > > - n_meas = (val & TEMPSENSE0_TEMP_CNT_MASK) >> > > TEMPSENSE0_TEMP_CNT_SHIFT; > > + n_meas = (val & soc_data->temp_value_mask) > > + >> soc_data->temp_value_shift; > > -> > /* See imx_init_calib() for formula derivation */ +> > ? /* See imx_init_calib() for formula derivation */ > > - *temp = data->c2 - n_meas * data->c1; > > + if (data->socdata->version == TEMPMON_IMX7D) > > + *temp = (n_meas - data->c1 + 25) * 1000; > > + else > > + *temp = data->c2 - n_meas * data->c1; > > -> > /* Update alarm value to next higher trip point for +> > ? /* Update alarm value to next higher trip point for > > TEMPMON_IMX6Q */ -> > if (data->socdata->version == TEMPMON_IMX6Q) { @@ -219,21 +> > ? if (data->socdata->version == TEMPMON_IMX6Q) { @@ -219,21 > > +357,26 -> > @@ static int imx_set_mode(struct thermal_zone_device *tz, { -> > struct imx_thermal_data *data = tz->devdata; -> > struct regmap *map = data->tempmon; +> > @@ static int imx_set_mode(struct thermal_zone_device *tz,??{ +> > ? struct imx_thermal_data *data = tz->devdata; +> > ? struct regmap *map = data->tempmon; > > + const struct thermal_soc_data *soc_data = data->socdata; > > -> > if (mode == THERMAL_DEVICE_ENABLED) { -> > tz->polling_delay = IMX_POLLING_DELAY; -> > tz->passive_delay = IMX_PASSIVE_DELAY; +> > ? if (mode == THERMAL_DEVICE_ENABLED) { +> > ? tz->polling_delay = IMX_POLLING_DELAY; +> > ? tz->passive_delay = IMX_PASSIVE_DELAY; > > > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_POWER_DOWN); > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_MEASURE_TEMP); > > + regmap_write(map, soc_data->sensor_ctrl + REG_CLR, -> > + soc_data->power_down_mask); +> > + ?????soc_data->power_down_mask); > > + regmap_write(map, soc_data->sensor_ctrl + REG_SET, -> > + soc_data->measure_temp_mask); +> > + ?????soc_data->measure_temp_mask); > > -> > if (!data->irq_enabled) { -> > data->irq_enabled = true; -> > enable_irq(data->irq); -> > } -> > } else { +> > ? if (!data->irq_enabled) { +> > ? data->irq_enabled = true; +> > ? enable_irq(data->irq); +> > ? } +> > ? } else { > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_MEASURE_TEMP); > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_POWER_DOWN); > > + regmap_write(map, soc_data->sensor_ctrl + REG_CLR, -> > + soc_data->measure_temp_mask); +> > + ?????soc_data->measure_temp_mask); > > + regmap_write(map, soc_data->sensor_ctrl + REG_SET, -> > + soc_data->power_down_mask); +> > + ?????soc_data->power_down_mask); > > -> > tz->polling_delay = 0; -> > tz->passive_delay = 0; +> > ? tz->polling_delay = 0; +> > ? tz->passive_delay = 0; > > @@ -355,6 +498,15 @@ static int imx_init_calib(struct > > platform_device *pdev, > > u32 ocotp_ana1) -> > } +> > ? } > > -> > /* -> > + * On i.MX7D, we only use the calibration data at 25C to +> > ? /* +> > + ?* On i.MX7D, we only use the calibration data at 25C to > > get the temp, -> > + * Tmeas = ( Nmeas - n1) + 25; n1 is the fuse value for +> > + ?* Tmeas = ( Nmeas - n1) + 25; n1 is the fuse value for > > 25C. -> > + */ +> > + ?*/ > > + if (data->socdata->version == TEMPMON_IMX7D) { > > + data->c1 = (ocotp_ana1 >> 9) & 0x1ff; > > + return 0; > > + } > > + > > + /* -> > * The sensor is calibrated at 25 °C (aka T1) and the +> > ? ?* The sensor is calibrated at 25 ?C (aka T1) and the > > value measured -> > * (aka N1) at this temperature is provided in bits +> > ? ?* (aka N1) at this temperature is provided in bits > > [31:20] in the -> > * i.MX's OCOTP value ANA1. +> > ? ?* i.MX's OCOTP value ANA1. > > @@ -492,6 +644,7 @@ static irqreturn_t > > imx_thermal_alarm_irq_thread(int -> > irq, void *dev) static const struct of_device_id +> > irq, void *dev)??static const struct of_device_id > > of_imx_thermal_match[] = { -> > { .compatible = "fsl,imx6q-tempmon", .data = +> > ? { .compatible = "fsl,imx6q-tempmon", .data = > > &thermal_imx6q_data, }, -> > { .compatible = "fsl,imx6sx-tempmon", .data = +> > ? { .compatible = "fsl,imx6sx-tempmon", .data = > > &thermal_imx6sx_data, }, > > + { .compatible = "fsl,imx7d-tempmon", .data = > > &thermal_imx7d_data, }, -> > { /* end */ } -> > }; -> > MODULE_DEVICE_TABLE(of, of_imx_thermal_match); @@ -523,14 +676,15 +> > ? { /* end */ } +> > ?}; +> > ?MODULE_DEVICE_TABLE(of, of_imx_thermal_match); @@ -523,14 +676,15 > > @@ static int imx_thermal_probe(struct platform_device *pdev) > > -> > /* make sure the IRQ flag is clear before enabling irq on +> > ? /* make sure the IRQ flag is clear before enabling irq on > > i.MX6SX */ -> > if (data->socdata->version == TEMPMON_IMX6SX) { +> > ? if (data->socdata->version == TEMPMON_IMX6SX) { > > - regmap_write(map, MISC1 + REG_CLR, > > MISC1_IRQ_TEMPHIGH | > > - MISC1_IRQ_TEMPLOW | MISC1_IRQ_TEMPPANIC); @@ -499,24 +499,24 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > + IMX6_MISC1_IRQ_TEMPHIGH | > > IMX6_MISC1_IRQ_TEMPLOW > > + | IMX6_MISC1_IRQ_TEMPPANIC); -> > /* -> > * reset value of LOW ALARM is incorrect, set it +> > ? /* +> > ? ?* reset value of LOW ALARM is incorrect, set it > > to lowest -> > * value to avoid false trigger of low alarm. -> > */ +> > ? ?* value to avoid false trigger of low alarm. +> > ? ?*/ > > - regmap_write(map, TEMPSENSE2 + REG_SET, > > - TEMPSENSE2_LOW_VALUE_MASK); > > + regmap_write(map, data->socdata->low_alarm_ctrl + > > REG_SET, -> > + data->socdata->low_alarm_mask); -> > } +> > + ?????data->socdata->low_alarm_mask); +> > ? } > > -> > data->irq = platform_get_irq(pdev, 0); @@ -557,11 +711,17 +> > ? data->irq = platform_get_irq(pdev, 0); @@ -557,11 +711,17 > > @@ static int > > imx_thermal_probe(struct platform_device *pdev) -> > } +> > ? } > > -> > /* Make sure sensor is in known good state for +> > ? /* Make sure sensor is in known good state for > > measurements */ > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_POWER_DOWN); @@ -529,107 +529,107 @@ On 二, 2018-03-13 at 06:13 +0000, Anson Huang wrote: > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_POWER_DOWN); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_CLR, -> > + data->socdata->power_down_mask); +> > + ?????data->socdata->power_down_mask); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_CLR, -> > + data->socdata->measure_temp_mask); +> > + ?????data->socdata->measure_temp_mask); > > + regmap_write(map, data->socdata->measure_freq_ctrl + > > REG_CLR, -> > + data->socdata->measure_freq_mask); +> > + ?????data->socdata->measure_freq_mask); > > + if (data->socdata->version != TEMPMON_IMX7D) > > + regmap_write(map, IMX6_MISC0 + REG_SET, > > + IMX6_MISC0_REFTOP_SELBIASOFF); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_SET, -> > + data->socdata->power_down_mask); +> > + ?????data->socdata->power_down_mask); > > -> > data->policy = cpufreq_cpu_get(0); -> > if (!data->policy) { +> > ? data->policy = cpufreq_cpu_get(0); +> > ? if (!data->policy) { > > @@ -626,16 +786,20 @@ static int imx_thermal_probe(struct > > platform_device > > *pdev) -> > data->temp_passive / 1000); +> > ? ?data->temp_passive / 1000); > > -> > /* Enable measurements at ~ 10 Hz */ +> > ? /* Enable measurements at ~ 10 Hz */ > > - regmap_write(map, TEMPSENSE1 + REG_CLR, > > TEMPSENSE1_MEASURE_FREQ); > > + regmap_write(map, data->socdata->measure_freq_ctrl + > > REG_CLR, -> > + data->socdata->measure_freq_mask); -> > measure_freq = DIV_ROUND_UP(32768, 10); /* 10 Hz */ +> > + ?????data->socdata->measure_freq_mask); +> > ? measure_freq = DIV_ROUND_UP(32768, 10); /* 10 Hz */ > > - regmap_write(map, TEMPSENSE1 + REG_SET, measure_freq); > > + regmap_write(map, data->socdata->measure_freq_ctrl + > > REG_SET, -> > + measure_freq << data->socdata- +> > + ?????measure_freq << data->socdata- > > >measure_freq_shift); -> > imx_set_alarm_temp(data, data->temp_passive); +> > ? imx_set_alarm_temp(data, data->temp_passive); > > -> > if (data->socdata->version == TEMPMON_IMX6SX) -> > imx_set_panic_temp(data, data->temp_critical); +> > ? if (data->socdata->version == TEMPMON_IMX6SX) +> > ? imx_set_panic_temp(data, data->temp_critical); > > > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_POWER_DOWN); > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_MEASURE_TEMP); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_CLR, -> > + data->socdata->power_down_mask); +> > + ?????data->socdata->power_down_mask); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_SET, -> > + data->socdata->measure_temp_mask); +> > + ?????data->socdata->measure_temp_mask); > > -> > ret = devm_request_threaded_irq(&pdev->dev, data->irq, -> > imx_thermal_alarm_irq, +> > ? ret = devm_request_threaded_irq(&pdev->dev, data->irq, +> > ? imx_thermal_alarm_irq, > > imx_thermal_alarm_irq_thread, @@ > > -661,7 +825,8 @@ static int imx_thermal_remove(struct > > platform_device > > *pdev) -> > struct regmap *map = data->tempmon; +> > ? struct regmap *map = data->tempmon; > > -> > /* Disable measurements */ +> > ? /* Disable measurements */ > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_POWER_DOWN); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_SET, -> > + data->socdata->power_down_mask); -> > if (!IS_ERR(data->thermal_clk)) -> > clk_disable_unprepare(data->thermal_clk); +> > + ?????data->socdata->power_down_mask); +> > ? if (!IS_ERR(data->thermal_clk)) +> > ? clk_disable_unprepare(data->thermal_clk); > > > > @@ -684,8 +849,10 @@ static int imx_thermal_suspend(struct device > > *dev) -> > * temperature will be read as the thermal sensor is +> > ? ?* temperature will be read as the thermal sensor is > > powered -> > * down. -> > */ +> > ? ?* down. +> > ? ?*/ > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_MEASURE_TEMP); > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_POWER_DOWN); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_CLR, -> > + data->socdata->measure_temp_mask); +> > + ?????data->socdata->measure_temp_mask); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_SET, -> > + data->socdata->power_down_mask); -> > data->mode = THERMAL_DEVICE_DISABLED; -> > clk_disable_unprepare(data->thermal_clk); +> > + ?????data->socdata->power_down_mask); +> > ? data->mode = THERMAL_DEVICE_DISABLED; +> > ? clk_disable_unprepare(data->thermal_clk); > > > > @@ -702,8 +869,10 @@ static int imx_thermal_resume(struct device > > *dev) -> > if (ret) -> > return ret; -> > /* Enabled thermal sensor after resume */ +> > ? if (ret) +> > ? return ret; +> > ? /* Enabled thermal sensor after resume */ > > - regmap_write(map, TEMPSENSE0 + REG_CLR, > > TEMPSENSE0_POWER_DOWN); > > - regmap_write(map, TEMPSENSE0 + REG_SET, > > TEMPSENSE0_MEASURE_TEMP); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_CLR, -> > + data->socdata->power_down_mask); +> > + ?????data->socdata->power_down_mask); > > + regmap_write(map, data->socdata->sensor_ctrl + REG_SET, -> > + data->socdata->measure_temp_mask); -> > data->mode = THERMAL_DEVICE_ENABLED; +> > + ?????data->socdata->measure_temp_mask); +> > ? data->mode = THERMAL_DEVICE_ENABLED; > > -> > return 0; +> > ? return 0; > > -- > > 2.7.4 > > > > > > _______________________________________________ > > linux-arm-kernel mailing list -> > linux-arm-kernel@lists.infradead.org +> > linux-arm-kernel at lists.infradead.org > > https://emea01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fl > > ists.infr > > adead.org%2Fmailman%2Flistinfo%2Flinux-arm- diff --git a/a/content_digest b/N1/content_digest index c435514..ffb7d4a 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,31 +1,18 @@ "ref\01519955970-11365-1-git-send-email-Anson.Huang@nxp.com\0" "ref\01519955970-11365-2-git-send-email-Anson.Huang@nxp.com\0" "ref\0AM3PR04MB13158EE8C129D6AEC605A106F5D20@AM3PR04MB1315.eurprd04.prod.outlook.com\0" - "From\0Zhang Rui <rui.zhang@intel.com>\0" - "Subject\0Re: [PATCH V6 2/2] thermal: imx: add i.MX7 thermal sensor support\0" + "From\0rui.zhang@intel.com (Zhang Rui)\0" + "Subject\0[PATCH V6 2/2] thermal: imx: add i.MX7 thermal sensor support\0" "Date\0Tue, 13 Mar 2018 14:51:05 +0800\0" - "To\0Anson Huang <anson.huang@nxp.com>" - Leonard Crestez <leonard.crestez@nxp.com> - edubezval@gmail.com <edubezval@gmail.com> - robh+dt@kernel.org <robh+dt@kernel.org> - mark.rutland@arm.com <mark.rutland@arm.com> - shawnguo@kernel.org <shawnguo@kernel.org> - kernel@pengutronix.de <kernel@pengutronix.de> - Fabio Estevam <fabio.estevam@nxp.com> - " linux@armlinux.org.uk <linux@armlinux.org.uk>\0" - "Cc\0linux-arm-kernel@lists.infradead.org <linux-arm-kernel@lists.infradead.org>" - devicetree@vger.kernel.org <devicetree@vger.kernel.org> - dl-linux-imx <linux-imx@nxp.com> - linux-kernel@vger.kernel.org <linux-kernel@vger.kernel.org> - " linux-pm@vger.kernel.org <linux-pm@vger.kernel.org>\0" + "To\0linux-arm-kernel@lists.infradead.org\0" "\00:1\0" "b\0" "yeah, will review it and get back to you later.\n" "\n" - "On \344\272\214, 2018-03-13 at 06:13 +0000, Anson Huang wrote:\n" + "On ?, 2018-03-13 at 06:13 +0000, Anson Huang wrote:\n" "> Ping...\n" "> \n" - "> @rui.zhang@intel.com, can you help review this patch?\n" + "> @rui.zhang at intel.com, can you help review this patch?\n" "> \n" "> Anson Huang\n" "> Best Regards!\n" @@ -33,18 +20,18 @@ "> \n" "> > \n" "> > -----Original Message-----\n" - "> > From: linux-arm-kernel [mailto:linux-arm-kernel-bounces@lists.infra\n" + "> > From: linux-arm-kernel [mailto:linux-arm-kernel-bounces at lists.infra\n" "> > dead.org]\n" "> > On Behalf Of Anson Huang\n" "> > Sent: Friday, March 2, 2018 10:00 AM\n" - "> > To: Leonard Crestez <leonard.crestez@nxp.com>; rui.zhang@intel.com;\n" - "> > edubezval@gmail.com; robh+dt@kernel.org; mark.rutland@arm.com;\n" - "> > shawnguo@kernel.org; kernel@pengutronix.de; Fabio Estevam\n" - "> > <fabio.estevam@nxp.com>; linux@armlinux.org.uk\n" - "> > Cc: linux-arm-kernel@lists.infradead.org; devicetree@vger.kernel.or\n" + "> > To: Leonard Crestez <leonard.crestez@nxp.com>; rui.zhang at intel.com;\n" + "> > edubezval at gmail.com; robh+dt at kernel.org; mark.rutland at arm.com;\n" + "> > shawnguo at kernel.org; kernel at pengutronix.de; Fabio Estevam\n" + "> > <fabio.estevam@nxp.com>; linux at armlinux.org.uk\n" + "> > Cc: linux-arm-kernel at lists.infradead.org; devicetree at vger.kernel.or\n" "> > g;\n" - "> > dl-linux-imx <linux-imx@nxp.com>; linux-kernel@vger.kernel.org;\n" - "> > linux-pm@vger.kernel.org\n" + "> > dl-linux-imx <linux-imx@nxp.com>; linux-kernel at vger.kernel.org;\n" + "> > linux-pm at vger.kernel.org\n" "> > Subject: [PATCH V6 2/2] thermal: imx: add i.MX7 thermal sensor\n" "> > support\n" "> > \n" @@ -69,10 +56,10 @@ "> > ---\n" "> > changes since V5:\n" "> > \tno code change, just add Reviewed-by.\n" - "> > \302\240.../devicetree/bindings/thermal/imx-thermal.txt\302\240\302\240\302\240\302\240|\302\240\302\240\302\2409 +-\n" - "> > \302\240drivers/thermal/imx_thermal.c\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240\302\240| 295\n" + "> > ?.../devicetree/bindings/thermal/imx-thermal.txt????|???9 +-\n" + "> > ?drivers/thermal/imx_thermal.c??????????????????????| 295\n" "> > ++++++++++++++++-----\n" - "> > \302\2402 files changed, 239 insertions(+), 65 deletions(-)\n" + "> > ?2 files changed, 239 insertions(+), 65 deletions(-)\n" "> > \n" "> > diff --git a/Documentation/devicetree/bindings/thermal/imx-\n" "> > thermal.txt\n" @@ -81,32 +68,32 @@ "> > --- a/Documentation/devicetree/bindings/thermal/imx-thermal.txt\n" "> > +++ b/Documentation/devicetree/bindings/thermal/imx-thermal.txt\n" "> > @@ -1,8 +1,13 @@\n" - "> > \302\240* Temperature Monitor (TEMPMON) on Freescale i.MX SoCs\n" + "> > ?* Temperature Monitor (TEMPMON) on Freescale i.MX SoCs\n" "> > \n" - "> > \302\240Required properties:\n" + "> > ?Required properties:\n" "> > -- compatible : \"fsl,imx6q-tempmon\" for i.MX6Q, \"fsl,imx6sx-\n" "> > tempmon\" for\n" "> > i.MX6SX.\n" - "> > -\302\240\302\240i.MX6SX has two more IRQs than i.MX6Q, one is IRQ_LOW and the\n" + "> > -??i.MX6SX has two more IRQs than i.MX6Q, one is IRQ_LOW and the\n" "> > other is\n" "> > IRQ_PANIC,\n" "> > +- compatible : must be one of following:\n" - "> > +\302\240\302\240- \"fsl,imx6q-tempmon\" for i.MX6Q,\n" - "> > +\302\240\302\240- \"fsl,imx6sx-tempmon\" for i.MX6SX,\n" - "> > +\302\240\302\240- \"fsl,imx7d-tempmon\" for i.MX7S/D.\n" + "> > +??- \"fsl,imx6q-tempmon\" for i.MX6Q,\n" + "> > +??- \"fsl,imx6sx-tempmon\" for i.MX6SX,\n" + "> > +??- \"fsl,imx7d-tempmon\" for i.MX7S/D.\n" "> > +- interrupts : the interrupt output of the controller:\n" - "> > +\302\240\302\240i.MX6Q has one IRQ which will be triggered when temperature is\n" + "> > +??i.MX6Q has one IRQ which will be triggered when temperature is\n" "> > higher\n" "> > +than high threshold,\n" - "> > +\302\240\302\240i.MX6SX and i.MX7S/D have two more IRQs than i.MX6Q, one is\n" + "> > +??i.MX6SX and i.MX7S/D have two more IRQs than i.MX6Q, one is\n" "> > IRQ_LOW\n" "> > +and the other is IRQ_PANIC,\n" - "> > \302\240\302\240\302\240when temperature is below than low threshold, IRQ_LOW will be\n" + "> > ???when temperature is below than low threshold, IRQ_LOW will be\n" "> > triggered,\n" "> > when temperature\n" - "> > \302\240\302\240\302\240is higher than panic threshold, system will auto reboot by SRC\n" + "> > ???is higher than panic threshold, system will auto reboot by SRC\n" "> > module.\n" - "> > \302\240- fsl,tempmon : phandle pointer to system controller that contains\n" + "> > ?- fsl,tempmon : phandle pointer to system controller that contains\n" "> > TEMPMON\n" "> > diff --git a/drivers/thermal/imx_thermal.c\n" "> > b/drivers/thermal/imx_thermal.c\n" @@ -114,8 +101,8 @@ "> > --- a/drivers/thermal/imx_thermal.c\n" "> > +++ b/drivers/thermal/imx_thermal.c\n" "> > @@ -31,35 +31,57 @@\n" - "> > \302\240#define REG_CLR\t\t0x8\n" - "> > \302\240#define REG_TOG\t\t0xc\n" + "> > ?#define REG_CLR\t\t0x8\n" + "> > ?#define REG_TOG\t\t0xc\n" "> > \n" "> > -#define MISC0\t\t\t\t0x0150\n" "> > -#define MISC0_REFTOP_SELBIASOFF\t\t(1 << 3)\n" @@ -126,7 +113,7 @@ "> > +#define IMX6_MISC0_REFTOP_SELBIASOFF\t\t(1 << 3)\n" "> > +#define IMX6_MISC1\t\t\t\t0x0160\n" "> > +#define IMX6_MISC1_IRQ_TEMPHIGH\t\t\t(1 << 29)\n" - "> > \302\240/* Below LOW and PANIC bits are only for TEMPMON_IMX6SX */\n" + "> > ?/* Below LOW and PANIC bits are only for TEMPMON_IMX6SX */\n" "> > -#define MISC1_IRQ_TEMPLOW\t\t(1 << 28)\n" "> > -#define MISC1_IRQ_TEMPPANIC\t\t(1 << 27)\n" "> > -\n" @@ -165,8 +152,8 @@ "> > +#define IMX6_TEMPSENSE1_MEASURE_FREQ\t\t0xffff\n" "> > +#define IMX6_TEMPSENSE1_MEASURE_FREQ_SHIFT\t0\n" "> > \n" - "> > \302\240#define OCOTP_MEM0\t\t\t0x0480\n" - "> > \302\240#define OCOTP_ANA1\t\t\t0x04e0\n" + "> > ?#define OCOTP_MEM0\t\t\t0x0480\n" + "> > ?#define OCOTP_ANA1\t\t\t0x04e0\n" "> > \n" "> > +/* Below TEMPSENSE2 is only for TEMPMON_IMX6SX */\n" "> > +#define IMX6_TEMPSENSE2\t\t\t\t0x0290\n" @@ -195,18 +182,18 @@ "> > +#define IMX7_TEMPSENSE1_TEMP_VALUE_SHIFT\t0\n" "> > +#define IMX7_TEMPSENSE1_TEMP_VALUE_MASK\t\t0x1ff\n" "> > +\n" - "> > \302\240/* The driver supports 1 passive trip point and 1 critical trip\n" - "> > point */\302\240\302\240enum\n" + "> > ?/* The driver supports 1 passive trip point and 1 critical trip\n" + "> > point */??enum\n" "> > imx_thermal_trip {\n" - "> > \302\240\tIMX_TRIP_PASSIVE,\n" + "> > ?\tIMX_TRIP_PASSIVE,\n" "> > @@ -72,17 +94,114 @@ enum imx_thermal_trip {\n" "> > \n" - "> > \302\240#define TEMPMON_IMX6Q\t\t\t1\n" - "> > \302\240#define TEMPMON_IMX6SX\t\t\t2\n" + "> > ?#define TEMPMON_IMX6Q\t\t\t1\n" + "> > ?#define TEMPMON_IMX6SX\t\t\t2\n" "> > +#define TEMPMON_IMX7D\t\t\t3\n" "> > \n" - "> > \302\240struct thermal_soc_data {\n" - "> > \302\240\tu32 version;\n" + "> > ?struct thermal_soc_data {\n" + "> > ?\tu32 version;\n" "> > +\n" "> > +\tu32 sensor_ctrl;\n" "> > +\tu32 power_down_mask;\n" @@ -232,10 +219,10 @@ "> > +\tu32 low_alarm_ctrl;\n" "> > +\tu32 low_alarm_mask;\n" "> > +\tu32 low_alarm_shift;\n" - "> > \302\240};\n" + "> > ?};\n" "> > \n" - "> > \302\240static struct thermal_soc_data thermal_imx6q_data = {\n" - "> > \302\240\t.version = TEMPMON_IMX6Q,\n" + "> > ?static struct thermal_soc_data thermal_imx6q_data = {\n" + "> > ?\t.version = TEMPMON_IMX6Q,\n" "> > +\n" "> > +\t.sensor_ctrl = IMX6_TEMPSENSE0,\n" "> > +\t.power_down_mask = IMX6_TEMPSENSE0_POWER_DOWN,\n" @@ -253,10 +240,10 @@ "> > +\t.high_alarm_ctrl = IMX6_TEMPSENSE0,\n" "> > +\t.high_alarm_mask = IMX6_TEMPSENSE0_ALARM_VALUE_MASK,\n" "> > +\t.high_alarm_shift = IMX6_TEMPSENSE0_ALARM_VALUE_SHIFT,\n" - "> > \302\240};\n" + "> > ?};\n" "> > \n" - "> > \302\240static struct thermal_soc_data thermal_imx6sx_data = {\n" - "> > \302\240\t.version = TEMPMON_IMX6SX,\n" + "> > ?static struct thermal_soc_data thermal_imx6sx_data = {\n" + "> > ?\t.version = TEMPMON_IMX6SX,\n" "> > +\n" "> > +\t.sensor_ctrl = IMX6_TEMPSENSE0,\n" "> > +\t.power_down_mask = IMX6_TEMPSENSE0_POWER_DOWN,\n" @@ -310,38 +297,38 @@ "> > +\t.low_alarm_ctrl = IMX7_TEMPSENSE0,\n" "> > +\t.low_alarm_mask = IMX7_TEMPSENSE0_LOW_ALARM_MASK,\n" "> > +\t.low_alarm_shift = IMX7_TEMPSENSE0_LOW_ALARM_SHIFT,\n" - "> > \302\240};\n" + "> > ?};\n" "> > \n" - "> > \302\240struct imx_thermal_data {\n" - "> > @@ -107,31 +226,42 @@ struct imx_thermal_data {\302\240\302\240static void\n" + "> > ?struct imx_thermal_data {\n" + "> > @@ -107,31 +226,42 @@ struct imx_thermal_data {??static void\n" "> > imx_set_panic_temp(struct imx_thermal_data *data,\n" - "> > \302\240\t\t\t\302\240\302\240\302\240\302\240\302\240\302\240\302\240int panic_temp)\n" - "> > \302\240{\n" + "> > ?\t\t\t???????int panic_temp)\n" + "> > ?{\n" "> > +\tconst struct thermal_soc_data *soc_data = data->socdata;\n" - "> > \302\240\tstruct regmap *map = data->tempmon;\n" - "> > \302\240\tint critical_value;\n" + "> > ?\tstruct regmap *map = data->tempmon;\n" + "> > ?\tint critical_value;\n" "> > \n" - "> > \302\240\tcritical_value = (data->c2 - panic_temp) / data->c1;\n" + "> > ?\tcritical_value = (data->c2 - panic_temp) / data->c1;\n" "> > -\tregmap_write(map, TEMPSENSE2 + REG_CLR,\n" "> > TEMPSENSE2_PANIC_VALUE_MASK);\n" "> > -\tregmap_write(map, TEMPSENSE2 + REG_SET, critical_value <<\n" "> > -\t\t\tTEMPSENSE2_PANIC_VALUE_SHIFT);\n" "> > +\n" "> > +\tregmap_write(map, soc_data->panic_alarm_ctrl + REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240soc_data->panic_alarm_mask);\n" + "> > +\t\t?????soc_data->panic_alarm_mask);\n" "> > +\tregmap_write(map, soc_data->panic_alarm_ctrl + REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240critical_value << soc_data-\n" + "> > +\t\t?????critical_value << soc_data-\n" "> > >panic_alarm_shift);\n" - "> > \302\240}\n" + "> > ?}\n" "> > \n" - "> > \302\240static void imx_set_alarm_temp(struct imx_thermal_data *data,\n" - "> > \302\240\t\t\t\302\240\302\240\302\240\302\240\302\240\302\240\302\240int alarm_temp)\n" - "> > \302\240{\n" - "> > \302\240\tstruct regmap *map = data->tempmon;\n" + "> > ?static void imx_set_alarm_temp(struct imx_thermal_data *data,\n" + "> > ?\t\t\t???????int alarm_temp)\n" + "> > ?{\n" + "> > ?\tstruct regmap *map = data->tempmon;\n" "> > +\tconst struct thermal_soc_data *soc_data = data->socdata;\n" - "> > \302\240\tint alarm_value;\n" + "> > ?\tint alarm_value;\n" "> > \n" - "> > \302\240\tdata->alarm_temp = alarm_temp;\n" + "> > ?\tdata->alarm_temp = alarm_temp;\n" "> > -\talarm_value = (data->c2 - alarm_temp) / data->c1;\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_ALARM_VALUE_MASK);\n" @@ -354,166 +341,166 @@ "> > +\t\talarm_value = (data->c2 - alarm_temp) / data->c1;\n" "> > +\n" "> > +\tregmap_write(map, soc_data->high_alarm_ctrl + REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240soc_data->high_alarm_mask);\n" + "> > +\t\t?????soc_data->high_alarm_mask);\n" "> > +\tregmap_write(map, soc_data->high_alarm_ctrl + REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240alarm_value << soc_data->high_alarm_shift);\n" - "> > \302\240}\n" + "> > +\t\t?????alarm_value << soc_data->high_alarm_shift);\n" + "> > ?}\n" "> > \n" - "> > \302\240static int imx_get_temp(struct thermal_zone_device *tz, int\n" - "> > *temp)\302\240\302\240{\n" - "> > \302\240\tstruct imx_thermal_data *data = tz->devdata;\n" + "> > ?static int imx_get_temp(struct thermal_zone_device *tz, int\n" + "> > *temp)??{\n" + "> > ?\tstruct imx_thermal_data *data = tz->devdata;\n" "> > +\tconst struct thermal_soc_data *soc_data = data->socdata;\n" - "> > \302\240\tstruct regmap *map = data->tempmon;\n" - "> > \302\240\tunsigned int n_meas;\n" - "> > \302\240\tbool wait;\n" + "> > ?\tstruct regmap *map = data->tempmon;\n" + "> > ?\tunsigned int n_meas;\n" + "> > ?\tbool wait;\n" "> > @@ -139,16 +269,18 @@ static int imx_get_temp(struct\n" "> > thermal_zone_device\n" "> > *tz, int *temp)\n" "> > \n" - "> > \302\240\tif (data->mode == THERMAL_DEVICE_ENABLED) {\n" - "> > \302\240\t\t/* Check if a measurement is currently in progress\n" + "> > ?\tif (data->mode == THERMAL_DEVICE_ENABLED) {\n" + "> > ?\t\t/* Check if a measurement is currently in progress\n" "> > */\n" "> > -\t\tregmap_read(map, TEMPSENSE0, &val);\n" "> > -\t\twait = !(val & TEMPSENSE0_FINISHED);\n" "> > +\t\tregmap_read(map, soc_data->temp_data, &val);\n" "> > +\t\twait = !(val & soc_data->temp_valid_mask);\n" - "> > \302\240\t} else {\n" - "> > \302\240\t\t/*\n" - "> > \302\240\t\t\302\240* Every time we measure the temperature, we will\n" + "> > ?\t} else {\n" + "> > ?\t\t/*\n" + "> > ?\t\t?* Every time we measure the temperature, we will\n" "> > power on the\n" - "> > \302\240\t\t\302\240* temperature sensor, enable measurements, take a\n" + "> > ?\t\t?* temperature sensor, enable measurements, take a\n" "> > reading,\n" - "> > \302\240\t\t\302\240* disable measurements, power off the temperature\n" + "> > ?\t\t?* disable measurements, power off the temperature\n" "> > sensor.\n" - "> > \302\240\t\t\302\240*/\n" + "> > ?\t\t?*/\n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_MEASURE_TEMP);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240soc_data->power_down_mask);\n" + "> > +\t\t\t????soc_data->power_down_mask);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_SET,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240soc_data->measure_temp_mask);\n" + "> > +\t\t\t????soc_data->measure_temp_mask);\n" "> > \n" - "> > \302\240\t\twait = true;\n" - "> > \302\240\t}\n" + "> > ?\t\twait = true;\n" + "> > ?\t}\n" "> > @@ -160,22 +292,28 @@ static int imx_get_temp(struct\n" "> > thermal_zone_device\n" "> > *tz, int *temp)\n" - "> > \302\240\tif (wait)\n" - "> > \302\240\t\tusleep_range(20, 50);\n" + "> > ?\tif (wait)\n" + "> > ?\t\tusleep_range(20, 50);\n" "> > \n" "> > -\tregmap_read(map, TEMPSENSE0, &val);\n" "> > +\tregmap_read(map, soc_data->temp_data, &val);\n" "> > \n" - "> > \302\240\tif (data->mode != THERMAL_DEVICE_ENABLED) {\n" + "> > ?\tif (data->mode != THERMAL_DEVICE_ENABLED) {\n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_MEASURE_TEMP);\n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240\302\240soc_data->measure_temp_mask);\n" + "> > +\t\t\t?????soc_data->measure_temp_mask);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_SET,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240\302\240soc_data->power_down_mask);\n" - "> > \302\240\t}\n" + "> > +\t\t\t?????soc_data->power_down_mask);\n" + "> > ?\t}\n" "> > \n" "> > -\tif ((val & TEMPSENSE0_FINISHED) == 0) {\n" "> > +\tif ((val & soc_data->temp_valid_mask) == 0) {\n" - "> > \302\240\t\tdev_dbg(&tz->device, \"temp measurement never\n" + "> > ?\t\tdev_dbg(&tz->device, \"temp measurement never\n" "> > finished\\n\");\n" - "> > \302\240\t\treturn -EAGAIN;\n" - "> > \302\240\t}\n" + "> > ?\t\treturn -EAGAIN;\n" + "> > ?\t}\n" "> > \n" "> > -\tn_meas = (val & TEMPSENSE0_TEMP_CNT_MASK) >>\n" "> > TEMPSENSE0_TEMP_CNT_SHIFT;\n" "> > +\tn_meas = (val & soc_data->temp_value_mask)\n" "> > +\t\t>> soc_data->temp_value_shift;\n" "> > \n" - "> > \302\240\t/* See imx_init_calib() for formula derivation */\n" + "> > ?\t/* See imx_init_calib() for formula derivation */\n" "> > -\t*temp = data->c2 - n_meas * data->c1;\n" "> > +\tif (data->socdata->version == TEMPMON_IMX7D)\n" "> > +\t\t*temp = (n_meas - data->c1 + 25) * 1000;\n" "> > +\telse\n" "> > +\t\t*temp = data->c2 - n_meas * data->c1;\n" "> > \n" - "> > \302\240\t/* Update alarm value to next higher trip point for\n" + "> > ?\t/* Update alarm value to next higher trip point for\n" "> > TEMPMON_IMX6Q */\n" - "> > \302\240\tif (data->socdata->version == TEMPMON_IMX6Q) { @@ -219,21\n" + "> > ?\tif (data->socdata->version == TEMPMON_IMX6Q) { @@ -219,21\n" "> > +357,26\n" - "> > @@ static int imx_set_mode(struct thermal_zone_device *tz,\302\240\302\240{\n" - "> > \302\240\tstruct imx_thermal_data *data = tz->devdata;\n" - "> > \302\240\tstruct regmap *map = data->tempmon;\n" + "> > @@ static int imx_set_mode(struct thermal_zone_device *tz,??{\n" + "> > ?\tstruct imx_thermal_data *data = tz->devdata;\n" + "> > ?\tstruct regmap *map = data->tempmon;\n" "> > +\tconst struct thermal_soc_data *soc_data = data->socdata;\n" "> > \n" - "> > \302\240\tif (mode == THERMAL_DEVICE_ENABLED) {\n" - "> > \302\240\t\ttz->polling_delay = IMX_POLLING_DELAY;\n" - "> > \302\240\t\ttz->passive_delay = IMX_PASSIVE_DELAY;\n" + "> > ?\tif (mode == THERMAL_DEVICE_ENABLED) {\n" + "> > ?\t\ttz->polling_delay = IMX_POLLING_DELAY;\n" + "> > ?\t\ttz->passive_delay = IMX_PASSIVE_DELAY;\n" "> > \n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_MEASURE_TEMP);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240\302\240soc_data->power_down_mask);\n" + "> > +\t\t\t?????soc_data->power_down_mask);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_SET,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240\302\240soc_data->measure_temp_mask);\n" + "> > +\t\t\t?????soc_data->measure_temp_mask);\n" "> > \n" - "> > \302\240\t\tif (!data->irq_enabled) {\n" - "> > \302\240\t\t\tdata->irq_enabled = true;\n" - "> > \302\240\t\t\tenable_irq(data->irq);\n" - "> > \302\240\t\t}\n" - "> > \302\240\t} else {\n" + "> > ?\t\tif (!data->irq_enabled) {\n" + "> > ?\t\t\tdata->irq_enabled = true;\n" + "> > ?\t\t\tenable_irq(data->irq);\n" + "> > ?\t\t}\n" + "> > ?\t} else {\n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_MEASURE_TEMP);\n" "> > -\t\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240\302\240soc_data->measure_temp_mask);\n" + "> > +\t\t\t?????soc_data->measure_temp_mask);\n" "> > +\t\tregmap_write(map, soc_data->sensor_ctrl + REG_SET,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240\302\240soc_data->power_down_mask);\n" + "> > +\t\t\t?????soc_data->power_down_mask);\n" "> > \n" - "> > \302\240\t\ttz->polling_delay = 0;\n" - "> > \302\240\t\ttz->passive_delay = 0;\n" + "> > ?\t\ttz->polling_delay = 0;\n" + "> > ?\t\ttz->passive_delay = 0;\n" "> > @@ -355,6 +498,15 @@ static int imx_init_calib(struct\n" "> > platform_device *pdev,\n" "> > u32 ocotp_ana1)\n" - "> > \302\240\t}\n" + "> > ?\t}\n" "> > \n" - "> > \302\240\t/*\n" - "> > +\t\302\240* On i.MX7D, we only use the calibration data at 25C to\n" + "> > ?\t/*\n" + "> > +\t?* On i.MX7D, we only use the calibration data at 25C to\n" "> > get the temp,\n" - "> > +\t\302\240* Tmeas = ( Nmeas - n1) + 25; n1 is the fuse value for\n" + "> > +\t?* Tmeas = ( Nmeas - n1) + 25; n1 is the fuse value for\n" "> > 25C.\n" - "> > +\t\302\240*/\n" + "> > +\t?*/\n" "> > +\tif (data->socdata->version == TEMPMON_IMX7D) {\n" "> > +\t\tdata->c1 = (ocotp_ana1 >> 9) & 0x1ff;\n" "> > +\t\treturn 0;\n" "> > +\t}\n" "> > +\n" "> > +\t/*\n" - "> > \302\240\t\302\240* The sensor is calibrated at 25 \302\260C (aka T1) and the\n" + "> > ?\t?* The sensor is calibrated at 25 ?C (aka T1) and the\n" "> > value measured\n" - "> > \302\240\t\302\240* (aka N1) at this temperature is provided in bits\n" + "> > ?\t?* (aka N1) at this temperature is provided in bits\n" "> > [31:20] in the\n" - "> > \302\240\t\302\240* i.MX's OCOTP value ANA1.\n" + "> > ?\t?* i.MX's OCOTP value ANA1.\n" "> > @@ -492,6 +644,7 @@ static irqreturn_t\n" "> > imx_thermal_alarm_irq_thread(int\n" - "> > irq, void *dev)\302\240\302\240static const struct of_device_id\n" + "> > irq, void *dev)??static const struct of_device_id\n" "> > of_imx_thermal_match[] = {\n" - "> > \302\240\t{ .compatible = \"fsl,imx6q-tempmon\", .data =\n" + "> > ?\t{ .compatible = \"fsl,imx6q-tempmon\", .data =\n" "> > &thermal_imx6q_data, },\n" - "> > \302\240\t{ .compatible = \"fsl,imx6sx-tempmon\", .data =\n" + "> > ?\t{ .compatible = \"fsl,imx6sx-tempmon\", .data =\n" "> > &thermal_imx6sx_data, },\n" "> > +\t{ .compatible = \"fsl,imx7d-tempmon\", .data =\n" "> > &thermal_imx7d_data, },\n" - "> > \302\240\t{ /* end */ }\n" - "> > \302\240};\n" - "> > \302\240MODULE_DEVICE_TABLE(of, of_imx_thermal_match); @@ -523,14 +676,15\n" + "> > ?\t{ /* end */ }\n" + "> > ?};\n" + "> > ?MODULE_DEVICE_TABLE(of, of_imx_thermal_match); @@ -523,14 +676,15\n" "> > @@ static int imx_thermal_probe(struct platform_device *pdev)\n" "> > \n" - "> > \302\240\t/* make sure the IRQ flag is clear before enabling irq on\n" + "> > ?\t/* make sure the IRQ flag is clear before enabling irq on\n" "> > i.MX6SX */\n" - "> > \302\240\tif (data->socdata->version == TEMPMON_IMX6SX) {\n" + "> > ?\tif (data->socdata->version == TEMPMON_IMX6SX) {\n" "> > -\t\tregmap_write(map, MISC1 + REG_CLR,\n" "> > MISC1_IRQ_TEMPHIGH |\n" "> > -\t\t\tMISC1_IRQ_TEMPLOW | MISC1_IRQ_TEMPPANIC);\n" @@ -521,24 +508,24 @@ "> > +\t\t\tIMX6_MISC1_IRQ_TEMPHIGH |\n" "> > IMX6_MISC1_IRQ_TEMPLOW\n" "> > +\t\t\t| IMX6_MISC1_IRQ_TEMPPANIC);\n" - "> > \302\240\t\t/*\n" - "> > \302\240\t\t\302\240* reset value of LOW ALARM is incorrect, set it\n" + "> > ?\t\t/*\n" + "> > ?\t\t?* reset value of LOW ALARM is incorrect, set it\n" "> > to lowest\n" - "> > \302\240\t\t\302\240* value to avoid false trigger of low alarm.\n" - "> > \302\240\t\t\302\240*/\n" + "> > ?\t\t?* value to avoid false trigger of low alarm.\n" + "> > ?\t\t?*/\n" "> > -\t\tregmap_write(map, TEMPSENSE2 + REG_SET,\n" "> > -\t\t\tTEMPSENSE2_LOW_VALUE_MASK);\n" "> > +\t\tregmap_write(map, data->socdata->low_alarm_ctrl +\n" "> > REG_SET,\n" - "> > +\t\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->low_alarm_mask);\n" - "> > \302\240\t}\n" + "> > +\t\t\t?????data->socdata->low_alarm_mask);\n" + "> > ?\t}\n" "> > \n" - "> > \302\240\tdata->irq = platform_get_irq(pdev, 0); @@ -557,11 +711,17\n" + "> > ?\tdata->irq = platform_get_irq(pdev, 0); @@ -557,11 +711,17\n" "> > @@ static int\n" "> > imx_thermal_probe(struct platform_device *pdev)\n" - "> > \302\240\t}\n" + "> > ?\t}\n" "> > \n" - "> > \302\240\t/* Make sure sensor is in known good state for\n" + "> > ?\t/* Make sure sensor is in known good state for\n" "> > measurements */\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_POWER_DOWN);\n" @@ -551,107 +538,107 @@ "> > -\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->power_down_mask);\n" + "> > +\t\t?????data->socdata->power_down_mask);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->measure_temp_mask);\n" + "> > +\t\t?????data->socdata->measure_temp_mask);\n" "> > +\tregmap_write(map, data->socdata->measure_freq_ctrl +\n" "> > REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->measure_freq_mask);\n" + "> > +\t\t?????data->socdata->measure_freq_mask);\n" "> > +\tif (data->socdata->version != TEMPMON_IMX7D)\n" "> > +\t\tregmap_write(map, IMX6_MISC0 + REG_SET,\n" "> > +\t\t\tIMX6_MISC0_REFTOP_SELBIASOFF);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->power_down_mask);\n" + "> > +\t\t?????data->socdata->power_down_mask);\n" "> > \n" - "> > \302\240\tdata->policy = cpufreq_cpu_get(0);\n" - "> > \302\240\tif (!data->policy) {\n" + "> > ?\tdata->policy = cpufreq_cpu_get(0);\n" + "> > ?\tif (!data->policy) {\n" "> > @@ -626,16 +786,20 @@ static int imx_thermal_probe(struct\n" "> > platform_device\n" "> > *pdev)\n" - "> > \302\240\t\t\302\240data->temp_passive / 1000);\n" + "> > ?\t\t?data->temp_passive / 1000);\n" "> > \n" - "> > \302\240\t/* Enable measurements at ~ 10 Hz */\n" + "> > ?\t/* Enable measurements at ~ 10 Hz */\n" "> > -\tregmap_write(map, TEMPSENSE1 + REG_CLR,\n" "> > TEMPSENSE1_MEASURE_FREQ);\n" "> > +\tregmap_write(map, data->socdata->measure_freq_ctrl +\n" "> > REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->measure_freq_mask);\n" - "> > \302\240\tmeasure_freq = DIV_ROUND_UP(32768, 10); /* 10 Hz */\n" + "> > +\t\t?????data->socdata->measure_freq_mask);\n" + "> > ?\tmeasure_freq = DIV_ROUND_UP(32768, 10); /* 10 Hz */\n" "> > -\tregmap_write(map, TEMPSENSE1 + REG_SET, measure_freq);\n" "> > +\tregmap_write(map, data->socdata->measure_freq_ctrl +\n" "> > REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240measure_freq << data->socdata-\n" + "> > +\t\t?????measure_freq << data->socdata-\n" "> > >measure_freq_shift);\n" - "> > \302\240\timx_set_alarm_temp(data, data->temp_passive);\n" + "> > ?\timx_set_alarm_temp(data, data->temp_passive);\n" "> > \n" - "> > \302\240\tif (data->socdata->version == TEMPMON_IMX6SX)\n" - "> > \302\240\t\timx_set_panic_temp(data, data->temp_critical);\n" + "> > ?\tif (data->socdata->version == TEMPMON_IMX6SX)\n" + "> > ?\t\timx_set_panic_temp(data, data->temp_critical);\n" "> > \n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_MEASURE_TEMP);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->power_down_mask);\n" + "> > +\t\t?????data->socdata->power_down_mask);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->measure_temp_mask);\n" + "> > +\t\t?????data->socdata->measure_temp_mask);\n" "> > \n" - "> > \302\240\tret = devm_request_threaded_irq(&pdev->dev, data->irq,\n" - "> > \302\240\t\t\timx_thermal_alarm_irq,\n" + "> > ?\tret = devm_request_threaded_irq(&pdev->dev, data->irq,\n" + "> > ?\t\t\timx_thermal_alarm_irq,\n" "> > imx_thermal_alarm_irq_thread, @@\n" "> > -661,7 +825,8 @@ static int imx_thermal_remove(struct\n" "> > platform_device\n" "> > *pdev)\n" - "> > \302\240\tstruct regmap *map = data->tempmon;\n" + "> > ?\tstruct regmap *map = data->tempmon;\n" "> > \n" - "> > \302\240\t/* Disable measurements */\n" + "> > ?\t/* Disable measurements */\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->power_down_mask);\n" - "> > \302\240\tif (!IS_ERR(data->thermal_clk))\n" - "> > \302\240\t\tclk_disable_unprepare(data->thermal_clk);\n" + "> > +\t\t?????data->socdata->power_down_mask);\n" + "> > ?\tif (!IS_ERR(data->thermal_clk))\n" + "> > ?\t\tclk_disable_unprepare(data->thermal_clk);\n" "> > \n" "> > @@ -684,8 +849,10 @@ static int imx_thermal_suspend(struct device\n" "> > *dev)\n" - "> > \302\240\t\302\240* temperature will be read as the thermal sensor is\n" + "> > ?\t?* temperature will be read as the thermal sensor is\n" "> > powered\n" - "> > \302\240\t\302\240* down.\n" - "> > \302\240\t\302\240*/\n" + "> > ?\t?* down.\n" + "> > ?\t?*/\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_MEASURE_TEMP);\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->measure_temp_mask);\n" + "> > +\t\t?????data->socdata->measure_temp_mask);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->power_down_mask);\n" - "> > \302\240\tdata->mode = THERMAL_DEVICE_DISABLED;\n" - "> > \302\240\tclk_disable_unprepare(data->thermal_clk);\n" + "> > +\t\t?????data->socdata->power_down_mask);\n" + "> > ?\tdata->mode = THERMAL_DEVICE_DISABLED;\n" + "> > ?\tclk_disable_unprepare(data->thermal_clk);\n" "> > \n" "> > @@ -702,8 +869,10 @@ static int imx_thermal_resume(struct device\n" "> > *dev)\n" - "> > \302\240\tif (ret)\n" - "> > \302\240\t\treturn ret;\n" - "> > \302\240\t/* Enabled thermal sensor after resume */\n" + "> > ?\tif (ret)\n" + "> > ?\t\treturn ret;\n" + "> > ?\t/* Enabled thermal sensor after resume */\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_CLR,\n" "> > TEMPSENSE0_POWER_DOWN);\n" "> > -\tregmap_write(map, TEMPSENSE0 + REG_SET,\n" "> > TEMPSENSE0_MEASURE_TEMP);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_CLR,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->power_down_mask);\n" + "> > +\t\t?????data->socdata->power_down_mask);\n" "> > +\tregmap_write(map, data->socdata->sensor_ctrl + REG_SET,\n" - "> > +\t\t\302\240\302\240\302\240\302\240\302\240data->socdata->measure_temp_mask);\n" - "> > \302\240\tdata->mode = THERMAL_DEVICE_ENABLED;\n" + "> > +\t\t?????data->socdata->measure_temp_mask);\n" + "> > ?\tdata->mode = THERMAL_DEVICE_ENABLED;\n" "> > \n" - "> > \302\240\treturn 0;\n" + "> > ?\treturn 0;\n" "> > --\n" "> > 2.7.4\n" "> > \n" "> > \n" "> > _______________________________________________\n" "> > linux-arm-kernel mailing list\n" - "> > linux-arm-kernel@lists.infradead.org\n" + "> > linux-arm-kernel at lists.infradead.org\n" "> > https://emea01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fl\n" "> > ists.infr\n" "> > adead.org%2Fmailman%2Flistinfo%2Flinux-arm-\n" @@ -660,4 +647,4 @@ "> > bc2b4c6fa92cd99c5c301635%7C0%7C0%7C636555530125162768&sdata=GP4\n" > > UyKpDXyRkmwSIZY9Sb%2BDxO9sPAWCk0O%2FZPYRA0P4%3D&reserved=0 -5872656edecb69b57f3869176fb389c22b099c4e8cb7bf94017e051d4ee479ce +1595a3c1e369a331892e442808e396fa52808bf582660cbc30b21f50265b5de4
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.