1 /* SPDX-License-Identifier: GPL-2.0+ */ 2 /* 3 * (C) Copyright 2009 4 * Stefano Babic, DENX Software Engineering, sbabic@denx.de. 5 */ 6 7 #ifndef __SYS_PROTO_IMX6_ 8 #define __SYS_PROTO_IMX6_ 9 10 #include <asm/mach-imx/sys_proto.h> 11 #include <asm/arch/iomux.h> 12 13 #define USBPHY_PWD 0x00000000 14 15 #define USBPHY_PWD_RXPWDRX (1 << 20) /* receiver block power down */ 16 17 #define is_usbotg_phy_active(void) (!(readl(USB_PHY0_BASE_ADDR + USBPHY_PWD) & \ 18 USBPHY_PWD_RXPWDRX)) 19 20 int imx6_pcie_toggle_power(void); 21 int imx6_pcie_toggle_reset(void); 22 23 enum ldo_reg { 24 LDO_ARM, 25 LDO_SOC, 26 LDO_PU, 27 }; 28 29 int set_ldo_voltage(enum ldo_reg ldo, u32 mv); 30 31 /** 32 * iomuxc_set_rgmii_io_voltage - set voltage level of RGMII/USB pins 33 * 34 * @param io_vol - the voltage IO level of pins 35 */ iomuxc_set_rgmii_io_voltage(int io_vol)36static inline void iomuxc_set_rgmii_io_voltage(int io_vol) 37 { 38 __raw_writel(io_vol, IOMUXC_SW_PAD_CTL_GRP_DDR_TYPE_RGMII); 39 } 40 41 #endif /* __SYS_PROTO_IMX6_ */ 42