mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-17 02:08:38 +00:00
3227c85fe7
This bus controller is used to communicate with an X-Powers AXP PMIC. Currently, various drivers access PMIC registers through a platform- specific non-DM "pmic_bus" interface, which depends on the legacy I2C framework. In order to convert those drivers to use DM_PMIC, this bus needs a DM_I2C driver. Refactor the rsb functions to take the base address as a parameter, and implement both the existing interface (which is still needed in SPL) and the DM_I2C interface on top of them. The register for switching between I2C/P2WI/RSB mode is the same across all PMIC variants, so move that to the common header. There are only a couple of pairs of hardware/runtime addresses used across all PMIC variants. So far the code expected only the "primary" pair, but some PMICs like the AXP305 and AXP805 use the secondary pair, so add support for that to the DM driver as well. Signed-off-by: Samuel Holland <samuel@sholland.org> Reviewed-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
16 lines
415 B
Text
16 lines
415 B
Text
CONFIG_ARM=y
|
|
CONFIG_ARCH_SUNXI=y
|
|
CONFIG_DEFAULT_DEVICE_TREE="sun9i-a80-optimus"
|
|
CONFIG_SPL=y
|
|
CONFIG_MACH_SUN9I=y
|
|
CONFIG_DRAM_CLK=672
|
|
CONFIG_MMC0_CD_PIN="PH18"
|
|
CONFIG_MMC_SUNXI_SLOT_EXTRA=2
|
|
CONFIG_USB0_VBUS_PIN="AXP0-VBUS-ENABLE"
|
|
CONFIG_USB0_VBUS_DET="AXP0-VBUS-DETECT"
|
|
CONFIG_USB0_ID_DET="PH3"
|
|
CONFIG_USB1_VBUS_PIN="PH4"
|
|
CONFIG_USB3_VBUS_PIN="PH5"
|
|
CONFIG_SYS_I2C_SUN8I_RSB=y
|
|
CONFIG_AXP_GPIO=y
|
|
CONFIG_AXP809_POWER=y
|