summaryrefslogtreecommitdiff
path: root/arch
Commit message (Collapse)AuthorAgeLines
...
| * | arm: mvebu: Add SPI driver model supportStefan Roese2016-01-14-3/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch enables the DM support for the SPI driver and the SPI NOR flash chips. Some MVEBU boards boot from SPI NOR, so adding the aliases and enabling CONFIG_DM_SEQ_ALIAS is needed here. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Luka Perkov <luka.perkov@sartura.hr> Cc: Dirk Eibach <dirk.eibach@gdsys.cc> Cc: Simon Glass <sjg@chromium.org>
| * | arm: mvebu: Add DM and OF_CONTROL support to SPLStefan Roese2016-01-14-65/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds full DM support to the SPL on MVEBU. Currently only serial is supported. Other drivers will follow. This patch also adds the necessary config values for the DEBUG UART to the MVEBU defconfig files. This came in handy while implementing this DM support. Additionally, the mvebu specific SPL linker script is removed and this common one is used instead: arch/arm/cpu/u-boot-spl.lds This common linker script already handles all special cases. No need to reinvent the wheel for MVEBU here. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Luka Perkov <luka.perkov@sartura.hr> Cc: Dirk Eibach <dirk.eibach@gdsys.cc> Cc: Simon Glass <sjg@chromium.org>
| * | arm: mvebu/kirkwood: Use common timer functionsStefan Roese2016-01-14-124/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By using the common timer functions for mvebu/kirkwood we can get rid of quite a lot of code. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Luka Perkov <luka.perkov@sartura.hr> Cc: Simon Guinot <simon.guinot@sequanux.org> Cc: Valentin Longchamp <valentin.longchamp@keymile.com>
* | | arm: lpc32xx: switch SPL builds to driver modelVladimir Zapolskiy2016-01-13-19/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For NXP LPC32xx boards the change enables SPL_DM option, this allows to use any driver model UART driver in SPL images, hence a restriction on HSUART in SPL image is removed and well as definitions for non-DM NS16550 driver, its DM version is used instead. Because SPL_DM requires malloc(), enable CONFIG_SPL_SYS_MALLOC_SIMPLE for LPC32xx boards. The change adds about 5KB to the resulting SPL image (for devkit3250 board SPL image is increased from 10672 to 15608 bytes). Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* | | arm: lpc32xx: switch serial console to driver modelVladimir Zapolskiy2016-01-13-17/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On NXP LPC32xx platform for non-SPL builds the change adds standard (NS16550) and high-speed UARTs to driver model. Due to specific of DM NS16550 device description UART clock can not be got in runtime and by default it is set to 13MHz, if board PERIPH_CLK is different, this should be specified in board configuration file. For SPL builds HSUARTs are disabled and non-DM NS16550 driver is compiled, if needed. The change also updates default configs of devkit3250 and work_92105 boards to reflect updates in platform files. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* | | arm: move gd handling outside of C codeAlbert ARIBAUD2016-01-13-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As of gcc 5.2.1 for Thumb-1, it is not possible any more to assign gd from C code, as gd is mapped to r9, and r9 may now be saved in the prolog sequence, and restored in the epilog sequence, of any C functions. Therefore arch_setup_gd(), which is supposed to set r9, may actually have no effect, causing U-Boot to use a bad address to access GD. Fix this by never calling arch_setup_gd() for ARM, and instead setting r9 in arch/arm/lib/crt0.S, to the value returned by board_init_f_alloc_reserve(). Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net> Reviewed-by: Simon Glass <sjg@chromium.org>
* | | Fix board init code to respect the C runtime environmentAlbert ARIBAUD2016-01-13-19/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | board_init_f_mem() alters the C runtime environment's stack it is actually already using. This is not a valid behaviour within a C runtime environment. Split board_init_f_mem into C functions which do not alter their own stack and always behave properly with respect to their C runtime environment. Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net> Acked-by: Thomas Chou <thomas@wytron.com.tw>
* | | Merge branch 'master' of git://www.denx.de/git/u-boot-microblazeTom Rini2016-01-13-0/+1
|\ \ \ | |/ / |/| |
| * | arm: mvebu: Select SPL_DM_SEQ_ALIASNathan Rossi2016-01-13-0/+1
| |/ | | | | | | | | | | | | | | | | | | | | | | Select SPL_DM_SEQ_ALIAS which is required for certain uclasses, specifically SPI Flash. Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Reviewed-by: Stefan Roese <sr@denx.de> Cc: Albert Aribaud <albert.u.boot@aribaud.net> Cc: Stefan Roese <sr@denx.de> Acked-by: Stefan Roese <sr@denx.de> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* | arm: dts: am4372: add qspi register maps for memory mapMugunthan V N2016-01-13-1/+4
| | | | | | | | | | | | | | | | Add qspi memory map address to device tree. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagan Teki <jteki@openedev.com>
* | arm: dts: dra72-evm: add spi-flash comaptible for flashMugunthan V N2016-01-13-1/+1
| | | | | | | | | | | | | | | | | | In U-Boot most flashes uses "spi-flash" as compatible to bind the device to flash driver, so adding "spi-flash" compatible to m25p80 node. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> Reviewed-by: Jagan Teki <jteki@openedev.com>
* | arm: dts: dra7-evm: add spi-flash comaptible for flashMugunthan V N2016-01-13-1/+1
| | | | | | | | | | | | | | | | | | In U-Boot most flashes uses "spi-flash" as compatible to bind the device to flash driver, so adding "spi-flash" compatible to m25p80 node. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> Reviewed-by: Jagan Teki <jteki@openedev.com>
* | arm: dts: am437x-gp-evm: add spi-flash comaptible for flashMugunthan V N2016-01-13-1/+1
| | | | | | | | | | | | | | | | | | In U-Boot most flashes uses "spi-flash" as compatible to bind the device to flash driver, so adding "spi-flash" compatible to m25p80 node. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> Reviewed-by: Jagan Teki <jteki@openedev.com>
* | arm: dts: dra7: add qspi register maps for memory map and control moduleMugunthan V N2016-01-13-2/+5
| | | | | | | | | | | | | | | | Add qspi memory map and control module register maps to device tree. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagan Teki <jteki@openedev.com>
* | dts: dra7: add spi alias for qspiMugunthan V N2016-01-13-0/+1
| | | | | | | | | | | | | | | | | | add spi alias for qspi so that spi probes the device and driver successfully. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jagan Teki <jteki@openedev.com>
* | Merge git://git.denx.de/u-boot-dmTom Rini2016-01-12-97/+56
|\ \
| * | sandbox: eth-raw-os.c: Ensure that our interface name is not too longTom Rini2016-01-12-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Coverity notes that we do not ensure when we copy ifname we still have space left to ensure NULL termination. As cannot control the size of ifr_name we must make sure that our argument will not overflow the buffer. Reported-by: Coverity (CID 131094) Cc: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
| * | rockchip: Use the debug UART on rk3036Simon Glass2016-01-12-65/+8
| | | | | | | | | | | | | | | | | | | | | Rather than using a new debug UART implementation, use the standard one provided by U-Boot. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Thomas Chou <thomas@wytron.com.tw>
| * | dm: Convert PCI MMC over to use DM PCI APISimon Glass2016-01-12-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At present pci_mmc_init() does not correctly use the PCI function since the list it passes is not terminated. The array size passed to pci_mmc_init() is actually not used correctly. Fix this and adjust the pci_mmc_init() to scan all available MMC devices. Adjust this code to use the new driver model PCI API. This should move over to the new MMC uclass at some point. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
| * | dm: tegra: net: Convert tegra boards to driver model for EthernetSimon Glass2016-01-12-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Adjust all Tegra boards to use driver model for Ethernet, now that the required drivers are converted. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
| * | dm: x86: pci: Adjust bios_run_on_x86() to use the DM PCI APISimon Glass2016-01-12-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | This function should take a struct udevice rather than pci_dev_t. Update it. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
| * | dm: pci: video: Convert video and pci_rom to use DM PCI APISimon Glass2016-01-12-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adjust these files to use the driver-model PCI API instead of the legacy functions. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
| * | dm: Convert bios_interrupts to use DM PCI APISimon Glass2016-01-12-13/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | Adjust this code to use driver model for devices where possible. Since existing users have not been converted the old code must remain. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
| * | dm: x86: ivybridge: Convert graphics init to use DM PCI APISimon Glass2016-01-12-12/+12
| |/ | | | | | | | | | | | | | | | | Use the driver-model PCI functions here where possible. For now we have to search for the device with pci_bus_find_bdf() but at some point we can put this in a proper driver and avoid this. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
* | ARM: uniphier: add dump command for DDR Multi PHY registersMasahiro Yamada2016-01-13-0/+339
| | | | | | | | | | | | | | | | The ProXstream2/PH1-LD6b is integrated with a new IP for DDR PHY which is not register-compatible with the former SoCs. Add a new command to support the register dump of this IP. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* | ARM: uniphier: add DRAM init code for ProXstream2/PH1-LD6bMasahiro Yamada2016-01-13-0/+826
| | | | | | | | | | | | | | | | As mentioned in the log of commit 019df879a93e2 (ARM: uniphier: add ProXstream2 and PH1-LD6b support), the DRAM init code was missing for a long time. Finally, here it is. SPL works now. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* | ARM: uniphier: move headers out of include/mach directoryMasahiro Yamada2016-01-13-129/+188
| | | | | | | | | | | | | | These headers are only included locally in arch/arm/mach-uniphier/. There is no reason to export them by putting in the mach/ directory. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* | ARM: uniphier: move cmd_pinmon.c to boot-mode subdirectoryMasahiro Yamada2016-01-13-1/+2
| | | | | | | | | | | | | | This command shows the boot mode pins, so it would be more at home in the boot-mode subdirectory. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* | ARM: uniphier: move cmd_ddrphy.c to dram subdirectoryMasahiro Yamada2016-01-13-1/+2
| | | | | | | | | | | | | | This command shows the register dump of the DDR PHY, so it would be more at home in the dram subdirectory. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* | ARM: uniphier: kill bogus header includesMasahiro Yamada2016-01-13-15/+0
|/ | | | | | These includes are not necessary. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* am33xx/am43xx: Add platform data for GPIOsTom Rini2016-01-08-0/+23
| | | | | | | | | | | | | On these platforms we have many cases of boards that enable device model and GPIO support but do not enable OF_CONTROL and pass in a device tree with the binary. We need to bring in the platform data here as well. Tested on Beaglebone Black. Reported-by: Robert Nelson <robertcnelson@gmail.com> Reported-by: Francisco Aguerre <franciscoaguerre@gmail.com> Reported-by: Jason Kridner <jkridner@beagleboard.org> Signed-off-by: Tom Rini <trini@konsulko.com>
* powerpc: Various typo fixes under arch/powerpc/cpu/mpc83xxRobert P. J. Day2016-01-08-20/+20
| | | | Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
* test: add sandbox timer to test.dtsThomas Chou2016-01-07-0/+5
| | | | | | | | Add missing sandbox timer to test.dts, so that test-dm works. Signed-off-by: Thomas Chou <thomas@wytron.com.tw> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
* Merge git://git.denx.de/u-boot-mpc85xxTom Rini2016-01-07-0/+2
|\
| * powerpc, mpc5xxx: fix missing bootflag initHeiko Schocher2016-01-05-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | since: commit: f05ad9ba "Add a way to skip relocation" tqm5200s board fails to boot. Reason is that board_init_f has a function parameter bootflag, which is not setup in in arch/powerpc/cpu/mpc5xxx/start.S _start So board_init_f gets a undefined bootflag, currently the gd pointer address. Unfortunately this address sets the GD_FLG_SKIP_RELOC bit, so u-boot code gets not relocated and u-boot does not boot ... Init bootflag with 0, and tqm5200 boots fine again. Signed-off-by: Heiko Schocher <hs@denx.de> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: York Sun <yorksun@freescale.com>
* | Merge branch 'master' of git://www.denx.de/git/u-boot-imxTom Rini2016-01-03-5/+50
|\ \ | |/ |/|
| * imx_common: check for Serial Downloader in spl_boot_deviceStefano Babic2016-01-03-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check for bmode before reading the boot device to check if a serial downloader is started, and returns UART if the serial downloader is set, letting SPL to wait for an image if CONFIG_SPL_YMODEM_SUPPORT is set. This allows to load again a SPL based board with imx_usb_loader together with a tool such as kermit. Signed-off-by: Stefano Babic <sbabic@denx.de> CC: Tim Harvey <tharvey@gateworks.com> CC: Fabio Estevam <Fabio.Estevam@freescale.com> CC: Eric Nelson <eric.nelson@boundarydevices.com> Reviewed-by: Eric Nelson <eric@nelint.com> Tested-by: Eric Nelson <eric@nelint.com>
| * ARM: mxs: allow boards to select DC-DC switching clock sourceMichael Heimpold2016-01-03-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For some board designs, it might be useful to switch the DC-DC clock source to something else rather the default 24 MHz, e.g. for EMI reasons. For this, override the mxs_power_setup_dcdc_clocksource function in your board support files. Example: void mxs_power_setup_dcdc_clocksource(void) { mxs_power_switch_dcdc_clocksource(POWER_MISC_FREQSEL_20MHZ); } Signed-off-by: Michael Heimpold <mhei@heimpold.de> Cc: Marek Vasut <marex@denx.de> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Marek Vasut <marex@denx.de>
| * imx: ddr: drop duplicated debug infoPeng Fan2016-01-03-1/+0
| | | | | | | | | | | | | | Drop duplicated debug info for tcl. Signed-off-by: Peng Fan <Peng.Fan@freescale.com> Cc: Stefano Babic <sbabic@denx.de>
| * imx: mx6: fix reg base address when runtime usagePeng Fan2015-12-07-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Should use parenthese to wrap the macro definition, otherwise we will encounter error like the following: " if (base_addr != LCDIF1_BASE_ADDR) { puts("Wrong LCD interface!\n"); return -EINVAL; } " Without this patch, we will always encounter "Wrong LCD interface". Signed-off-by: Peng Fan <Peng.Fan@freescale.com> Cc: Stefano Babic <sbabic@denx.de> Reviewed-by: Stefano Babic <sbabic@denx.de>
| * imx: mx6: add missing return valueJeroen Hofstee2015-12-07-0/+2
| | | | | | | | | | | | | | cc: Peng Fan <Peng.Fan@freescale.com> Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl> Reviewed-by: Peng Fan <Peng.Fan@freescale.com> Reviewed-by: Stefano Babic <sbabic@denx.de>
* | Merge git://git.denx.de/u-boot-socfpgaTom Rini2015-12-24-3/+22
|\ \ | | | | | | | | | | | | | | | | | | Conflicts: include/configs/axs101.h Signed-off-by: Tom Rini <trini@konsulko.com>
| * | arm: socfpga: Unreset NAND in U-BootMarek Vasut2015-12-22-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | Make sure the NAND reset is not asserted in full U-Boot. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: Chin Liang See <clsee@altera.com>
| * | arm: socfpga: Unreset NAND in SPLMarek Vasut2015-12-22-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | If the system boots from NAND, make sure to de-assert the NAND IP reset, otherwise the system will get stuck. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
| * | arm: socfpga: Define NAND reset bitMarek Vasut2015-12-22-1/+2
| | | | | | | | | | | | | | | | | | | | | Define the NAND reset bit and fix the ordering of the macros. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
| * | arm: socfpga: Make /soc available in pre-relocMarek Vasut2015-12-22-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | This node must be available before relocation, otherwise the board will not find mmc and will thus not boot. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
| * | arm: socfpga: Actually enable L2 cacheMarek Vasut2015-12-22-2/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | The L2 cache was never enabled in the v7_outer_cache_enable(), fix this and enable the L2 cache. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: Chin Liang See <clsee@altera.com>
* | | ARM: dts: uniphier: add SD/MMC pinmux nodesMasahiro Yamada2015-12-23-0/+15
| | | | | | | | | | | | Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* | | ARM: uniphier: set DTB file name to fdt_file environmentMasahiro Yamada2015-12-23-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we want to boot Linux with a DTB file downloaded from a TFTP server or somewhere, we need to know the file name to be downloaded. Assume the U-Boot configuration is shared among some similar boards. If they are similar enough, the difference only appears in device trees. The build procedure would be like this: - Board A: make foo_common_defconfig && make DEVICE_TREE=foo_board_a - Board B: make foo_common_defconfig && make DEVICE_TREE=foo_board_b - Board C: make foo_common_defconfig && make DEVICE_TREE=foo_board_c In this case, the U-Boot image contains nothing about the DTB file name it is running with. (CONFIG_DEFAULT_DEVICE_TREE is not helpful for this purpose because it is painful to change it from "make menuconfig" for each board.) This commit allows to lookup the DTB file name based on the compatible string and set it to "fdt_file" environment. Then "tftpboot $fdt_file" will download the file we want. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* | | ARM: uniphier: merge umc/ and ddrphy/ into a single directoryMasahiro Yamada2015-12-23-15/+11
| | | | | | | | | | | | | | | | | | | | | | | | The UMC (Universal Memory Controller) and the DDR PHY block are highly related to each other. It is better to have both code in the same directory. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>