| Message ID | 20251006133525.2457171-2-u.kleine-koenig@baylibre.com |
|---|---|
| State | Accepted |
| Headers | show |
| Series | pwm: Use %u to printf unsigned int pwm_chip::npwm and pwm_chip::id | expand |
On Mon, Oct 06, 2025 at 03:35:26PM +0200, Uwe Kleine-König wrote: > %u is the right conversion specifier to emit an unsigned int value. > > Fixes: 62099abf67a2 ("pwm: Add debugfs interface") > Fixes: 0360a4873372 ("pwm: Mention PWM chip ID in /sys/kernel/debug/pwm") > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com> > --- > Hello, > > please tell me if this patch make a difference for one of your machines > :-) > > The patch this depends on is > https://lore.kernel.org/r/20250926165702.321514-2-u.kleine-koenig@baylibre.com > . I applied this patch to https://git.kernel.org/pub/scm/linux/kernel/git/ukleinek/linux.git pwm/for-nexxt as material for the next merge window. It will migrate to my pwm/for-next branch that is pulled into next after the merge window closes. Best regards Uwe
diff --git a/drivers/pwm/core.c b/drivers/pwm/core.c index 5b75f4a08496..7dd1cf2ba402 100644 --- a/drivers/pwm/core.c +++ b/drivers/pwm/core.c @@ -2696,7 +2696,7 @@ static int pwm_seq_show(struct seq_file *s, void *v) { struct pwm_chip *chip = v; - seq_printf(s, "%s%d: %s/%s, npwm: %d\n", + seq_printf(s, "%s%u: %s/%s, npwm: %u\n", (char *)s->private, chip->id, pwmchip_parent(chip)->bus ? pwmchip_parent(chip)->bus->name : "no-bus", dev_name(pwmchip_parent(chip)), chip->npwm);
%u is the right conversion specifier to emit an unsigned int value. Fixes: 62099abf67a2 ("pwm: Add debugfs interface") Fixes: 0360a4873372 ("pwm: Mention PWM chip ID in /sys/kernel/debug/pwm") Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com> --- Hello, please tell me if this patch make a difference for one of your machines :-) The patch this depends on is https://lore.kernel.org/r/20250926165702.321514-2-u.kleine-koenig@baylibre.com . Best regards Uwe drivers/pwm/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) base-commit: 8f2689f194b8d1bff41150ae316abdfccf191309 prerequisite-patch-id: 569104417dd341baa45f7c1ff09c5a73062a2fb4