Lines Matching full:stmpe

11 #include <linux/mfd/stmpe.h>
29 struct stmpe *stmpe; member
45 ret = stmpe_reg_read(stmpe_pwm->stmpe, STMPE24XX_PWMCS); in stmpe_24xx_pwm_enable()
54 ret = stmpe_reg_write(stmpe_pwm->stmpe, STMPE24XX_PWMCS, value); in stmpe_24xx_pwm_enable()
71 ret = stmpe_reg_read(stmpe_pwm->stmpe, STMPE24XX_PWMCS); in stmpe_24xx_pwm_disable()
80 ret = stmpe_reg_write(stmpe_pwm->stmpe, STMPE24XX_PWMCS, value); in stmpe_24xx_pwm_disable()
87 /* STMPE 24xx PWM instructions */
121 if (stmpe_pwm->stmpe->partnum == STMPE2401 || in stmpe_24xx_pwm_config()
122 stmpe_pwm->stmpe->partnum == STMPE2403) in stmpe_24xx_pwm_config()
125 ret = stmpe_set_altfunc(stmpe_pwm->stmpe, BIT(pin), in stmpe_24xx_pwm_config()
157 if (stmpe_pwm->stmpe->partnum == STMPE2401) in stmpe_24xx_pwm_config()
160 if (stmpe_pwm->stmpe->partnum == STMPE2403) in stmpe_24xx_pwm_config()
165 if (stmpe_pwm->stmpe->partnum == STMPE2401) in stmpe_24xx_pwm_config()
168 if (stmpe_pwm->stmpe->partnum == STMPE2403) in stmpe_24xx_pwm_config()
197 } else if (stmpe_pwm->stmpe->partnum == STMPE2403) { in stmpe_24xx_pwm_config()
201 } else if (stmpe_pwm->stmpe->partnum == STMPE2401) { in stmpe_24xx_pwm_config()
234 ret = stmpe_reg_write(stmpe_pwm->stmpe, offset, value); in stmpe_24xx_pwm_config()
243 ret = stmpe_reg_write(stmpe_pwm->stmpe, offset, value); in stmpe_24xx_pwm_config()
295 struct stmpe *stmpe = dev_get_drvdata(pdev->dev.parent); in stmpe_pwm_probe() local
303 stmpe_pwm->stmpe = stmpe; in stmpe_pwm_probe()
306 if (stmpe->partnum == STMPE2401 || stmpe->partnum == STMPE2403) { in stmpe_pwm_probe()
310 if (stmpe->partnum == STMPE1601) in stmpe_pwm_probe()
313 dev_err(&pdev->dev, "Unknown STMPE PWM\n"); in stmpe_pwm_probe()
318 ret = stmpe_enable(stmpe, STMPE_BLOCK_PWM); in stmpe_pwm_probe()
324 stmpe_disable(stmpe, STMPE_BLOCK_PWM); in stmpe_pwm_probe()
333 .name = "stmpe-pwm",