summaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2017-05-10power: twl4030: Move CONFIG_TWL4030_POWER to KconfigAdam Ford
As requested, I added the CONFIG_TWL4030_POWER to Kconfig and made it the implied default when selecting OMAP34XX as a platform. Signed-off-by: Adam Ford <aford173@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-10power: twl4030: Add CONFIG_CMD_POWEROFF supportAdam Ford
With the addition of twl4030_power_off(), let's allow the 'poweroff' command to run this function when CONFIG_CMD_POWEROFF is enabled. Tested on a DM3730 with twl4030 PMIC. Signed-off-by: Adam Ford <aford173@gmail.com> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
2017-05-10ARM: OMAP: I2C: Support New read, write and probe functions for OMAP3Adam Ford
New i2c_read, i2c_write and i2c_probe functions, tested on OMAP4 (4430/60/70), OMAP5 (5430) and AM335X (3359) were added in 960187ffa125( "ARM: OMAP: I2C: New read, write and probe functions") but not tested on OMAP3. This patch will allow the updated drivers using device tree and DM_I2C to operate on OMAP3. Signed-off-by: Adam Ford <aford173@gmail.com> Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
2017-05-10omap_hsmmc: update struct hsmmc to accommodate omap3 from DTAdam Ford
This patch changes the way DM_MMC calculates offset to the base register of MMC. Previously this was through an #ifdef but that wasn't necessary for OMAP3. This patch will now add in the offset to the base address based on the .compatible flags. Signed-off-by: Adam Ford <aford173@gmail.com> V2: Remove ifdef completely and reference offset from the omap_hsmmc_ids table. V1: Change ifdef to ignore OMAP3 Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-10bcm2835_wdt: support for the BCM2835/2836 watchdogPaolo Pisati
Signed-off-by: Paolo Pisati <p.pisati@gmail.com>
2017-05-10dm: video: arm: rpi: Convert to use driver model for videoSimon Glass
Adjust the video driver to work with driver model and move over existing baords. There is no need to keep the old code. We can also drop setting of CONFIG_FB_ADDR since driver model doesn't have this problem. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-05-10video: arm: rpi: Move the video settings out of the driverSimon Glass
Add a function to set the video parameters to the msg handler and remove it from the video driver. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-05-10video: arm: rpi: Move the video query out of the driverSimon Glass
Add a function to get the video size to the msg handler and remove it from the video driver. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-05-10dm: mmc: rpi: Convert Raspberry Pi to driver model for MMCSimon Glass
Convert the bcm2835 SDHCI driver over to support CONFIG_DM_MMC and move all boards over. There is no need to keep the old code since there are no other users. Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Simon Glass <sjg@chromium.org>
2017-05-10net: smsc95xx: Correct free_pkt() implementationSimon Glass
On further review this returns the wrong packet length from the driver. It may not be noticed since protocols will take care of it. Fix it by subtracting the header length from the packet length returned. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-05-09Merge git://git.denx.de/u-boot-dmTom Rini
2017-05-09Merge git://www.denx.de/git/u-boot-marvellTom Rini
2017-05-09drivers: block: dwc_ahci: Implement a driver for Synopsys DWC sata deviceJean-Jacques Hiblot
Implement a sata driver for Synopsys DWC sata device based on U-boot driver model. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09drivers: phy: add PIPE3 phy driverJean-Jacques Hiblot
This phy is found on omap platforms with sata capabilities. Except for the part related to the DM and the PHY framework, the code is basically a copy paste from arch/arm/mach-omap2/pipe3-phy.c Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09dm: test: Add tests for the generic PHY uclassJean-Jacques Hiblot
Those tests check: - the ability for a phy-user to get a phy based on its name or its index - the ability of a phy device (provider) to manage multiple ports - the ability to perform operations on the phy (init,deinit,on,off) - the behavior of the uclass when optional operations are not implemented Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09drivers: phy: add generic PHY frameworkJean-Jacques Hiblot
The PHY framework provides a set of APIs to control a PHY. This API is derived from the linux version of the generic PHY framework. Currently the API supports init(), deinit(), power_on, power_off() and reset(). The framework provides a way to get a reference to a phy from the device-tree. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09serial: atmel_usart: Add clk supportWenyou Yang
Add the clock support. Note that the clock handling of the DBGU peripheral is different from the USART. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09serial: atmel_usart: Fix early debug not work in SPLWenyou Yang
Add the uart init function to be used on both probe and the early debug uart init. For the latter, the input clock should be from CONFIG_DEBUG_UART_CLOCK. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09clk: at91: Align the at91 pmc's compatiblesWenyou Yang
Align the at91 pmc's compatibles with kernel. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-05-09clk: at91: Align clk-master compatibles with kernelWenyou Yang
Add the compatible "atmel,at91rm9200-clk-master" to align with the kernel. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09clk: at91: Enhance the peripheral clockWenyou Yang
Enhance the peripheral clock to support both at9sam9x5's and at91rm9200's peripheral clock via the different compatibles. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-09net: macb: Align the compatibles with kernelWenyou Yang
Add the compatibles to align with the kernel. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2017-05-09net: macb: Add remove callbackWenyou Yang
To avoid the failure of mdio_register(), add the remove callback to unregister the mii_dev when removing the ethernet device. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com> Fixed up unused variable warning, e.g. for gurnard: Signed-off-by: Simon Glass <sjg@chromium.org>
2017-05-09Merge branch 'master' of git://git.denx.de/u-boot-i2cTom Rini
2017-05-09dm: Update Simple Watchdog uclassMaxim Sloyko
- Remove "probe" function from sandbox wdt driver - Fix include order Fixes: 0753bc2d30d7 ("dm: Simple Watchdog uclass") Signed-off-by: Maxim Sloyko <maxims@google.com> [trini: Create as the delta between v1 (applied) and v2 (should have applied)]. Signed-off-by: Tom Rini <trini@konsulko.com>
2017-05-09fix: nand: pxa3xx: Remove hardcode values from the driverKonstantin Porotchkin
Obtain NAND controller setup parameters from the device tree instead of using hardcoded values. Signed-off-by: Konstantin Porotchkin <kostap@marvell.com> Cc: Scott Wood <oss@buserror.net> Cc: Stefan Roese <sr@denx.de> Cc: Igal Liberman <igall@marvell.com> Cc: Nadav Haklai <nadavh@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de>
2017-05-09fix: phy: marvell: cp110: pcie: update analog parameters according to latest ETPIgal Liberman
Add PCIE analog parameters initialization values according to latest ETP. Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: phy: marvell: cp110: rename comphy_index to cp_indexIgal Liberman
No functional change. The variable name "comphy_index" is misleading, it represents cp index and not comphy index. Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: phy: marvell: cp110: sfi: update analog parameters according to latest ETPIgal Liberman
Add SFI analog parameters initialization values according to latest ETP. Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09phy: marvell: print comphy status even when it's disconnectedStefan Roese
since now the COMPHY can also be ignored, we must know the state of the COMPHY. we cannot assume anymore that a missing COMPHY is unconnected. Signed-off-by: Yehuda Yitschak <yehuday@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: phy: marvell: cp110: fix comphy lane 4 selection optionsStefan Roese
The comphy configuration is incorrect. Set the correct values for SGMII. In addition, remove xaui from the comment as it is not supported. Signed-off-by: Yoav Gvili <ygvili@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09phy: marvell: cp110: add 5G XFI modeIgal Liberman
This patch adds the option to configure a comphy to 5G XFI mode. In order to configure the comphy to 5G XFI, update the comphy node in the device-tree: phy2 { phy-type = <PHY_TYPE_SFI>; phy-speed = <PHY_SPEED_5_15625G>; }; Signed-off-by: Igal Liberman <igall@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: phy: marvell: cp110: update comphy selector optionStefan Roese
Align PHY selectors register with Armada-CP-110 functional SPEC update all relevant device trees with this change. Signed-off-by: Hanna Hawa <hannah@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: phy: marvell: cp110: sata: update analog parameters according to latest ETPIgal Liberman
Add SATA analog parameters initialization values according to latest ETP. Signed-off-by: Konstantin Porotchkin <kostap@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: phy: marvell: cp110: fix the KR/SFI line 4 selectorStefan Roese
This patch fixes the following: 1. KR/SFI on lane #4 mux selector is 0x2 and not 0x1 2. Comment typo Signed-off-by: Rabeeh Khoury <rabeeh@solid-run.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09phy: marvell: add IGNORE COMPHY typeStefan Roese
This type tells u-boot to preserve the COMPHY settings as is it is usefull in situations where the COMPHY was initialized by earlier firmware. Note that IGNORE is different from UNCONNECTED since setting UNCONNECTED type will disconnect the COMPHY in the COMPHY MUX which is a desired behaviour Signed-off-by: Yehuda Yitschak <yehuday@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09phy: marvell: cp110: update utmi phy connection typeStefan Roese
UTMI_PHY_TO_USB_HOST was used in USB3 UTMI dts node only, but there will be USB2 UTMI dts node for some SoCs that have got USB2 controller, so rename TO_USB_HOST to TO_USB3_HOST to distinguish TO_USB2_HOST in later on patches. Signed-off-by: zachary <zhangzg@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09phy: marvell: cp110: add support for end point configurationStefan Roese
The serdes was always configured in root complex mode. this patch add new entry in device tree (per serdes) which indicates whether the serdes is in end point mode. if so, it skips the root complex configuration. Signed-off-by: Haim Boot <hayim@marvell.com> Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09phy: marvell: Replace PHY_TYPE_KR with PHY_TYPE_SFIStefan Roese
Use correct naming as done in the latest Marvell U-Boot version as well. Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: Igal Liberman <igall@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: mvebu_ comphy: Update COMPHY sequence numberKonstantin Porotchkin
Use local static counter for maintaining the COMPHY chip-ID upon its initialization. The dev->seq originally used as the COMPHY chip-ID depends on the device tree scan order and produces wrong results that breaks the deficated PHYs init flow, which in turn breaks the USB support. Change-Id: I4e3f7ec36590a7f95dc94d9269a3c47fb708c4a9 Signed-off-by: Konstantin Porotchkin <kostap@marvell.com> Cc: Stefan Roese <sr@denx.de> Cc: Igal Liberman <igall@marvell.com> Cc: Stefan Chulski <stefanc@marvell.com> Cc: Nadav Haklai <nadavh@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09fix: mvebu: pcie_dw: Allow probing empty PCIe slotsKonstantin Porotchkin
This patch allows probing all PCIe nodes defined in DTS even if there no device connected to such node (no link). Without this fix the driver returns -ENODEV when the PCIe link is down. As result the pci_init function stops scanning bus on first empty PCIe slot and all devices located in higher numbered buses are not discovered. Signed-off-by: Konstantin Porotchkin <kostap@marvell.com> Cc: Stefan Roese <sr@denx.de> Cc: Igal Liberman <igall@marvell.com> Cc: Nadav Haklai <nadavh@marvell.com> Reviewed-by: Stefan Roese <sr@denx.de>
2017-05-09net: mvpp2: Add remove function that is called before the OS is startedStefan Roese
This patch adds a remove function to the mvpp2 ethernet driver which is called before the OS is started, doing: - Allocate the used buffers back from the buffer manager - Stop the BM activity Signed-off-by: Stefan Roese <sr@denx.de> Cc: Stefan Chulski <stefanc@marvell.com> Cc: Kostya Porotchkin <kostap@marvell.com> Cc: Nadav Haklai <nadavh@marvell.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2017-05-09drivers: i2c: davinci_i2c: Update davinci i2c driver to driver modelCooper Jr., Franklin
Convert davinci i2c driver to driver model. Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Heiko Schocher <hs@denx.de>
2017-05-09i2c: davinci: Split functions into two parts for future DM supportCooper Jr., Franklin
The i2c driver will be converted to support device model. In preparation for that change split the various functions into two parts. This will allow device model specific driver to reuse the majority of the code from the non device model implementation. Also rename the probe function to probe_chip to better reflect its purpose. Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Heiko Schocher <hs@denx.de>
2017-05-08Merge branch 'master' of git://git.denx.de/u-boot-sunxiTom Rini
2017-05-08aspeed: Refactor SCU to use consistent mask & shiftmaxims@google.com
Refactor SCU header to use consistent Mask & Shift values. Now, consistently, to read value from SCU register, mask needs to be applied before shift. Signed-off-by: Maxim Sloyko <maxims@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-08aspeed: Add support for Clocks needed by MACsmaxims@google.com
Add support for clocks needed by MACs to ast2500 clock driver. The clocks are D2-PLL, which is used by both MACs and PCLK_MAC1 and PCLK_MAC2 for MAC1 and MAC2 respectively. The rate of D2-PLL is hardcoded to 250MHz -- the value used in Aspeed SDK. It is not entirely clear from the datasheet how this clock is used by MACs, so not clear if the rate would ever need to be different. So, for now, hardcoding it is probably safer. The rate of PCLK_MAC{1,2} is chosen based on MAC speed selected through hardware strapping. So, the network driver would only need to enable these clocks, no need to configure the rate. Signed-off-by: Maxim Sloyko <maxims@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-08aspeed: Add I2C Drivermaxims@google.com
Add Device Model based I2C driver for ast2500/ast2400 SoCs. The driver is very limited, it only supports master mode and synchronous byte-by-byte reads/writes, no DMA or Pool Buffers. Signed-off-by: Maxim Sloyko <maxims@google.com> Reviewed-by: Simon Glass <sjg@chromium.org> Acked-by: Heiko Schocher <hs@denx.de>
2017-05-08aspeed: Add P-Bus clock in ast2500 clock drivermaxims@google.com
Add P-Bus Clock support to ast2500 clock driver. This is the clock used by I2C devices. Signed-off-by: Maxim Sloyko <maxims@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-08aspeed: AST2500 Pinctrl Drivermaxims@google.com
This driver uses Generic Pinctrl framework and is compatible with the Linux driver for ast2500: it uses the same device tree configuration. Not all pins are supported by the driver at the moment, so it actually compatible with ast2400. In general, however, there are differences that in the future would be easier to maintain separately. Signed-off-by: Maxim Sloyko <maxims@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>