Searched refs:rcar_pwm (Results 1 - 1 of 1) sorted by relevance

/linux-4.4.14/drivers/pwm/
H A Dpwm-rcar.c209 struct rcar_pwm_chip *rcar_pwm; rcar_pwm_probe() local
213 rcar_pwm = devm_kzalloc(&pdev->dev, sizeof(*rcar_pwm), GFP_KERNEL); rcar_pwm_probe()
214 if (rcar_pwm == NULL) rcar_pwm_probe()
218 rcar_pwm->base = devm_ioremap_resource(&pdev->dev, res); rcar_pwm_probe()
219 if (IS_ERR(rcar_pwm->base)) rcar_pwm_probe()
220 return PTR_ERR(rcar_pwm->base); rcar_pwm_probe()
222 rcar_pwm->clk = devm_clk_get(&pdev->dev, NULL); rcar_pwm_probe()
223 if (IS_ERR(rcar_pwm->clk)) { rcar_pwm_probe()
225 return PTR_ERR(rcar_pwm->clk); rcar_pwm_probe()
228 platform_set_drvdata(pdev, rcar_pwm); rcar_pwm_probe()
230 rcar_pwm->chip.dev = &pdev->dev; rcar_pwm_probe()
231 rcar_pwm->chip.ops = &rcar_pwm_ops; rcar_pwm_probe()
232 rcar_pwm->chip.base = -1; rcar_pwm_probe()
233 rcar_pwm->chip.npwm = 1; rcar_pwm_probe()
235 ret = pwmchip_add(&rcar_pwm->chip); rcar_pwm_probe()
248 struct rcar_pwm_chip *rcar_pwm = platform_get_drvdata(pdev); rcar_pwm_remove() local
252 return pwmchip_remove(&rcar_pwm->chip); rcar_pwm_remove()

Completed in 104 milliseconds