summaryrefslogtreecommitdiff
path: root/arch
AgeCommit message (Collapse)Author
2016-09-18sunxi: Provide board_fit_config_name_match() hook functionPhilipp Tomsich
We assume that any (i.e. the first) FDT contained fits our board and simply return a positive match every time. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2016-09-18sunxi: Set probing order for SPL via board_boot_order() for sun9iPhilipp Tomsich
As SPL can probe multiple interfaces, we can let it do the work for FIT images and simply provide the board_boot_order hook. This mechanism is fully implemented for sun9i (i.e. A80) platforms and falls back to the old mechanism of determining a single boot device for older/other platforms for now. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2016-09-18sun9i: armadillo: set CLKB_OUT and reset USB hubsKlaus Goger
set CLKB_OUT to 12MHz output and reset the onboard USB, HSIC hub and GL830 USB to SATA bridge.
2016-09-18ARM: sunxi: add support for the A80-Q7 modulePhilipp Tomsich
This adds a DTS and a defconfig for the A80-Q7 (a system-on-module compatible with the Qseven form-factor developed and supported by Theobroma Systems).
2016-09-18ARM: sun9i: SPI support for sun9iPhilipp Tomsich
2016-09-18sun9i: improved clock setup for better boot reliabilityPhilipp Tomsich
2016-09-18sun9i: Adjust clock-setup to match what Allwinner used in U-BootPhilipp Tomsich
Our initial clock setup had been based on the basic_bootloader (boot0), but differed from what Allwinner used in their SDK in 'u-boot-2011.09'. To improve compatibility, we now switch to the same clocking they have used. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2016-09-18sunxi: Support chip-id reading on sun9i (A80)Philipp Tomsich
The chip-id on the sun9i resides in the SID block, but at an offset from what we'd expect with older variants.
2016-09-18sunxi: Add support for the AXP806 on sun9iPhilipp Tomsich
On A80 boards, both a AXP809 (primary) and AXP806 (secondary) PMIC are found. The AXP806 supplies the Cortex-A15 cores with a poly-phase supply to deliver up to 10A of total power. When used in the slave configuration, the AXP806 needs a write to the REGADDR_EXT register to configure it to work on the same RSB bus as the primary PMIC.
2016-09-18sunxi: support the AXP809 PMIC (for A80 platforms)Philipp Tomsich
Implement support for the AXP809 PMIC that is used on A80 platforms as the primary PMIC and powers most peripherals and the CPUA (Cortex-A7) cluster. A AXP806 is usually the slave PMIC, which will provide the power for the CPUB (Cortex-A15) cluster. The default voltage settings have been chosen to be safe values for a Optimus, Cubieboard and A80-Q7. These changes are validated against the A80-Q7 module.
2016-09-18sunxi: enable SPL for sun9iPhilipp Tomsich
2016-09-18sunxi: add initial clock setup for sun9i for SPLPhilipp Tomsich
2016-09-18sunxi: issue a MMC hardware reset on core_initPhilipp Tomsich
2016-09-18sunxi: Support GbE controller (GMAC) for sun9i (A80)Philipp Tomsich
* board/sunxi/gmac.c(eth_init_board): Add support for configuring sun9i (A80) for Ethernet support in RGMII mode. * arch/arm/include/asm/arch-sunxi/gpio.h (SUN9I_GPA_GMAC): Define. * arch/arm/include/asm/arch-sunxi/clock_sun9i.h: Add Ethernet support for sun9i (A80), defining struct sunxi_sysctl_reg (which contains the GMAC clock control on sun9i) and AHB_{GATE,RESET}_OFFSET_GMAC * arch/arm/include/asm/arch-sunxi/cpu_sun9i.h(SUNXI_SYSCTL_BASE): Define. * arch/arm/dts/sun9i-a80.dtsi: add device-tree support for GMAC on sun9i (A80).
2016-09-18sunxi: Support UART4 on A80 (sun9i) as system consolePhilipp Tomsich
* arch/arm/cpu/armv7/sunxi/board.c (gpio_init): Configure UART4 pins and function for CONFIG_CONS_INDEX == 5 (UART4) on CONFIG_MACH_SUN9I * include/configs/sunxi-common.h: Define CONFIG_SYS_NS16550_COM5 and CONFIG_SYS_NS16550_COM6 for CONFIG_MACH_SUN9I to refer to UART4 and UART5, respectively. Define OF_STDOUT_PATH for CONFIG_CONS_INDEX == 5 (UART4) on CONFIG_MACH_SUN9I * arch/arm/include/asm/arch-sunxi/gpio.h (SUN9I_GPG_UART4): Define. Validated against A80-Q7 module.
2016-09-18sunxi: Enable SMP mode for sun9i (A80)Philipp Tomsich
2016-09-18sunxi: add gtbus-initialisation for sun9iPhilipp Tomsich
On sun9i, the GTBUS manages transaction priority and bandwidth for multiple read ports when accessing DRAM. The initialisation mirrors the settings from Allwinner's boot0 for now, even though this may not be optimal for all applications (e.g. headless systems might want to give priority to IO modules). Adding a common callout to gtbus_init() from the SPL clock init with a weakly defined implementation in sunxi/clock.c to fallback to for platforms that don't require this.
2016-09-18sunxi: DRAM initialisation for sun9iPhilipp Tomsich
This adds DRAM initialisation code for sun9i, which calculates the appropriate timings based on timing information for the supplied DDR3 bin and the clock speeds used. With this DRAM setup, we have verified DDR3 clocks of up to 792MHz (i.e. DDR3-1600) on the A80-Q7 using a dual-channel configuration.
2016-09-18arm: mvebu: theadorable: Add StratixV FPGA programming supportStefan Roese
This patch adds support for Altera StratixV bitstream programming. 2 FPGAs are connected to the SPI busses. This patch uses board specific write code to program the bitstream via SPI direct write mode. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Luka Perkov <luka.perkov@sartura.hr> Signed-off-by: Stefan Roese <sr@denx.de>
2016-09-18arm: mvebu: spi.h: Add registers for direct write accessStefan Roese
The direct write config register is needed for SPI direct write mode configuration. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Luka Perkov <luka.perkov@sartura.hr> Signed-off-by: Stefan Roese <sr@denx.de>
2016-09-18arm: mvebu: Add some SPI CS attributesStefan Roese
These attribute defines may be used to map an area of memory for direct access to the specific SPI devices. See SPI Direct Access Mode for further information. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Luka Perkov <luka.perkov@sartura.hr> Signed-off-by: Stefan Roese <sr@denx.de>
2016-09-18sunxi: A83T: fix 32bit overflow warningvishnupatekar
In mctl_channel_init, (0x50<<26) which overflows 32bit. It was supposed to be 0x50<<16,corrected now. Reported-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Vishnu Patekar <vishnupatekar0510@gmail.com> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2016-09-18sunxi: Select CONFIG_OF_BOARD_SETUP from arch/arm/KconfigHans de Goede
Always select OF_BOARD_SETUP on sunxi, rather then having it in almost all our defconfigs. This also fixes it missing from some recently added defconfigs. This commit also modifies our ft_board_setup() to not cause warnings when CONFIG_VIDEO_DT_SIMPLEFB is not set, since we will now always build it. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Fix gmac not working due to cpu_eth_init no longer being calledHans de Goede
cpu_eth_init is no longer called for dm enabled eth drivers, this was causing the sunxi gmac eth controller to no longer work in u-boot. This commit fixes this by calling the clock, reset and pinmux setup function from s_init() and enabling the phy power pin (if any) from board_init(). The enabling of phy power cannot be done from s_init because it uses dm and dm is not ready yet at this point. Note that the mdelay is dropped as the phy gets enabled much earlier now, so it is no longer needed. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk> Tested-by: Karsten Merker <merker@debian.org> Tested-by: Michael Haas <haas@computerlinguist.org>
2016-09-18sunxi: Add support for USB vbus pin for USB3Hans de Goede
The H3 has USB0 - USB3, add support for having a USB vbus pin for USB3. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Support SID e-fuses on A83T and H3Chen-Yu Tsai
On the A83T and H3, the SID block is at a different address. Furthurmore, the e-fuses are at an offset of 0x200 within the hardware's address space. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2016-09-18sunxi: Add defconfig and dts for Orange Pi 2 SBCHans de Goede
The Orange Pi 2 is a SBC based on the Allwinner H3 SoC with a uSD slot, 4 USB ports connected via a USB-2 hub, a 10/100M ethernet port using the SoC's integrated PHY, Wifi via a RTL8189ETV sdio wifi chip, USB OTG, HDMI, a TRRS headphone jack for stereo out and composite out, a microphone, an IR receiver, a CSI connector, 2 LEDs, a 3 pin UART header and a 40-pin GPIO header. The added dts file is identical to the one submitted to the upstream kernel. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Add defconfig and dts for Dserve DSRV9703C tabletHans de Goede
The Dserve DSRV9703C is a 9.7" A10 tablet with a 1024x768 ips LCD, 1G RAM, 4GB flash, a Focaltech FT5406EE8 touchscreen and rtl8188ctv wifi. The dts file is identical to the one submitted to the upstream kernel. Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2016-09-18sunxi: Add defconfig and dts for the Polaroid MID2809PXE4 tabletHans de Goede
The Polaroid MID2809PXE4 is a 9" tablet which is clearly marked Polaroid MID2809PXE4 on the back. It features a 9" 16:9 800x480 LCD, A23 Soc, 1GB RAM, 8GB NAND, gsl3670 touchscreen and esp8089 wifi. The dts file is identical to the one submitted to the upstream kernel. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Add defconfig and dts for Difrence DIT4350 tabletHans de Goede
The Difrnce dit4350 tablet is a tiny tablet with a 4.3" 16:9 480x272 LCD, A13 SoC, 512M RAM, 4G NAND, solomon systech ssd2532qn6 touchscreen at i2c1 address 0x48, Memsic MXC622X accelerometer at i2c1 address 0x15 and rtl8188etv wifi. The dts file is identical to the one submitted to the upstream kernel. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Add defconfig and dts for colorfly e708 q1 tabletHans de Goede
The colorfly e708 q1 is a 7" tablet which is clearly marked as colorfly e708 q1 on the back. It features a 9:16 800x1280 IPS LCD, A31s SoC, 1GB RAM, 8G NAND, ilitek 2139qt004 touchscreen on i2c-1 addr 0x41, stk8313 accelerometer on i2c-2 addr 0x22 and a rtl8188etv wifi chip. The added dts is identical to the dts submitted to the upstream kernel, note this commit also syncs axp22x.dtsi and sun6i-a31.dtsi with the upstream kernel as the added dts depends on these. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Fix clock_twi_onoff for sun9iHans de Goede
Fix a copy and paste error which caused us to use the uart rather then the twi reset bits in clock_twi_onoff for sun9i. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Fix clock_twi_onoff for sun8i-a83Hans de Goede
clock_sun8i_a83.c did not contain a clock_twi_onoff implementation at all, this is fixed by moving the clock_sun6i.c implementation, which is correct for the a83 too, to a shared location. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Fix clock_twi_onoff for sun6iHans de Goede
The clock_sun6i.c implementation was not deasserting the reset for the regular i2c controllers, this commit fixes this. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: Sync dts files with the upstream kernelHans de Goede
Sync dts files with the upstream kernel including changes queued for 4.6: https://git.kernel.org/cgit/linux/kernel/git/mripard/linux.git/commit/?h=sunxi/dt-for-4.6 Note this adds a number of new unused board dts files. I've asked the authors of the kernel commits adding these to submit a matching defconfig to u-boot. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-09-18sunxi: A23: Fix some revisions needing a different magic sram pokeHans de Goede
I've had this one a23 tablet which would not boot and I've finally figured out what the problem is by looking at the released boot0 code, it seems the magic sram controller poke which we need to do in s_init() depends on the revision of the a23. Specifically this change is needed to get the A23 SoC I have with the following serial to boot: "E6071AB 26Y7". Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
2016-03-24ARM: uniphier: add NOR boot supportMasahiro Yamada
This allows to boot from NOR flash (or SRAM) with help of an external loader (NOR-loader). Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: support Debug UARTMasahiro Yamada
For ARM32 architecture, CONFIG_DEBUG_LL is available for early low-level debugging (and actually UniPhier 32bit SoCs use it), but ARM64 architecture does not support it. Instead, CONFIG_DEBUG_UART is available as an architecture-independent debug facility. This commit supports it on all the UniPhier SoCs (including the new ARMv8 SoCs), which is very useful for new SoC bringups. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: add System Control register macros for ARMv8 SoCsMasahiro Yamada
The System Control block moved to a completely different register map for ARMv8 SoCs, so it cannot be shared with the ARM 32-bit ones. Define register macros in a new header file. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: add sg_set_iectrl() functionMasahiro Yamada
This helper function would be useful for new SoCs with per-pin input enable controlling, such as PH1-LD20, PH1-LD11, etc. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: dts: uniphier: add PH1-LD11 SoC/board device tree sourcesMasahiro Yamada
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: dts: uniphier: add PH1-LD20 SoC/board device tree sourcesMasahiro Yamada
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: enable DDR PHY parameter dump commands by defaultMasahiro Yamada
These commands are not necessarily needed for usual operations (they are useful in case of DDR memory trouble), but enabling them by default would be nice in terms of the compilation test coverage. They are small enough, so limited impact on the memory footprint. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: add work-around to support Micro Support Card v3.6.10Masahiro Yamada
Due to some hardware guy's awful work, this version is not compatible with v3.6: the logic of BIT(0) of the reset logic is inverted! (and v3.6.10 is horribly wrong in multiple ways), but this is what we have to solve now. The v3.6 expects 0x0000 set to the register for reset de-assertion, while v3.6 does 0x0001. This commit (ab)uses another bug of v3.6.10 to work around the issue. The UniPhier System Bus is a 16-bit bus, which this support card is connected to. A 32-bit write to the bus (writel() function call) is divided into two 16-bit write transactions, with LSB the first. What is amazing for v3.6.10 is that access to address 4N + 2 goes to 4N (Jesus Christ!). For clarification, things are like this: writel(0x00010000, MICRO_SUPPORT_CARD_RESET); is done with two bus transactions as follows [1] write 0x0000 to address MICRO_SUPPORT_CARD [2] write 0x0001 to address MICRO_SUPPORT_CARD + 2 For v3.6, [1] is written to the register and [2] is correctly ignored because there is nothing at the address MICRO_SUPPORT_CARD + 2. This is what we expect. For v3.6.10, [1] is written to the reset register and then [2] is over-written to the same register due to the bus access bug. For the latter, it produces a glitch signal to the BIT[0], so the device state is lost due to the reset pulse. This solution only works for the start-up code. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: drop ifdef in ddrphy-regs.hMasahiro Yamada
The ifdef conditionals in header files prevent us from multi-SoC support in a single U-Boot image. Detect SoC specific parameters run-time rather than define them statically with an ifdef in ddrphy-regs.h. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: refactor SBC init codeMasahiro Yamada
There is a bunch of duplication in the System Bus Controller init code. Roughly, there are two types in the SBC mode: Adress/Data Multiplex Mode and Save Pins Mode. Consolidate per-SoC functions into the two, plus per-SoC optional init code. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: uniphier: drop PH1- prefix from CONFIG options and file namesMasahiro Yamada
The current CONFIG names like "CONFIG_ARCH_UNIPHIER_PH1_PRO4" is too long. It would not hurt to drop "PH1_" because "UNIPHIER_" already well specifies the SoC family. Also, rename files for consistency. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-24ARM: dts: uniphier: add device tree for Micro Support CardMasahiro Yamada
Import uniphier-support-card.dtsi from Linux Kernel and make it available on the UniPhier reference boards. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2016-03-22Fix spelling of "transferred".Vagrant Cascadian
Signed-off-by: Vagrant Cascadian <vagrant@debian.org> Acked-by: Marek Vasut <marex@denx.de> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2016-03-22sandbox: Avoid calling commands when not availableSimon Glass
Don't try to run commands when not supported. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>