summaryrefslogtreecommitdiffstats
path: root/arch
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'for-next/spd'Sascha Hauer2019-03-073-10/+10
|\
| * ddr_spd: Update from U-BootSascha Hauer2019-03-043-10/+10
| | | | | | | | | | | | | | | | | | | | | | This updates the ddr_spd.h header file from U-Boot-2019.01 with some small changes: - typedefs are removed - "_s" suffix from struct types removed - remove unnecessary "extern" from function declarations Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/rpi'Sascha Hauer2019-03-0717-73/+243
|\ \
| * | ARM: rpi: Add mini UART debug_ll supportSascha Hauer2019-03-061-0/+37
| | | | | | | | | | | | | | | | | | | | | The raspberry pi 3 comes up with the mini UART as default, so allow to use it for debug_ll output. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: rpi: move debug UART Kconfig settingsSascha Hauer2019-03-062-24/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In contrast to other architectures, R.Pi debug UART config was placed under the "System Type" menu, not under the "Debugging -> low-level debugging port". This made this setting easy to miss when enabling low level debug mesages. While at it use the existing base address defines rather than defining them again in Kconfig. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | debug_ll: Move pl011 header file to architecture independent placeSascha Hauer2019-03-066-30/+5
| | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: rpi: Move UART base address definitions to header fileSascha Hauer2019-03-062-4/+5
| | | | | | | | | | | | | | | | | | Move defines to header file to make them reusable. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: rpi: save bootargs from VC FDT to vc.bootargsTomaz Solc2019-03-041-0/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When booting a Raspberry Pi, it is useful to extract bootargs from the device tree that was created by the VideoCore firmware. These bootargs contain for example settings for the framebuffer that the kernel needs to properly set the video output. This commit extracts the bootargs in the board initialization code and saves them to the vc.bootargs global variable. For example, a bootloader environment can then add the contents of this variable to linux.bootargs.vc, which then gets included into the final bootargs for the kernel using CONFIG_FLEXIBLE_BOOTARGS. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: rpi: save fdt that was passed from VideoCoreTomaz Solc2019-03-043-19/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Raspberry Pi, VideoCore firmware creates a device tree that contains information about peripherals that were initialized by VideoCore based on settings in config.txt. Normally this device tree is passed to the Linux kernel via a pointer in the r2 register. A bootloader needs to pass this device tree to the kernel, or some peripherals will not work correctly. Since the VideoCore device tree is not compatible with barebox, we can't just pass it to barebox_arm_entry() as the internal barebox device tree. This commit makes the prebootloader code copy the device tree from VideoCore into a scrap RAM area just above the area reserved for the bootloader. Board initialization code in the bootloader proper then copies it into a file /vc.dtb. The bootloader environment is then free to pass this file to the kernel at boot (e.g. via bootm -o). Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: start: save end of memory passed to start.Tomaz Solc2019-03-042-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | Knowing the address of the end of the memory area used by Barebox is useful if PBL stores some extra data after it, so that board init code can later retrieve it from there. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: rpi: add CONFIG_PINCTRL to rpi_defconfig.Tomaz Solc2019-02-191-1/+1
| | | | | | | | | | | | | | | | | | Required for emmc pin function switching on Raspberry Pi 3. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: rpi: Add device tree for Compute Module 3.Tomaz Solc2019-02-194-0/+35
| | | | | | | | | | | | | | | | | | | | | Compute Module needs "no-sd" property on the MMC interface otherwise mci-bcm2835 hangs on SD card probe. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | pinctrl: bcm2835: move existing code from gpio.Tomaz Solc2019-02-191-1/+1
| | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | ARM: rpi: switch emmc from sdhost to sdhciTomaz Solc2019-02-191-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | BCM2837 has two mmc interfaces: sdhost and sdhci. On Raspberry Pi 3, sdhost is normally used for SD card/MMC flash and sdhci for the wireless interface. Barebox currently only has a driver for sdhci, so we disable the sdhost interface and remap the pins so that the sdhci has access to the SD card/MMC flash. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | Merge branch 'for-next/misc'Sascha Hauer2019-03-078-8/+674
|\ \ \
| * | | images: pbl: verify CONFIG_BAREBOX_MAX_IMAGE_SIZE is not exceededAhmad Fatoum2019-03-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For platforms such as the at91, the boot ROM imposes an upper limit on barebox file size. Prior to 5a1a5ed253 ("ARM: images: use piggydata"), BAREBOX_MAX_PBLX_SIZE seems to have been the way to go for limiting the size of the final barebox binary when using the PBL. With pblx removed, this variable is of no use, so have the existing BAREBOX_MAX_IMAGE_SIZE replace its functionality. Currently BAREBOX_MAX_IMAGE_SIZE is only checked against in the non-PBL case, so add a check in the PBL case as well. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | fix zbarebox linking with new ld张忠山2019-03-071-1/+1
| | | | | | | | | | | | | | | | | | | | Signed-off-by: 张忠山 <zzs213@126.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: Fix cpu_info for armv8Sascha Hauer2019-03-041-5/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We have get_cr() to get the control register for the different exception levels. Use it rather than the variant hardcoded for EL1. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | MIPS: ath79: increase malloc size to 8 MiBOleksij Rempel2019-02-271-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | with 4 MiB we are not able even to start latest kernel. Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | firmware-zynqmp: port from linuxThomas Haemmerle2019-02-274-1/+669
| |/ / | | | | | | | | | | | | | | | | | | Port Xilinx Zynq MPSoC Firmware layer driver from linux. Signed-off-by: Thomas Haemmerle <thomas.haemmerle@wolfvision.net> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | Merge branch 'for-next/imx'Sascha Hauer2019-03-0731-525/+2227
|\ \ \
| * | | ARM: dts: imx6*phytec*: switch to new partitioning schemeUwe Kleine-König2019-03-079-141/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Both Linux and barebox support this new scheme and it's the actually the recommended one. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: i.MX6UL: liteSOM: depend on DDR controller settingsMarcin Niestroj2019-03-072-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Initially we depended on DDR controller settings for liteSOM and liteboard. With 33fdc89d4cbd ("dts: update to v5.0-rc1") a `device_type = "memory";` property was added to imx6ul-litesom.dtsi file, which causes "ram0" to be added with 512MB size (value in dtsi) instead of the real 256MB size that is configured in barebox-grinn-liteboard-256mb.img. As a result Linux kernel fails to boot. Lets depend on DDR controller settings, by removing whole `/memory` node from device tree. This makes barebox-grinn-liteboard-256mb.img able to boot Linux kernel once again. Reported-by: Bartosz Bilas <b.bilas@grinn-global.com> Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | esdhc-xload: Move to drivers/mciSascha Hauer2019-03-053-384/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The esdhc-xload code will be used by upcoming Layerscape support aswell, so move it from architecture code to drivers/mci/. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: imx8mq-zii-ultra: Add USB related nodesAndrey Smirnov2019-03-042-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add nodes for exposed USB ports as well as USB hub connected to one of them. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: dts: imx8mq: Add nodes for USB IP blocksAndrey Smirnov2019-03-041-0/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add node for USB IP block that is missing in upstream DTS. This patch should be reverted once that changes. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: imx8mq-zii-ultra: Enable PCIE1 and PCIE2Andrey Smirnov2019-03-041-0/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Enable PCIE1 and PCIE2 used on both Zest and RMB3 boards. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: imx8mq: Add nodes for PCIE1 and PCIE2 IP blocksAndrey Smirnov2019-02-271-0/+89
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add node for PCE1 and PCIE2 IP block that is missing in upstream DTS. This patch should be reverted once that changes. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: imx8mq: Add node for GPC IP blockAndrey Smirnov2019-02-271-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add node for GPC IP block that is missing in upstream DTS. This patch should be reverted once that changes. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: imx8mq: Add node for SRC IP blockAndrey Smirnov2019-02-271-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add node for SRC IP block that is missing in upstream DTS. This patch should be reverted once that changes. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: phyCORE-i.MX8M SOM supportChristian Hemp2019-02-2513-0/+1711
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The phyCORE-i.MX8M aka PCL-066 is a SoM containing a i.MX8M SoC. phyCORE-i.MX8M: - 1GB LPDDR4 RAM - eMMC - microSD - Ethernet Signed-off-by: Christian Hemp <christian.hemp@posteo.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: phytec-som-imx6: make use of new imd oftree helperUwe Kleine-König2019-02-251-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With this patch the two last lines are added to the output of the following command: $ ./scripts/bareboximd images/barebox-phytec-phycore-imx6dl-som-emmc-1gib.img build: #15 Thu Feb 21 11:20:23 CET 2019 release: 2019.02.0-00235-gb03cf6f145ae-dirty parameter: memsize=1024 of_compatible: phytec,imx6dl-pcm058-emmc fsl,imx6dl model: Phytec phyCORE-i.MX6 DualLite/SOLO with eMMC Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: i.MX8MQ: Check CPU type in imx8mq_init_syscnt_frequency()Andrey Smirnov2019-02-181-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add code to make sure that imx8mq_init_syscnt_frequency() is only executed on i.MX8MQ. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: i.MX8MQ: Add code to report HDMI/eDP firmware versionAndrey Smirnov2019-02-181-0/+40
| |/ / | | | | | | | | | | | | | | | | | | | | | Port code found in cdn_dp_load_firmware() in Linux kernel to check if HDMI firmware is running and, if so, report its version. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | Merge branch 'for-next/efi'Sascha Hauer2019-03-071-0/+3
|\ \ \ | |_|/ |/| |
| * | efi_defconfig: enable watchdog supportOleksij Rempel2019-02-181-0/+3
| |/ | | | | | | | | Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | clk: at91: update to PMC bindingsSam Ravnborg2019-02-251-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Based on kernel 5.0-rc6 update at91 clk support to match the new PMC bindings. Manually added all changes done in the kernel from 4.9-rc3 to 5.0-rc6. New drivers required was added as seperate commits. This includes dt-compat code required to support at91sam5d3, as this is not yet ported to use the new PMC bindings. clk-programmable saw some extra changes - it had never been bulit. It is used only by at91sama5d2 - and barebox has no board support for this cpu (yet). The CONFIG_SOC symbols is used to select the relevant drivers. CONFIG_SOC_SAM9 selects several drivers, and in the future this can be split to keep the image size down. In the kernel CLK_OF_DECLARE_DRIVER() can be used for a two step init. In barebox this is a simple one step init. It was added to have less differences between the kernel and the barebox versions of the drivers. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Tested-by: Ladislav Michl <ladis@linux-mips.org> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | arm: at91: add SOC_SAMA5{D2,D3,D4}Sam Ravnborg2019-02-251-2/+18
| | | | | | | | | | | | | | | | | | | | | | This split allows us to distingush between the SOC types. The SOC symbols will be used in following patches. SOC_SAMA5D2 is essential unused for now,, and only added to prepare for future use Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Tested-by: Ladislav Michl <ladis@linux-mips.org> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | arm: at91: fix at91_configure_usart6 warningSam Ravnborg2019-02-251-0/+1
|/ | | | | | | | | | | Add declaration to silence following warning: arch/arm/mach-at91/sama5d4_devices.c:487:24: warning: no previous prototype for ‘at91_configure_usart6’ Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Tested-by: Ladislav Michl <ladis@linux-mips.org> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/rpi'Sascha Hauer2019-02-136-55/+84
|\
| * ARM: rpi: complete new revision schemeMoritz Augsburger2019-02-052-24/+47
| | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: rpi: make locally used functions staticRoland Hieber2019-02-052-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These functions are not meant to be a public interface, so they can well be static. rpi_b_plus_init() was previously declared with a prototype, which is no longer needed. This fixes the following build warnings: .../arch/arm/boards/raspberry-pi/rpi-common.c:124:6: warning: no previous prototype for 'rpi_add_led' [-Wmissing-prototypes] void rpi_add_led(void) ^~~~~~~~~~~ .../arch/arm/boards/raspberry-pi/rpi-common.c:141:6: warning: no previous prototype for 'rpi_b_init' [-Wmissing-prototypes] void rpi_b_init(void) Signed-off-by: Roland Hieber <rhi@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: rpi: use defines for uart basesRouven Czerwinski2019-02-051-3/+7
| | | | | | | | | | | | | | | | Previously the clkdev_add_phybase was called on magic register values, add defines which clarify the device for which the phybase clkdev is created. Signed-off-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: rpi: choose miniuart as stdoutRouven Czerwinski2019-02-051-6/+1
| | | | | | | | | | | | | | | | | | Since we now support the miniuart, enable it as the default stdout port. With this change the device tree overlay to switch the miniuart to bluetooth is no longer necessary. Signed-off-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: rpi: add NS16550 supportRouven Czerwinski2019-02-051-0/+1
| | | | | | | | | | | | | | | | Since the 16550 driver now supports the RPI3 miniuart, enable it in the default config. Signed-off-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: rpi: retrieve miniuart clock from firmwareRouven Czerwinski2019-02-051-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | The miniuart uses the core clock as the clock source. This clock is fixed by the firmware to 250Mhz if enable_uart=1 is set in the config.txt file. However a user could still choose to overclock the core frequency, which would result in wrong baudrates computed by barebox. Retrieve the core clock frequency from the firmware to allow all potential firmware configurations to work with barebox. Signed-off-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: rpi: move clks into board specific rpi-commonRouven Czerwinski2019-02-052-19/+19
| | | | | | | | | | | | | | | | | | | | | | | | We don't know if the firmware running on the raspberry pi is the same firmware which is running on all bcm283x devices. Therefore move the console clock initialization into the rpi-common.c board file. A future commit will use this function to retrieve the miniuart clock from the raspberry pi firmware. No functional changes. Signed-off-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: rpi: fix typo in rpi-common.cRouven Czerwinski2019-02-051-2/+2
| | | | | | | | | | Signed-off-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/pci'Sascha Hauer2019-02-131-1/+2
|\ \
| * | PCI: Convert ->res_start() to return resource_size_tAndrey Smirnov2019-01-161-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On 64-bit machines int doesn't cover full address space, so convert .res_start to both accept resource_size_t as a parameter and return it as result. Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>