summaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
2017-07-31configs: Migrate CMD_NAND*Tom Rini
Migrate all remaining instances of CMD_NAND, CMD_NAND_TRIMFFS CMD_NAND_LOCK_UNLOCK and CMD_NAND_TORTURE from the headers into the defconfig files. Tested-by: Adam Ford <aford173@gmail.com> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
2017-07-31dm: console: Check for serial devices properlySimon Glass
With driver model the serial device is often not called "serial". Mark driver-model stdio devices so that they can be detected and we can look up the uclass. This is a more reliable way of finding out whether the console is connected to a serial device or not. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-07-31env: Migrate CONFIG_ENV_IS_IN_FAT options to KconfigTom Rini
We rename the various FAT_ENV_xxx options to CONFIG_ENV_FAT_xxx so that they can be modified via Kconfig. Migrate all existing users to the new values. Signed-off-by: Tom Rini <trini@konsulko.com>
2017-07-31Remove unused CONFIG_TWL4030_PWMAdam Ford
CONFIG_TWL4030_PWM is not being used by any source, so let's remove the #define and the whitelist entry Signed-off-by: Adam Ford <aford173@gmail.com> Reviewed-by: Tom Rini <trini@konsulko.com>
2017-07-31serial: stm32x7: Convert CONFIG_STM32X7_SERIAL to KconfigPatrice Chotard
Add CONFIG_STM32X7_SERIAL as a Kconfig option. Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Reviewed-by: Vikas Manocha <vikas.manocha@st.com>
2017-07-31Merge tag 'signed-efi-next' of git://github.com/agraf/u-bootTom Rini
Patch queue for efi - 2017-07-29 A lot of EFI greatness this time around. Thanks a lot to the two amazing new contributors Heinrich Schuchardt and Rob Clark we now gain - stable objects across multiple bootefi invocations - fixes for shim - fixes for ipxe - protocol installation - device path conversion to/from text - working "lsefi" support in grub - working notifiers - various bug fixes
2017-07-30x86: minnowmax: Remove CONFIG_SMSC_LPC47MBin Meng
There is no SMSC LPC47M Super I/O chipset on the MinnowMax board. Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
2017-07-30x86: Add Intel Edison board filesAndy Shevchenko
Add Intel Edison board which is using U-Boot. The patch is based on work done by the following people (in alphabetical order): Aiden Park <aiden.park@intel.com> Dukjoon Jeon <dukjoon.jeon@intel.com> eric.park <eric.park@intel.com> Fabien Chereau <fabien.chereau@intel.com> Felipe Balbi <felipe.balbi@linux.intel.com> Scott D Phillips <scott.d.phillips@intel.com> Sebastien Colleur <sebastienx.colleur@intel.com> Steve Sakoman <steve.sakoman@intel.com> Vincent Tinelli <vincent.tinelli@intel.com> In case we're building for Intel Edison, we must have 4096 bytes of zeroes in the beginning on u-boot.bin. This is done in board/intel/edison/config.mk. First run sets hardware_id environment variable which is read from System Controller Unit (SCU). Serial number (serial# environment variable) is generated based on eMMC CID. MAC address on USB network interface is unique to the board but kept the same all over the time. Set mac address from U-Boot using following scheme: OUI = 02:00:86 next 3 bytes of MAC address set from eMMC serial number This allows to have a unique mac address across reboot and flashing. Signed-off-by: Vincent Tinelli <vincent.tinelli@intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> [bmeng: Add MAINTAINERS file for Intel Edison board] Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
2017-07-29Merge git://git.denx.de/u-boot-socfpgaTom Rini
2017-07-29Merge git://git.denx.de/u-boot-usbTom Rini
2017-07-28efi_loader: indent entry/exit prints to show nesting levelRob Clark
This should make it easier to see when a callback back to UEFI world calls back in to the u-boot world, and generally match up EFI_ENTRY() and EFI_EXIT() calls. Signed-off-by: Rob Clark <robdclark@gmail.com> [agraf: remove static from const var] Signed-off-by: Alexander Graf <agraf@suse.de>
2017-07-28efi_loader: add checking for incorrect use of EFI_ENTRY/EXITRob Clark
Missing an EFI_ENTRY() or doubling up EFI_EXIT() leads to non-obvious crashes. Let's add some error checking. Signed-off-by: Rob Clark <robdclark@gmail.com> [agraf: fix bogus assert() and fix app_gd breakage] Signed-off-by: Alexander Graf <agraf@suse.de>
2017-07-28clk: fix compilation errors for poplar platformPatrice Chotard
Move clk_release_all() prototype and definition inside OF_CONTROL flag to avoid following compilation error for poplar platform: aarch64: + poplar +drivers/usb/host/built-in.o: In function `ehci_usb_remove': +drivers/usb/host/ehci-generic.c:159: undefined reference to `clk_release_all' +drivers/usb/host/built-in.o: In function `ehci_usb_probe': +drivers/usb/host/ehci-generic.c:133: undefined reference to `clk_release_all' +make[1]: *** [u-boot] Error 139 +make: *** [sub-make] Error 2 Introduced by 4e542c4 clk: add clk_release_all() Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
2017-07-28dm: phy: add missing #ifdef CONFIG_PHYPatrice Chotard
To avoid compilation breakage on platform that doesn't support DM PHY but uses xhci-dwc3 driver, add the missing CONFIG_PHY flag. Introduced by patch : 84e53877 "usb: host: xhci-dwc3: Add generic PHY support" Cc: Ran Wang <ran.wang_1@nxp.com> Cc: Bin Meng <bmeng.cn@gmail.com> Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Reported-by: Ran Wang <ran.wang_1@nxp.com>
2017-07-28dfu: remove limitation on partition sizePatrick Delaunay
Change long (32 bits on arm) to u64 (same type than offset) for size and read offset r_left So partition and device used for DFU can be greater than 4GB Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
2017-07-28dfu: allow dfu read on partition greater than 2GBPatrick Delaunay
solve issue on get_medium_size() function the detection of error is a simple test < 0 but for ARM platform, long is 32bits and 2GB = 0x80000000 is seen as error. I solve the issue by changing the prototype fo the function to separate size and result. This patch prepare the next patch with size change to u64. Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
2017-07-28dm: usb: Add a new USB controller operation 'update_hub_device'Bin Meng
For USB host controllers like xHC, its internal representation of hub needs to be updated after the hub descriptor is fetched. This adds a new op that does this. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28usb: hub: Parse and save TT details from device descriptorBin Meng
A high speed hub has a special responsibility to handle full speed/ low speed devices connected on downstream ports. In this case, the hub must isolate the high speed signaling environment from the full speed/low speed signaling environment with the help of Transaction Translator (TT). TT details are provided by hub descriptors and we parse and save it to hub uclass_priv for later use. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28usb: hub: Support 'set hub depth' request for USB 3.0 hubsBin Meng
USB 3.0 hub uses a hub depth value multiplied by four as an offset into the 'route string' to locate the bits it uses to determine the downstream port number. We shall set the hub depth value of a USB 3.0 hub after it is configured. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28usb: hub: Add a new API to test if a hub device is root hubBin Meng
Sometimes we need know if a given hub device is root hub or not. Add a new API to test this. This removes the xHCI driver's own version is_root_hub() and change to use the new API. While we are here, remove the unused/commented out get_usb_device() in the xHCI driver too. Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
2017-07-28usb: hub: Remove hub_port_reset()Bin Meng
At present hub_port_reset() is defined in DM USB, but it is never called hence remove it (removing another ifdefs). While we are here, change legacy_hub_port_reset() name to usb_hub_port_reset() to better match other function names in the same hub module. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28x86: minnowmax: Add a environment variable for USB power-on delayBin Meng
Occasionally it was observed that on Intel MinnowMax board, with a USB 2.0 device connected to the bottom port, when doing 'usb start' on the xHCI controller: scanning bus 0 for devices... cannot reset port 3!? But neither of the two USB ports is routed to xHCI root port 3. Adding some debug information shows that xHCI port 3 PORTSC register mysteriously reports both CCS = 1 and CSC = 1. This is not seen every time. After increasing the timeout to wait for power to become stable, the issue is gone. So this indicates current default USB power-on delay (20ms) might be at a critical region where power is stable/unstable. U-Boot provides a mechanism to have a environment variable to override the default one. Add one for MinnowMax. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stefan Roese <sr@denx.de> Tested-by: Stefan Roese <sr@denx.de>
2017-07-28configs: Remove CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS in all boardsBin Meng
Now that EHCD does not use CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS, remove it in all boards' config files. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stefan Roese <sr@denx.de> Tested-by: Stefan Roese <sr@denx.de>
2017-07-28configs: Remove CONFIG_SYS_USB_XHCI_MAX_ROOT_PORTS in all boardsBin Meng
Now that xHCD does not use CONFIG_SYS_USB_XHCI_MAX_ROOT_PORTS, remove it in all boards' config files. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stefan Roese <sr@denx.de> Tested-by: Stefan Roese <sr@denx.de>
2017-07-28usb: hub: Add 3.0 hub port status mask of 2.0 hubBin Meng
USB 3.0 hub port status has different bit position regarding to port power, port speed, etc. But others are the same as 2.0 hubs. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stefan Roese <sr@denx.de> Tested-by: Stefan Roese <sr@denx.de>
2017-07-28usb: hub: Change USB hub descriptor to match USB 3.0 hubsBin Meng
USB 3.0 hubs have a slightly different hub descriptor than USB 2.0 hubs, with a fixed (rather than variable length) size. Change the host controller drivers that access those last two fields (DeviceRemovable and PortPowerCtrlMask) to use the union. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stefan Roese <sr@denx.de> Tested-by: Stefan Roese <sr@denx.de>
2017-07-28usb: hub: Send correct wValue to get hub descriptor of a USB 3.0 hubBin Meng
Testing a USB 3.0 hub by connecting it to the xHCI port on Intel MinnowMax, when issuing 'get hub descriptor' to the hub, xHCI reports a transfer event TRB with a completion code 6 which means 'Stall Error'. In fact super speed USB hub descriptor type is 0x2a, not 0x29. Sending correct SETUP packet to the hub makes it not stall anymore. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stefan Roese <sr@denx.de> Tested-by: Stefan Roese <sr@denx.de>
2017-07-28dm: core: add ofnode_count_phandle_with_args()Patrice Chotard
This function is usefull to get phandle number contained in a property list. For example, this allows to allocate the right amount of memory to keep clock's reference contained into the "clocks" property. To implement it, either of_count_phandle_with_args() or fdtdec_parse_phandle_with_args() are used respectively for live tree and flat tree. By passing index = -1, these 2 functions returns the number of phandle contained into the property list. Add also the dev_count_phandle_with_args() based on ofnode_count_phandle_with_args() Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28clk: add clk_release_all()Patrice Chotard
Add clk_release_all() method which Disable/Free an array of clocks that has been previously requested by clk_request/get_by_*() Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28reset: add reset_release_all()Patrice Chotard
Add reset_release_all() method which Assert/Free an array of resets signal that has been previously successfully requested by reset_get_by_*() Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28reset: add reset_request()Patrice Chotard
This is needed in error path to assert previously deasserted reset by using a saved reset_ctl reference. Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28drivers: phy: add generic_phy_valid() methodPatrice Chotard
This allow to check if a PHY has been correctly initialised and avoid to get access to phy struct. Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
2017-07-28fdtdec: Drop old compatible valuesSimon Glass
These are not needed now since the drivers now use driver model. Drop them. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Tested-on: Beaver, Jetson-TK1 Tested-by: Stephen Warren <swarren@nvidia.com>
2017-07-28dm: power: Convert as3722 to driver modelSimon Glass
Convert this PMIC driver to driver model and fix up other users. The regulator and GPIO functions are now handled by separate drivers. Update nyan-big to work correct. Three boards will need to be updated by the maintainers: apalis-tk1, cei-tk1-som. Also the TODO in the code re as3722_sd_set_voltage() needs to be completed. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Lukasz Majewski <lukma@denx.de> Tested-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Tested-on: Jetson-TK1 Tested-by: Stephen Warren <swarren@nvidia.com>
2017-07-28power: Add a GPIO driver for the as3722 PMICSimon Glass
This pmic includes GPIOs which should have their own driver. Add a driver to support these. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Lukasz Majewski <lukma@denx.de> Tested-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Tested-on: Beaver, Jetson-TK1 Tested-by: Stephen Warren <swarren@nvidia.com>
2017-07-28power: Add a regulator driver for the as3722 PMICSimon Glass
This pmic includes regulators which should have their own driver. Add a driver to support these. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Lukasz Majewski <lukma@denx.de> Tested-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Tested-on: Beaver, Jetson-TK1 Tested-by: Stephen Warren <swarren@nvidia.com>
2017-07-28dm: core: Add ofnode_read_resource()Simon Glass
We sometimes need to read a resource from an arbitrary node. In any case for consistency we should not put the live-tree switching code in a dev_read_...() function. Update this to suit. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Tested-on: Beaver, Jetson-TK1 Tested-by: Stephen Warren <swarren@nvidia.com>
2017-07-28sandbox: remove os_putc() and os_puts()Masahiro Yamada
They are unused since commit d8c6fb8cedbc ("sandbox: Drop special case console code for sandbox"). Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-07-28dm: ofnode: change return type of dev_read_prop() to opaque pointerMasahiro Yamada
DT property values can be strings as well as integers. This is why of_get_property/fdt_getprop returns an opaque pointer. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-07-28dm: Fix typo in include-guard for dm-structs.hPhilipp Tomsich
The include-guard for dm-structs.h was misspelled as __DT_STTUCTS. Change it. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-07-28efi_loader: Add an EFI_CALL() macroRob Clark
Rather than open-coding EFI_EXIT() + callback + EFI_ENTRY(), introduce an EFI_CALL() macro. This makes callbacks into UEFI world (of which there will be more in the future) more concise and easier to locate in the code. Signed-off-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2017-07-28efi_loader: only evaluate EFI_EXIT()'s ret onceRob Clark
There are a couple spots doing things like: return EFI_EXIT(some_fxn(...)); which I handn't noticed before. With addition of printing return value in the EFI_EXIT() macro, now the fxn call was getting evaluated twice. Which we didn't really want. Signed-off-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2017-07-27spl: make SPL and normal u-boot stage use independent SYS_MALLOC_F_LENAndy Yan
Some platforms have very limited SRAM to run SPL code, so there may not be the same amount space for a malloc pool before relocation in the SPL stage as the normal U-Boot stage. Make SPL and (the full) U-Boot stage use independent SYS_MALLOC_F_LEN, so the size of pre-relocation malloc pool can be configured memory space independently. Signed-off-by: Andy Yan <andy.yan@rock-chips.com> Reviewed-by: Tom Rini <trini@konsulko.com> Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> [fixed up commit-message:] Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-07-27rockchip: firefly: Add "usb start" to auto-start USB deviceLeo Wen
Add "preboot=usb start" to ROCKCHIP_DEVICE_SETTINGS,you don't need to input "usb start" in command line of u-boot console,it can auto-start the USB device,after that usb keyboard can work. Signed-off-by: Leo Wen <leo.wen@rock-chips.com> Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-07-27rockchip: firefly: Set the environment variable 'usbkbd' to the stdinLeo Wen
Add the 'usbkbd' environment variable to the 'stdin', the contents of the keyboard input can be auto-displayed on the serial terminal,so you don't need to manually set the environment variable 'stdin'. Signed-off-by: Leo Wen <leo.wen@rock-chips.com> Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-07-27rockchip: rk3399: enable SPL_SERIAL_SUPPORT and SPL_DRIVERS_MISC_SUPPORT via ↵Philipp Tomsich
Kconfig SPL_SERIAL_SUPPORT and SPL_DRIVERS_MISC_SUPPORT were previously enabled through rk3399_common.h. This change implies these options through Kconfig. These need to always be active for the RK3399, as follows: - SPL_SERIAL_SUPPORT is needed to pass the SPL build - SPL_DRIVERS_MISC_SUPPORT is needed to pass the SPL build Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-07-27rockchip: use UUID for root partitionsKever Yang
We use to use /dev/mmcbl0p7 as root partition, and pass it to kernel by cmdline, but the mmc number in kernel in not fixed, we need to change the bootargs to adapt it from time to time. We can use the UUID to fix it, the ID is from: https://www.freedesktop.org/wiki/Specifications/DiscoverablePartitionsSpec/ ARM 32bit: 69dad710-2ce4-4e3c-b16c-21a1d49abed3 ARM 64bit: b921b045-1df0-41c3-af44-4c6f280d3fae Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-07-26Merge git://git.denx.de/u-boot-uniphierTom Rini
2017-07-26serial: stm32x7: migrate serial struct to driverPatrice Chotard
This allow to remove include/dm/platform_data/serial_stm32x7.h which was included in the past by stm32x7 driver and by stm32f746-disco.c board file. Since patch 42bf5e7c27 "serial: stm32f7: add device tree support" this file is no more needed in board file. Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Acked-by: Vikas MANOCHA <vikas.manocha@st.com>
2017-07-26ARM: DTS: stm32: align DT clock declaration with kernelPatrice Chotard
Use the same clocks macro than the one used by kernel DT. Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Acked-by: Vikas MANOCHA <vikas.manocha@st.com>