Home
last modified time | relevance | path

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

/linux-6.12.1/drivers/pwm/
Dpwm-lpss.c38 .npwm = 1,
46 .npwm = 1,
55 .npwm = 4,
64 .npwm = 4,
257 if (WARN_ON(info->npwm > LPSS_MAX_PWMS)) in devm_pwm_lpss_probe()
260 chip = devm_pwmchip_alloc(dev, info->npwm, sizeof(*lpwm)); in devm_pwm_lpss_probe()
280 for (i = 0; i < lpwm->info->npwm; i++) { in devm_pwm_lpss_probe()
Dpwm-cros-ec.c221 unsigned int i, npwm; in cros_ec_pwm_probe() local
229 npwm = CROS_EC_PWM_DT_COUNT; in cros_ec_pwm_probe()
234 npwm = ret; in cros_ec_pwm_probe()
237 chip = devm_pwmchip_alloc(dev, npwm, sizeof(*ec_pwm)); in cros_ec_pwm_probe()
256 for (i = 0; i < npwm; ++i) in cros_ec_pwm_probe()
259 dev_dbg(dev, "Probed %u PWMs\n", chip->npwm); in cros_ec_pwm_probe()
Dcore.c432 if (!chip || index >= chip->npwm) in pwm_request_from_chip()
798 if (hwpwm >= chip->npwm) in export_store()
825 if (hwpwm >= chip->npwm) in unexport_store()
839 return sysfs_emit(buf, "%u\n", chip->npwm); in npwm_show()
841 static DEVICE_ATTR_RO(npwm);
887 static int pwm_class_resume_npwm(struct device *pwmchip_dev, unsigned int npwm) in pwm_class_resume_npwm() argument
893 for (i = 0; i < npwm; i++) { in pwm_class_resume_npwm()
924 for (i = 0; i < chip->npwm; i++) { in pwm_class_suspend()
963 return pwm_class_resume_npwm(pwmchip_dev, chip->npwm); in pwm_class_resume()
978 for (i = 0; i < chip->npwm; i++) { in pwmchip_sysfs_unexport()
[all …]
Dpwm-sprd.c253 int ret, npwm; in sprd_pwm_probe() local
255 npwm = sprd_pwm_clk_init(&pdev->dev, chn); in sprd_pwm_probe()
256 if (npwm < 0) in sprd_pwm_probe()
257 return npwm; in sprd_pwm_probe()
259 chip = devm_pwmchip_alloc(&pdev->dev, npwm, sizeof(*spc)); in sprd_pwm_probe()
Dpwm-sun4i.c80 unsigned int npwm; member
331 .npwm = 2,
336 .npwm = 2,
341 .npwm = 1,
347 .npwm = 1,
353 .npwm = 2,
395 chip = devm_pwmchip_alloc(&pdev->dev, data->npwm, sizeof(*sun4ichip)); in sun4i_pwm_probe()
Dpwm-mxs.c127 u32 npwm; in mxs_pwm_probe() local
130 ret = of_property_read_u32(np, "fsl,pwm-number", &npwm); in mxs_pwm_probe()
136 chip = devm_pwmchip_alloc(&pdev->dev, npwm, sizeof(*mxs)); in mxs_pwm_probe()
Dpwm-twl-led.c349 unsigned int npwm; in twl_pwmled_probe() local
354 npwm = 2; in twl_pwmled_probe()
357 npwm = 1; in twl_pwmled_probe()
360 chip = devm_pwmchip_alloc(&pdev->dev, npwm, sizeof(*twl)); in twl_pwmled_probe()
Dpwm-sifive.c261 for (i = 0; i < chip->npwm; ++i) { in pwm_sifive_probe()
299 dev_dbg(dev, "SiFive PWM chip registered %d PWMs\n", chip->npwm); in pwm_sifive_probe()
324 for (ch = 0; ch < chip->npwm; ch++) { in pwm_sifive_remove()
Dpwm-imx-tpm.c346 unsigned int npwm; in pwm_imx_tpm_probe() local
360 npwm = FIELD_GET(PWM_IMX_TPM_PARAM_CHAN, val); in pwm_imx_tpm_probe()
362 chip = devm_pwmchip_alloc(&pdev->dev, npwm, sizeof(*tpm)); in pwm_imx_tpm_probe()
Dpwm-stm32.c130 if (pwm->chip->npwm < 2) in stm32_pwm_raw_capture()
649 unsigned int npwm, num_enabled; in stm32_pwm_probe() local
653 npwm = stm32_pwm_detect_channels(ddata->regmap, &num_enabled); in stm32_pwm_probe()
655 chip = devm_pwmchip_alloc(dev, npwm, sizeof(*priv)); in stm32_pwm_probe()
714 for (i = 0; i < chip->npwm; i++) { in stm32_pwm_suspend()
Dpwm-img.c363 for (i = 0; i < chip->npwm; i++) in img_pwm_suspend()
385 for (i = 0; i < chip->npwm; i++) in img_pwm_resume()
391 for (i = 0; i < chip->npwm; i++) in img_pwm_resume()
Dpwm-berlin.c234 for (i = 0; i < chip->npwm; i++) { in berlin_pwm_suspend()
259 for (i = 0; i < chip->npwm; i++) { in berlin_pwm_resume()
Dpwm-fsl-ftm.c470 for (i = 0; i < chip->npwm; i++) { in fsl_pwm_suspend()
494 for (i = 0; i < chip->npwm; i++) { in fsl_pwm_resume()
Dpwm-tiehrpwm.c563 for (i = 0; i < chip->npwm; i++) { in ehrpwm_pwm_suspend()
581 for (i = 0; i < chip->npwm; i++) { in ehrpwm_pwm_resume()
Dpwm-jz4740.c40 u32 pwm_channels_mask = GENMASK(chip->npwm - 1, 2); in jz4740_pwm_can_use_chn()
Dpwm-bcm-iproc.c216 for (i = 0; i < chip->npwm; i++) { in iproc_pwmc_probe()
Dpwm-hibvt.c236 for (i = 0; i < chip->npwm; i++) { in hibvt_pwm_probe()
Dpwm-bcm-kona.c306 for (chan = 0; chan < chip->npwm; chan++) in kona_pwmc_probe()
Dpwm-atmel.c472 cnt = bitmap_weight(&sr, chip->npwm); in atmel_pwm_enable_clk_if_on()
/linux-6.12.1/include/linux/
Dpwm.h285 unsigned int npwm; member
293 struct pwm_device pwms[] __counted_by(npwm);
398 struct pwm_chip *pwmchip_alloc(struct device *parent, unsigned int npwm, size_t sizeof_priv);
399 struct pwm_chip *devm_pwmchip_alloc(struct device *parent, unsigned int npwm, size_t sizeof_priv);
467 unsigned int npwm, in pwmchip_alloc() argument
474 unsigned int npwm, in devm_pwmchip_alloc() argument
477 return pwmchip_alloc(parent, npwm, sizeof_priv); in devm_pwmchip_alloc()
/linux-6.12.1/drivers/staging/greybus/
Dpwm.c250 int ret, npwm; in gb_pwm_probe() local
266 npwm = ret; in gb_pwm_probe()
268 chip = pwmchip_alloc(&gbphy_dev->dev, npwm, sizeof(*pwmc)); in gb_pwm_probe()
/linux-6.12.1/include/linux/platform_data/x86/
Dpwm-lpss.h15 unsigned int npwm; member
/linux-6.12.1/Documentation/ABI/testing/
Dsysfs-class-pwm19 What: /sys/class/pwm/pwmchip<N>/npwm
32 Value is between 0 and /sys/class/pwm/pwmchipN/npwm - 1.
/linux-6.12.1/Documentation/driver-api/
Dpwm.rst101 npwm
110 The PWM channels are numbered using a per-chip index from 0 to npwm-1.
/linux-6.12.1/drivers/pinctrl/intel/
Dpinctrl-intel.c1532 .npwm = 1, in intel_pinctrl_probe_pwm()