Skip to content

Conversation

@xakep-amatop
Copy link
Contributor

Add support of voltage control to Renesas PFC driver. Voltage register mappings have been added to r8a77951 and r8a77961 SoCs.

Allow 'power-source' property for 'renesas,rcar-pfc' node. This property will be used for configuring IO voltage on appropriate pin. For now it is possible to have only two voltages: 1.8 and 3.3.

Note: it is possible to change voltage only for SD/MMC pins on r8a77951 and r8a77961 SoCs.

@xakep-amatop
Copy link
Contributor Author

This pull request is a rebase of the following pull request: #60444.

The voltage control functionality has been moved from the SOC(s) to the PFC driver.

@xakep-amatop xakep-amatop marked this pull request as ready for review December 22, 2023 11:10
@zephyrbot zephyrbot added platform: Renesas R-Car Renesas R-Car area: Pinctrl area: Devicetree Binding PR modifies or adds a Device Tree binding area: ARM64 ARM (64-bit) Architecture labels Dec 22, 2023
Comment on lines 11 to 17
Copy link
Member

Choose a reason for hiding this comment

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

use depends on for single if/endif item. question: what is the reason to guard this feature?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I believe that adding a PINCTRL_RCAR_PFC check here is unnecessary since the file where the configuration is used is compiled exclusively for PINCTRL_RCAR_PFC. So, I'll remove the checking of PINCTRL_RCAR_PFC from this file.

If you are inquiring about the reason behind the need for the PINCTRL_RCAR_VOLTAGE_CONTROL config, a partial answer can be found here: #60444 (comment). The R-Car PFC driver is utilized for both Gen4 and Gen3 platforms, and currently, the voltage control table has been added only for Gen3.

While it is possible to add a check, such as SOC_SERIES_RCAR_GEN3, to the driver code, but as for me, using an additional config provides a clearer approach.

@xakep-amatop xakep-amatop force-pushed the rcar-pfc-add-support-of-voltage-control branch from 848a076 to c44e782 Compare January 12, 2024 13:28
@xakep-amatop xakep-amatop requested a review from gmarull January 12, 2024 13:28
@xakep-amatop
Copy link
Contributor Author

@aaillet @gmarull Could you please review this PR?

Copy link
Member

Choose a reason for hiding this comment

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

depends on PINCTRL_RCAR_PFC

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

Add support of voltage control to Renesas PFC driver. Voltage register
mappings have been added to r8a77951 and r8a77961 SoCs.

Allow 'power-source' property for 'renesas,rcar-pfc' node. This property
will be used for configuring IO voltage on appropriate pin. For now it
is possible to have only two voltages: 1.8 and 3.3.

Note: it is possible to change voltage only for SD/MMC pins on r8a77951
      and r8a77961 SoCs.

Signed-off-by: Mykola Kvach <[email protected]>
@xakep-amatop xakep-amatop force-pushed the rcar-pfc-add-support-of-voltage-control branch from c44e782 to 138bf75 Compare January 17, 2024 15:19
@xakep-amatop xakep-amatop requested a review from gmarull January 17, 2024 15:20
@carlescufi carlescufi merged commit 72758f9 into zephyrproject-rtos:main Jan 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: ARM64 ARM (64-bit) Architecture area: Devicetree Binding PR modifies or adds a Device Tree binding area: Pinctrl platform: Renesas R-Car Renesas R-Car

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants