Skip to content

drivers/pwm/it51xxx: implement pwm driver #88471

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

RuibinChang
Copy link
Collaborator

Implement pwm driver for ITE it51xxx series chip.

@RuibinChang
Copy link
Collaborator Author

rebase to resolve conflicts

@RuibinChang
Copy link
Collaborator Author

rebase to resolve conflicts

@RuibinChang RuibinChang force-pushed the it51xxx_evb_pwm branch 2 times, most recently from e25f117 to ee9bea9 Compare April 24, 2025 07:17
@RuibinChang
Copy link
Collaborator Author

rebase to resolve conflicts

@RuibinChang
Copy link
Collaborator Author

rebase to resolve conflicts

@RuibinChang
Copy link
Collaborator Author

Hi @anangl, any comments will be appreciated.

Dino-Li
Dino-Li previously approved these changes Apr 30, 2025
@kartben kartben requested a review from Copilot May 2, 2025 07:58
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements a new PWM driver for the ITE it51xxx series chip.

  • Introduces a header file with device binding macros and definitions.
  • Adds a DTS binding YAML file defining device properties and PWM cells.
  • Implements the PWM driver in a new source file with configuration, initialization, and cycle setting logic.

Reviewed Changes

Copilot reviewed 3 out of 8 changed files in this pull request and generated 1 comment.

File Description
include/zephyr/dt-bindings/pwm/it51xxx_pwm.h Added binding definitions and macro constants for PWM configuration.
dts/bindings/pwm/ite,it51xxx-pwm.yaml Defined device properties and bindings for the PWM controller.
drivers/pwm/pwm_ite_it51xxx.c Implemented the PWM driver including initialization and cycle logic.
Files not reviewed (5)
  • boards/ite/it515xx_evb/it515xx_evb.dts: Language not supported
  • drivers/pwm/CMakeLists.txt: Language not supported
  • drivers/pwm/Kconfig: Language not supported
  • drivers/pwm/Kconfig.it51xxx: Language not supported
  • dts/riscv/ite/it51xxx.dtsi: Language not supported

* Provides a type to hold PWM configuration flags.
*
* The upper 8 bits are reserved for SoC specific flags.
* Output onpe-drain flag [ 8 ]
Copy link
Preview

Copilot AI May 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo in the comment: 'onpe-drain' should be corrected to 'open-drain'.

Suggested change
* Output onpe-drain flag [ 8 ]
* Output open-drain flag [ 8 ]

Copilot uses AI. Check for mistakes.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Implement pwm driver for ITE it51xxx series chip.

Signed-off-by: Ruibin Chang <[email protected]>
@Dino-Li Dino-Li requested a review from fabiobaltieri May 2, 2025 09:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: PWM Pulse Width Modulation area: RISCV RISCV Architecture (32-bit & 64-bit) platform: ITE ITE
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants