Lines Matching full:stmpe
11 #include <linux/mfd/stmpe.h>
29 struct stmpe *stmpe; member
44 ret = stmpe_reg_read(stmpe_pwm->stmpe, STMPE24XX_PWMCS); in stmpe_24xx_pwm_enable()
53 ret = stmpe_reg_write(stmpe_pwm->stmpe, STMPE24XX_PWMCS, value); in stmpe_24xx_pwm_enable()
70 ret = stmpe_reg_read(stmpe_pwm->stmpe, STMPE24XX_PWMCS); in stmpe_24xx_pwm_disable()
79 ret = stmpe_reg_write(stmpe_pwm->stmpe, STMPE24XX_PWMCS, value); in stmpe_24xx_pwm_disable()
86 /* STMPE 24xx PWM instructions */
120 if (stmpe_pwm->stmpe->partnum == STMPE2401 || in stmpe_24xx_pwm_config()
121 stmpe_pwm->stmpe->partnum == STMPE2403) in stmpe_24xx_pwm_config()
124 ret = stmpe_set_altfunc(stmpe_pwm->stmpe, BIT(pin), in stmpe_24xx_pwm_config()
156 if (stmpe_pwm->stmpe->partnum == STMPE2401) in stmpe_24xx_pwm_config()
159 if (stmpe_pwm->stmpe->partnum == STMPE2403) in stmpe_24xx_pwm_config()
164 if (stmpe_pwm->stmpe->partnum == STMPE2401) in stmpe_24xx_pwm_config()
167 if (stmpe_pwm->stmpe->partnum == STMPE2403) in stmpe_24xx_pwm_config()
196 } else if (stmpe_pwm->stmpe->partnum == STMPE2403) { in stmpe_24xx_pwm_config()
200 } else if (stmpe_pwm->stmpe->partnum == STMPE2401) { in stmpe_24xx_pwm_config()
233 ret = stmpe_reg_write(stmpe_pwm->stmpe, offset, value); in stmpe_24xx_pwm_config()
242 ret = stmpe_reg_write(stmpe_pwm->stmpe, offset, value); in stmpe_24xx_pwm_config()
293 struct stmpe *stmpe = dev_get_drvdata(pdev->dev.parent); in stmpe_pwm_probe() local
298 switch (stmpe->partnum) { in stmpe_pwm_probe()
307 "Unknown STMPE PWM\n"); in stmpe_pwm_probe()
315 stmpe_pwm->stmpe = stmpe; in stmpe_pwm_probe()
319 ret = stmpe_enable(stmpe, STMPE_BLOCK_PWM); in stmpe_pwm_probe()
325 stmpe_disable(stmpe, STMPE_BLOCK_PWM); in stmpe_pwm_probe()
334 .name = "stmpe-pwm",