From 3ad2737ee3faa291f75176b667ac3ad4408b023d Mon Sep 17 00:00:00 2001 From: Ying Zhang Date: Fri, 31 Oct 2014 18:06:18 +0800 Subject: powerpc/t208xqds: VID support The fuse status register provides the values from on-chip voltage ID efuses programmed at the factory. These values define the voltage requirements for the chip. u-boot reads FUSESR and translates the values into the appropriate commands to set the voltage output value of an external voltage regulator. Signed-off-by: Ying Zhang Reviewed-by: York Sun --- include/configs/T208xQDS.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'include/configs') diff --git a/include/configs/T208xQDS.h b/include/configs/T208xQDS.h index ebc32f2bd4..d1fe78ef0c 100644 --- a/include/configs/T208xQDS.h +++ b/include/configs/T208xQDS.h @@ -494,6 +494,23 @@ unsigned long get_board_ddr_clk(void); #define I2C_MUX_PCA_ADDR_SEC2 0x76 /* I2C bus multiplexer,secondary 2 */ #define I2C_MUX_CH_DEFAULT 0x8 +#define I2C_MUX_CH_VOL_MONITOR 0xa + +/* Voltage monitor on channel 2*/ +#define I2C_VOL_MONITOR_ADDR 0x40 +#define I2C_VOL_MONITOR_BUS_V_OFFSET 0x2 +#define I2C_VOL_MONITOR_BUS_V_OVF 0x1 +#define I2C_VOL_MONITOR_BUS_V_SHIFT 3 + +#define CONFIG_VID_FLS_ENV "t208xqds_vdd_mv" +#ifndef CONFIG_SPL_BUILD +#define CONFIG_VID +#endif +#define CONFIG_VOL_MONITOR_IR36021_SET +#define CONFIG_VOL_MONITOR_IR36021_READ +/* The lowest and highest voltage allowed for T208xQDS */ +#define VDD_MV_MIN 819 +#define VDD_MV_MAX 1212 /* * RapidIO -- cgit v1.2.3