royzah opened a new pull request, #20437:
URL: https://github.com/apache/nuttx/pull/20437

   *Note: Please adhere to [Contributing 
Guidelines](https://github.com/apache/nuttx/blob/master/CONTRIBUTING.md).*
   
   ## Summary
   
   A channel number of zero marks an unused slot, as 
`Documentation/components/drivers/character/timers/pwm.rst` says. The i.MX9 TPM 
and FlexIO `pwm_start()` handed every slot to `pwm_update_duty()`, which 
refuses channel 0, so a caller that fills only some slots got `EINVAL`. Skip 
those slots, as the stm32 and n32 drivers do.
   
   ## Impact
   
   i.MX9 TPM and FlexIO PWM only. Callers that fill every slot see no change.
   
   ## Testing
   
   Host: Ubuntu 24.04, x86_64. Builds in 
`ghcr.io/apache/nuttx/apache-nuttx-ci-linux`.
   
   | Where | Result |
   | --- | --- |
   | `imx93-evk:nsh`, `imx93-evk:knsh` (TPM and FlexIO PWM enabled) | build |
   | i.MX93 board, PX4's tone alarm, which fills only slot 0 | `tune_control 
play`: no `PWMIOC_START failed` |
   
   `tools/checkpatch.sh -c -u -m -g` clean.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to