Home
last modified time | relevance | path

Searched refs:pwm (Results 1 – 25 of 1267) sorted by relevance

12345678910>>...51

/openbmc/linux/drivers/pwm/
H A DMakefile4 obj-$(CONFIG_PWM_AB8500) += pwm-ab8500.o
5 obj-$(CONFIG_PWM_APPLE) += pwm-apple.o
6 obj-$(CONFIG_PWM_ATMEL) += pwm-atmel.o
7 obj-$(CONFIG_PWM_ATMEL_HLCDC_PWM) += pwm-atmel-hlcdc.o
8 obj-$(CONFIG_PWM_ATMEL_TCB) += pwm-atmel-tcb.o
9 obj-$(CONFIG_PWM_BCM_IPROC) += pwm-bcm-iproc.o
10 obj-$(CONFIG_PWM_BCM_KONA) += pwm-bcm-kona.o
11 obj-$(CONFIG_PWM_BCM2835) += pwm-bcm2835.o
12 obj-$(CONFIG_PWM_BERLIN) += pwm-berlin.o
13 obj-$(CONFIG_PWM_BRCMSTB) += pwm-brcmstb.o
[all …]
H A Dcore.c85 static int pwm_device_request(struct pwm_device *pwm, const char *label) in pwm_device_request() argument
89 if (test_bit(PWMF_REQUESTED, &pwm->flags)) in pwm_device_request()
92 if (!try_module_get(pwm->chip->ops->owner)) in pwm_device_request()
95 if (pwm->chip->ops->request) { in pwm_device_request()
96 err = pwm->chip->ops->request(pwm->chip, pwm); in pwm_device_request()
98 module_put(pwm->chip->ops->owner); in pwm_device_request()
103 if (pwm->chip->ops->get_state) { in pwm_device_request()
113 err = pwm->chip->ops->get_state(pwm->chip, pwm, &state); in pwm_device_request()
114 trace_pwm_get(pwm, &state, err); in pwm_device_request()
117 pwm->state = state; in pwm_device_request()
[all …]
H A Dpwm-twl.c32 #define TWL4030_PWM_TOGGLE(pwm, x) ((x) << (pwm)) argument
46 #define TWL6030_PWM_TOGGLE(pwm, x) ((x) << (pwm * 3)) argument
60 static int twl_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm, in twl_pwm_config() argument
83 base = pwm->hwpwm * 3; in twl_pwm_config()
89 dev_err(chip->dev, "%s: Failed to configure PWM\n", pwm->label); in twl_pwm_config()
94 static int twl4030_pwm_enable(struct pwm_chip *chip, struct pwm_device *pwm) in twl4030_pwm_enable() argument
103 dev_err(chip->dev, "%s: Failed to read GPBR1\n", pwm->label); in twl4030_pwm_enable()
107 val |= TWL4030_PWM_TOGGLE(pwm->hwpwm, TWL4030_PWMXCLK_ENABLE); in twl4030_pwm_enable()
111 dev_err(chip->dev, "%s: Failed to enable PWM\n", pwm->label); in twl4030_pwm_enable()
113 val |= TWL4030_PWM_TOGGLE(pwm->hwpwm, TWL4030_PWMX_ENABLE); in twl4030_pwm_enable()
[all …]
H A Dsysfs.c19 struct pwm_device *pwm; member
33 return export->pwm; in child_to_pwm_device()
40 const struct pwm_device *pwm = child_to_pwm_device(child); in period_show() local
43 pwm_get_state(pwm, &state); in period_show()
53 struct pwm_device *pwm = export->pwm; in period_store() local
63 pwm_get_state(pwm, &state); in period_store()
65 ret = pwm_apply_might_sleep(pwm, &state); in period_store()
75 const struct pwm_device *pwm = child_to_pwm_device(child); in duty_cycle_show() local
78 pwm_get_state(pwm, &state); in duty_cycle_show()
88 struct pwm_device *pwm = export->pwm; in duty_cycle_store() local
[all …]
H A Dpwm-vt8500.c28 #define REG_CTRL(pwm) (((pwm) << 4) + 0x00) argument
29 #define REG_SCALAR(pwm) (((pwm) << 4) + 0x04) argument
30 #define REG_PERIOD(pwm) (((pwm) << 4) + 0x08) argument
31 #define REG_DUTY(pwm) (((pwm) << 4) + 0x0C) argument
69 static int vt8500_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm, in vt8500_pwm_config() argument
105 writel(prescale, vt8500->base + REG_SCALAR(pwm->hwpwm)); in vt8500_pwm_config()
106 vt8500_pwm_busy_wait(vt8500, pwm->hwpwm, STATUS_SCALAR_UPDATE); in vt8500_pwm_config()
108 writel(pv, vt8500->base + REG_PERIOD(pwm->hwpwm)); in vt8500_pwm_config()
109 vt8500_pwm_busy_wait(vt8500, pwm->hwpwm, STATUS_PERIOD_UPDATE); in vt8500_pwm_config()
111 writel(dc, vt8500->base + REG_DUTY(pwm->hwpwm)); in vt8500_pwm_config()
[all …]
H A Dpwm-twl-led.c74 static int twl4030_pwmled_config(struct pwm_chip *chip, struct pwm_device *pwm, in twl4030_pwmled_config() argument
97 base = pwm->hwpwm * 2 + TWL4030_PWMA_REG; in twl4030_pwmled_config()
103 dev_err(chip->dev, "%s: Failed to configure PWM\n", pwm->label); in twl4030_pwmled_config()
108 static int twl4030_pwmled_enable(struct pwm_chip *chip, struct pwm_device *pwm) in twl4030_pwmled_enable() argument
117 dev_err(chip->dev, "%s: Failed to read LEDEN\n", pwm->label); in twl4030_pwmled_enable()
121 val |= TWL4030_LED_TOGGLE(pwm->hwpwm, TWL4030_LED_PINS); in twl4030_pwmled_enable()
125 dev_err(chip->dev, "%s: Failed to enable PWM\n", pwm->label); in twl4030_pwmled_enable()
133 struct pwm_device *pwm) in twl4030_pwmled_disable() argument
142 dev_err(chip->dev, "%s: Failed to read LEDEN\n", pwm->label); in twl4030_pwmled_disable()
146 val &= ~TWL4030_LED_TOGGLE(pwm->hwpwm, TWL4030_LED_PINS); in twl4030_pwmled_disable()
[all …]
H A Dpwm-lpss.c74 static inline u32 pwm_lpss_read(const struct pwm_device *pwm) in pwm_lpss_read() argument
76 struct pwm_lpss_chip *lpwm = to_lpwm(pwm->chip); in pwm_lpss_read()
78 return readl(lpwm->regs + pwm->hwpwm * PWM_SIZE + PWM); in pwm_lpss_read()
81 static inline void pwm_lpss_write(const struct pwm_device *pwm, u32 value) in pwm_lpss_write() argument
83 struct pwm_lpss_chip *lpwm = to_lpwm(pwm->chip); in pwm_lpss_write()
85 writel(value, lpwm->regs + pwm->hwpwm * PWM_SIZE + PWM); in pwm_lpss_write()
88 static int pwm_lpss_wait_for_update(struct pwm_device *pwm) in pwm_lpss_wait_for_update() argument
90 struct pwm_lpss_chip *lpwm = to_lpwm(pwm->chip); in pwm_lpss_wait_for_update()
91 const void __iomem *addr = lpwm->regs + pwm->hwpwm * PWM_SIZE + PWM; in pwm_lpss_wait_for_update()
109 dev_err(pwm->chip->dev, "PWM_SW_UPDATE was not cleared\n"); in pwm_lpss_wait_for_update()
[all …]
H A Dpwm-stmpe.c39 static int stmpe_24xx_pwm_enable(struct pwm_chip *chip, struct pwm_device *pwm) in stmpe_24xx_pwm_enable() argument
48 pwm->hwpwm); in stmpe_24xx_pwm_enable()
52 value = ret | BIT(pwm->hwpwm); in stmpe_24xx_pwm_enable()
57 pwm->hwpwm); in stmpe_24xx_pwm_enable()
65 struct pwm_device *pwm) in stmpe_24xx_pwm_disable() argument
74 pwm->hwpwm); in stmpe_24xx_pwm_disable()
78 value = ret & ~BIT(pwm->hwpwm); in stmpe_24xx_pwm_disable()
83 pwm->hwpwm); in stmpe_24xx_pwm_disable()
98 static int stmpe_24xx_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm, in stmpe_24xx_pwm_config() argument
112 if (pwm_is_enabled(pwm)) { in stmpe_24xx_pwm_config()
[all …]
H A Dpwm-jz4740.c50 static int jz4740_pwm_request(struct pwm_chip *chip, struct pwm_device *pwm) in jz4740_pwm_request() argument
57 if (!jz4740_pwm_can_use_chn(jz, pwm->hwpwm)) in jz4740_pwm_request()
60 snprintf(name, sizeof(name), "timer%u", pwm->hwpwm); in jz4740_pwm_request()
74 pwm_set_chip_data(pwm, clk); in jz4740_pwm_request()
79 static void jz4740_pwm_free(struct pwm_chip *chip, struct pwm_device *pwm) in jz4740_pwm_free() argument
81 struct clk *clk = pwm_get_chip_data(pwm); in jz4740_pwm_free()
87 static int jz4740_pwm_enable(struct pwm_chip *chip, struct pwm_device *pwm) in jz4740_pwm_enable() argument
92 regmap_set_bits(jz->map, TCU_REG_TCSRc(pwm->hwpwm), TCU_TCSR_PWM_EN); in jz4740_pwm_enable()
95 regmap_write(jz->map, TCU_REG_TESR, BIT(pwm->hwpwm)); in jz4740_pwm_enable()
100 static void jz4740_pwm_disable(struct pwm_chip *chip, struct pwm_device *pwm) in jz4740_pwm_disable() argument
[all …]
H A Dpwm-samsung.c121 struct pwm_device *pwm) in __pwm_samsung_manual_update() argument
123 unsigned int tcon_chan = to_tcon_channel(pwm->hwpwm); in __pwm_samsung_manual_update()
134 static void pwm_samsung_set_divisor(struct samsung_pwm_chip *pwm, in pwm_samsung_set_divisor() argument
142 bits = (fls(divisor) - 1) - pwm->variant.div_base; in pwm_samsung_set_divisor()
146 reg = readl(pwm->base + REG_TCFG1); in pwm_samsung_set_divisor()
149 writel(reg, pwm->base + REG_TCFG1); in pwm_samsung_set_divisor()
228 static int pwm_samsung_request(struct pwm_chip *chip, struct pwm_device *pwm) in pwm_samsung_request() argument
233 if (!(our_chip->variant.output_mask & BIT(pwm->hwpwm))) { in pwm_samsung_request()
236 pwm->hwpwm); in pwm_samsung_request()
244 pwm_set_chip_data(pwm, our_chan); in pwm_samsung_request()
[all …]
H A Dpwm-crc.c54 static int crc_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm, in crc_pwm_apply() argument
69 if (pwm_is_enabled(pwm) && !state->enabled) { in crc_pwm_apply()
77 if (pwm_get_duty_cycle(pwm) != state->duty_cycle || in crc_pwm_apply()
78 pwm_get_period(pwm) != state->period) { in crc_pwm_apply()
90 if (pwm_is_enabled(pwm) && state->enabled && in crc_pwm_apply()
91 pwm_get_period(pwm) != state->period) { in crc_pwm_apply()
100 if (pwm_get_period(pwm) != state->period || in crc_pwm_apply()
101 pwm_is_enabled(pwm) != state->enabled) { in crc_pwm_apply()
113 if (!pwm_is_enabled(pwm) && state->enabled) { in crc_pwm_apply()
124 static int crc_pwm_get_state(struct pwm_chip *chip, struct pwm_device *pwm, in crc_pwm_get_state() argument
[all …]
H A Dpwm-berlin.c73 static int berlin_pwm_request(struct pwm_chip *chip, struct pwm_device *pwm) in berlin_pwm_request() argument
81 return pwm_set_chip_data(pwm, channel); in berlin_pwm_request()
84 static void berlin_pwm_free(struct pwm_chip *chip, struct pwm_device *pwm) in berlin_pwm_free() argument
86 struct berlin_pwm_channel *channel = pwm_get_chip_data(pwm); in berlin_pwm_free()
91 static int berlin_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm, in berlin_pwm_config() argument
116 value = berlin_pwm_readl(bpc, pwm->hwpwm, BERLIN_PWM_CONTROL); in berlin_pwm_config()
121 berlin_pwm_writel(bpc, pwm->hwpwm, value, BERLIN_PWM_CONTROL); in berlin_pwm_config()
123 berlin_pwm_writel(bpc, pwm->hwpwm, duty, BERLIN_PWM_DUTY); in berlin_pwm_config()
124 berlin_pwm_writel(bpc, pwm->hwpwm, period, BERLIN_PWM_TCNT); in berlin_pwm_config()
130 struct pwm_device *pwm, in berlin_pwm_set_polarity() argument
[all …]
H A Dpwm-hibvt.c83 static void hibvt_pwm_enable(struct pwm_chip *chip, struct pwm_device *pwm) in hibvt_pwm_enable() argument
87 hibvt_pwm_set_bits(hi_pwm_chip->base, PWM_CTRL_ADDR(pwm->hwpwm), in hibvt_pwm_enable()
91 static void hibvt_pwm_disable(struct pwm_chip *chip, struct pwm_device *pwm) in hibvt_pwm_disable() argument
95 hibvt_pwm_set_bits(hi_pwm_chip->base, PWM_CTRL_ADDR(pwm->hwpwm), in hibvt_pwm_disable()
99 static void hibvt_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm, in hibvt_pwm_config() argument
110 hibvt_pwm_set_bits(hi_pwm_chip->base, PWM_CFG0_ADDR(pwm->hwpwm), in hibvt_pwm_config()
113 hibvt_pwm_set_bits(hi_pwm_chip->base, PWM_CFG1_ADDR(pwm->hwpwm), in hibvt_pwm_config()
118 struct pwm_device *pwm, in hibvt_pwm_set_polarity() argument
124 hibvt_pwm_set_bits(hi_pwm_chip->base, PWM_CTRL_ADDR(pwm->hwpwm), in hibvt_pwm_set_polarity()
127 hibvt_pwm_set_bits(hi_pwm_chip->base, PWM_CTRL_ADDR(pwm->hwpwm), in hibvt_pwm_set_polarity()
[all …]
H A Dpwm-mediatek.c77 struct pwm_device *pwm) in pwm_mediatek_clk_enable() argument
90 ret = clk_prepare_enable(pc->clk_pwms[pwm->hwpwm]); in pwm_mediatek_clk_enable()
105 struct pwm_device *pwm) in pwm_mediatek_clk_disable() argument
109 clk_disable_unprepare(pc->clk_pwms[pwm->hwpwm]); in pwm_mediatek_clk_disable()
121 static int pwm_mediatek_config(struct pwm_chip *chip, struct pwm_device *pwm, in pwm_mediatek_config() argument
130 ret = pwm_mediatek_clk_enable(chip, pwm); in pwm_mediatek_config()
141 do_div(resolution, clk_get_rate(pc->clk_pwms[pwm->hwpwm])); in pwm_mediatek_config()
152 pwm_mediatek_clk_disable(chip, pwm); in pwm_mediatek_config()
157 if (pc->soc->pwm45_fixup && pwm->hwpwm > 2) { in pwm_mediatek_config()
167 pwm_mediatek_writel(pc, pwm->hwpwm, PWMCON, BIT(15) | clkdiv); in pwm_mediatek_config()
[all …]
H A Dpwm-lpc18xx-sct.c129 struct pwm_device *pwm, in lpc18xx_pwm_set_conflict_res() argument
142 val &= ~LPC18XX_PWM_RES_MASK(pwm->hwpwm); in lpc18xx_pwm_set_conflict_res()
143 val |= LPC18XX_PWM_RES(pwm->hwpwm, action); in lpc18xx_pwm_set_conflict_res()
172 struct pwm_device *pwm, u64 duty_ns) in lpc18xx_pwm_config_duty() argument
175 struct lpc18xx_pwm_data *lpc18xx_data = &lpc18xx_pwm->channeldata[pwm->hwpwm]; in lpc18xx_pwm_config_duty()
193 static int lpc18xx_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm, in lpc18xx_pwm_config() argument
218 pwm->hwpwm); in lpc18xx_pwm_config()
233 lpc18xx_pwm_config_duty(chip, pwm, duty_ns); in lpc18xx_pwm_config()
238 static int lpc18xx_pwm_enable(struct pwm_chip *chip, struct pwm_device *pwm, enum pwm_polarity pola… in lpc18xx_pwm_enable() argument
241 struct lpc18xx_pwm_data *lpc18xx_data = &lpc18xx_pwm->channeldata[pwm->hwpwm]; in lpc18xx_pwm_enable()
[all …]
/openbmc/linux/drivers/clocksource/
H A Dsamsung_pwm_timer.c79 static struct samsung_pwm_clocksource pwm; variable
92 reg = readl(pwm.base + REG_TCFG0); in samsung_timer_set_prescale()
95 writel(reg, pwm.base + REG_TCFG0); in samsung_timer_set_prescale()
107 bits = (fls(divisor) - 1) - pwm.variant.div_base; in samsung_timer_set_divisor()
111 reg = readl(pwm.base + REG_TCFG1); in samsung_timer_set_divisor()
114 writel(reg, pwm.base + REG_TCFG1); in samsung_timer_set_divisor()
129 tcon = readl_relaxed(pwm.base + REG_TCON); in samsung_time_stop()
131 writel_relaxed(tcon, pwm.base + REG_TCON); in samsung_time_stop()
147 tcon = readl_relaxed(pwm.base + REG_TCON); in samsung_time_setup()
152 writel_relaxed(tcnt, pwm.base + REG_TCNTB(channel)); in samsung_time_setup()
[all …]
/openbmc/linux/include/linux/
H A Dpwm.h83 unsigned int pwm; member
102 static inline void pwm_get_state(const struct pwm_device *pwm, in pwm_get_state() argument
105 *state = pwm->state; in pwm_get_state()
108 static inline bool pwm_is_enabled(const struct pwm_device *pwm) in pwm_is_enabled() argument
112 pwm_get_state(pwm, &state); in pwm_is_enabled()
117 static inline void pwm_set_period(struct pwm_device *pwm, u64 period) in pwm_set_period() argument
119 if (pwm) in pwm_set_period()
120 pwm->state.period = period; in pwm_set_period()
123 static inline u64 pwm_get_period(const struct pwm_device *pwm) in pwm_get_period() argument
127 pwm_get_state(pwm, &state); in pwm_get_period()
[all …]
/openbmc/u-boot/doc/device-tree-bindings/pwm/
H A Dpwm.txt8 with a property containing a 'pwm-list':
10 pwm-list ::= <single-pwm> [pwm-list]
11 single-pwm ::= <pwm-phandle> <pwm-specifier>
12 pwm-phandle : phandle to PWM controller node
13 pwm-specifier : array of #pwm-cells specifying the given PWM
18 An optional property "pwm-names" may contain a list of strings to label
19 each of the PWM devices listed in the "pwms" property. If no "pwm-names"
23 "pwm-names" property to map the name of the PWM device requested by the
29 pwm: pwm {
30 #pwm-cells = <2>;
[all …]
/openbmc/linux/Documentation/devicetree/bindings/pwm/
H A Dpwm.txt8 with a property containing a 'pwm-list':
10 pwm-list ::= <single-pwm> [pwm-list]
11 single-pwm ::= <pwm-phandle> <pwm-specifier>
12 pwm-phandle : phandle to PWM controller node
13 pwm-specifier : array of #pwm-cells specifying the given PWM
18 An optional property "pwm-names" may contain a list of strings to label
19 each of the PWM devices listed in the "pwms" property. If no "pwm-names"
23 "pwm-names" property to map the name of the PWM device requested by the
29 pwm: pwm {
30 #pwm-cells = <2>;
[all …]
/openbmc/linux/drivers/input/keyboard/
H A Dlm8323.c147 struct lm8323_pwm pwm[LM8323_NUM_PWMS]; member
351 static void pwm_done(struct lm8323_pwm *pwm) in pwm_done() argument
353 mutex_lock(&pwm->lock); in pwm_done()
354 pwm->running = false; in pwm_done()
355 if (pwm->desired_brightness != pwm->brightness) in pwm_done()
356 schedule_work(&pwm->work); in pwm_done()
357 mutex_unlock(&pwm->lock); in pwm_done()
392 pwm_done(&lm->pwm[i]); in lm8323_irq()
416 static void lm8323_write_pwm_one(struct lm8323_pwm *pwm, int pos, u16 cmd) in lm8323_write_pwm_one() argument
418 lm8323_write(pwm->chip, 4, LM8323_CMD_PWM_WRITE, (pos << 2) | pwm->id, in lm8323_write_pwm_one()
[all …]
/openbmc/u-boot/arch/arm/cpu/armv7/s5p-common/
H A Dpwm.c17 const struct s5p_timer *pwm = in pwm_enable() local
21 tcon = readl(&pwm->tcon); in pwm_enable()
24 writel(tcon, &pwm->tcon); in pwm_enable()
31 const struct s5p_timer *pwm = in pwm_disable() local
35 tcon = readl(&pwm->tcon); in pwm_disable()
38 writel(tcon, &pwm->tcon); in pwm_disable()
60 const struct s5p_timer *pwm = in pwm_config() local
96 writel(tcnt, &pwm->tcntb0 + offset); in pwm_config()
97 writel(tcmp, &pwm->tcmpb0 + offset); in pwm_config()
100 tcon = readl(&pwm->tcon); in pwm_config()
[all …]
/openbmc/u-boot/drivers/pwm/
H A Dpwm-imx.c18 struct pwm_regs *pwm = (struct pwm_regs *)pwm_id_to_reg(pwm_id); in pwm_init() local
20 if (!pwm) in pwm_init()
23 writel(0, &pwm->ir); in pwm_init()
29 struct pwm_regs *pwm = (struct pwm_regs *)pwm_id_to_reg(pwm_id); in pwm_config() local
33 if (!pwm) in pwm_config()
43 writel(cr, &pwm->cr); in pwm_config()
45 writel(duty_cycles, &pwm->sar); in pwm_config()
47 writel(period_cycles, &pwm->pr); in pwm_config()
53 struct pwm_regs *pwm = (struct pwm_regs *)pwm_id_to_reg(pwm_id); in pwm_enable() local
55 if (!pwm) in pwm_enable()
[all …]
/openbmc/linux/include/trace/events/
H A Dpwm.h3 #define TRACE_SYSTEM pwm
11 DECLARE_EVENT_CLASS(pwm,
13 TP_PROTO(struct pwm_device *pwm, const struct pwm_state *state, int err),
15 TP_ARGS(pwm, state, err),
18 __field(struct pwm_device *, pwm)
27 __entry->pwm = pwm;
36 __entry->pwm, __entry->period, __entry->duty_cycle,
41 DEFINE_EVENT(pwm, pwm_apply,
43 TP_PROTO(struct pwm_device *pwm, const struct pwm_state *state, int err),
45 TP_ARGS(pwm, state, err)
[all …]
/openbmc/u-boot/drivers/video/exynos/
H A Dexynos_pwm_bl.c19 static struct pwm_backlight_data *pwm; variable
23 int brightness = pwm->brightness; in exynos_pwm_backlight_update_status()
24 int max = pwm->max_brightness; in exynos_pwm_backlight_update_status()
27 pwm_config(pwm->pwm_id, 0, pwm->period); in exynos_pwm_backlight_update_status()
28 pwm_disable(pwm->pwm_id); in exynos_pwm_backlight_update_status()
30 pwm_config(pwm->pwm_id, in exynos_pwm_backlight_update_status()
31 brightness * pwm->period / max, pwm->period); in exynos_pwm_backlight_update_status()
32 pwm_enable(pwm->pwm_id); in exynos_pwm_backlight_update_status()
39 pwm = pd; in exynos_pwm_backlight_init()
/openbmc/linux/drivers/hwmon/
H A Dmlxreg-fan.c110 struct mlxreg_fan_pwm pwm[MLXREG_FAN_MAX_PWM]; member
125 struct mlxreg_fan_pwm *pwm; in mlxreg_fan_read() local
182 pwm = &fan->pwm[channel]; in mlxreg_fan_read()
185 err = regmap_read(fan->regmap, pwm->reg, &regval); in mlxreg_fan_read()
209 struct mlxreg_fan_pwm *pwm; in mlxreg_fan_write() local
218 pwm = &fan->pwm[channel]; in mlxreg_fan_write()
221 pwm->last_hwmon_state = MLXREG_FAN_PWM_DUTY2STATE(val); in mlxreg_fan_write()
226 if (pwm->last_hwmon_state >= pwm->last_thermal_state) in mlxreg_fan_write()
227 return mlxreg_fan_set_cur_state(pwm->cdev, in mlxreg_fan_write()
228 pwm->last_hwmon_state); in mlxreg_fan_write()
[all …]

12345678910>>...51