Commit Graph

60120 Commits

Author SHA1 Message Date
Ashok Reddy Soma
0384ac0583 gpio: zynq: fix issue in set gpio output direction
This patch fixes zynq_gpio_direction() to call driver specific
zynq_gpio_set_value function rather than top level gpio_set_value.

Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:53:04 +02:00
Siva Durga Prasad Paladugu
b82d520c34 arm64: versal: Remove unneeded configs for mini configurations
The PSCI_RESET and EXPERT are not needed for mini configurations so remove
them to save space.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
5bbc4dc038 arm64: versal: mini_emmc: Enable fatwrite support
This patch enable fatwrite support for mini emmc configurations.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
2019-10-08 09:41:27 +02:00
T Karthik Reddy
f8c0f9fa7c env: Kconfig: Add environment default offset in versal
This patch adds default offset & sector size values for environment
variables to save in qspi/ospi flash for versal.

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
T Karthik Reddy
1a031d236a drivers: usb: dwc3: setup phy before dwc3 core soft reset
Phy setup should be done before dwc3 soft core reset as it is done
in linux & this fixes unreliable detection of usb cable on host side.

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
T Karthik Reddy
0d0fbc857c arm64: zynqmp: Enable 2 NAND chips support for zynqmp_mini_nand
This patch enables 2 nand chips support for zynqmp mini nand

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
T Karthik Reddy
ad704bbdba doc: README.xilinx: Add dt bindings
Devicetree bindings are already specified in Linux kernel documentation.
Instead of maintaining same dt bindings in U-Boot doc specify path to dt
bindings in Linux kernel & documenting specific changes that are in U-Boot.

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Tested-by: Bin Meng <bmeng.cn@gmail.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
c95b19acac mmc: zynq_sdhci: Remove check for DM_MMC config
The zynq_sdhci drivers depends on DM_MMC in Kconfig so no need to check for
DM_MMC in the driver so this patch removes it.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
b96b695f2c arm64: zynqmp: Switch spi-flash to jedec, spi-nor compatible
Change has been done across the whole tree only zynqmp-mini-qspi hasn't
been fixed.
Origin changed done by commit ffd4c7c2ec
("dts: switch spi-flash to jedec, spi-nor compatible")

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
f41e588c03 net: phy: Add gmiitorgmii converter support
This patch adds support for gmiitorgmii converter.
This converter sits between the MAC and the external phy
MAC <==> GMII2RGMII <==> RGMII_PHY.
The ethernet driver probes this bridge and this bridge driver
probes real phy driver and invokes the real phy functionalities
as requested. This bridge just needs to be configured based on
real phy negotiated speed and duplex.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
83a0e8054e ARM: zynq: Remove all Xilinx private commands
All platforms have been moved to distro boot that's why remove the rest of
configurations to have unified boot flow.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
a542a93735 ARM: zynq: Use {} around variables for qspi and nand boot cmds
Follow conventions and used {} around variables.

Fixes: 90e97ab31e ("arm: zynq: Define distro boot commnads for qspi, nand and nor")
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
90b9fcb9d4 ARM: zynq: Fix NOR boot mode
There are two typos in this command that's why it couldn't work properly.
This bootmode is almost unused from the beggining on this SoC.

Fixes: 90e97ab31e ("arm: zynq: Define distro boot commnads for qspi, nand and nor")
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
559e5a68f4 ARM: zynq: Enable USB1 as secondary boot device
Xilinx Zynq SoC has two usb controllers and both could be used as secondary
boot method.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
7712fb1ff7 ARM: zynq: Specify MMC controller number for boot sequence
Xilinx Zynq SoC has two sdhci controllers but boot is only possible from
the first one. That's why there is a need to specify controller number.
mmc1 is supposed to be secondary boot device and should be also listed in
distribution boot.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
be49508a0f net: phy: Define init routine and register generic phy driver
This patch define init routine for generic phy driver and registers it
using phy_register as this generic phy driver also needs to be relocated
incase of manual reloc.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Vipul Kumar
69b67ec8c9 ARM: zynq: dts: Added alias for usb node
This patch added alias for usb node in dts file.

Signed-off-by: Vipul Kumar <vipul.kumar@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
a6af30908b ARM: zynq: Align model name with DT
Use model property to distinguish different configurations.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
134b0c8d6a arm64: zynqmp: Add idcodes for new RFSoC silicons ZU48DR and ZU49DR
Add zu48dr and zu49dr to the list of zynqmp devices. The zu48dr and zu49dr
are the new RFSoC silicons with id values of 0x7b and 0x7e.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Ashok Reddy Soma
a85f388565 arm64: versal: Fix for OCM overwriting issue
This patch reduces the console buffer size from 2048 to 1024, thus fixes
OCM overwriting issue.

Differences are in bss section as is shown from output:
xilinx_versal_mini: all -2056 bss -2048 text -8
   u-boot: add: 0/0, grow: 0/-3 bytes: 0/-2056 (-2056)
     function                                   old     new   delta
     cli_simple_run_command                     340     332      -8
     static.lastcommand                        2049    1025   -1024
     console_buffer                            2049    1025   -1024

Better would be to use PPU RAM but this change is also aligned with changes
done in ZynqMP mini configurations.

Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
8567717dff ARM: zynq: Increase input buffer console size to 2k
ZynqMP and Versal is using 2k that's why aligned all platform together to
be able to use the same scripts.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
d6d82cb0be ARM: zynq: Increase init ram size by 4K
Increase init ram size by 4K such that more stack space will be available
during initialization as the present stackspace is not sufficient if DEBUG
option is enabled and causes system hang. Increasing init ram size provides
sufficient stack space during init even if DEBUG enabled and solves the
hang issue.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
d6f48ea5ce ARM: zynq: Do not enable NETBSD support by default
This option is disable in Xilinx tree for quite a long time that's why
let's disable it in mainline. If there is anybody who requires this options
then it should be moved to Kconfig first and should be removed from this
config.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Michal Simek
23decf013b fpga: zynqmp: Fix second local variable declaration
No reason to define new_buf again.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
d882f0847c mmc: sdhci: Move ZYNQ_HISPD_BROKEN to Kconfig
This patch moves CONFIG_ZYNQ_HISPD_BROKEN to Kconfig

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
bc493d911e net: zynq_gem: Remove check for Versal
This patch removes check for Versal platform
in gem driver as it now supports clock setting
through clock framework.

Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:27 +02:00
Siva Durga Prasad Paladugu
95105089af clk: versal: Add clock driver support
This patch adds clock driver support for Versal platform. The clock driver
queries and performs clock operations using PLM firmware by communicating
with it using SMC calls.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:41:24 +02:00
Siva Durga Prasad Paladugu
1ff8bdb8d3 net: zynq_gem: Add new versal compatible string
This patch adds new versal compatible string to GEM driver for Versal
platform.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:35:43 +02:00
Michal Simek
74969a074c net: gem: Remove DECLARE_GLOBAL_DATA_PTR from gem driver
GD is not used anywhere that's why there is no reason to have this macro
in the driver.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:35:43 +02:00
Siva Durga Prasad Paladugu
5d2274c00f arm64: zynqmp: Add new jtag distro boot command
This patch adds new jtag distro boot command to look for bootscript file in
DDR and execute it first incase of jtag bootmode.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:35:43 +02:00
Siva Durga Prasad Paladugu
81764f5361 arm64: zynqmp: Update scriptaddr value to 512MB
This patch updates scriptaddr value to 512MB as having it at 32MB has high
chance of script corruption incase of bigger kernel.

Be aware that 512MB is used for SPL malloc area that's why images should be
loaded after SPL (the best after u-boot relocation).

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:35:43 +02:00
T Karthik Reddy
e76bc3cbc0 arm64: versal: Change boot script offset address in versal
With the current boot script offset address in qspi is being overlaped
by BOOT.BIN as it is over 90MB with fpga included. So moving the script
offset address to end of flash after "bootenv" mtd partition. Here we
are considering qspi flash size >= 128Mbytes on versal and left
512Kbytes space to save boot.scr script.

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:35:43 +02:00
T Karthik Reddy
f0c16cd6f3 arm64: versal: Add new dfu usb distro boot command
This patch adds new dfu usb distro boot command to look for bootscript
from dfu-util and runs it.

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
2019-10-08 09:35:43 +02:00
Siva Durga Prasad Paladugu
3d865acb70 arm64: versal: Add new jtag distro boot command
This patch adds new jtag distro boot command to look for bootscript file
in DDR and execute it first incase of jtag bootmode.
This patch also updates scriptaddr to 512MB as there is high of script
corruption incase of bigger kernel image.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:35:43 +02:00
Siva Durga Prasad Paladugu
37d53180cd arm64: versal: Define configs related to USB DFU functionality
This patch defines macros required for DFU functionality
for Xilinx Versal platform.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:35:43 +02:00
Rajan Vaja
14723ed544 zynqmp: firmware: Add Xilinx ZynqMP firmware driver
Add simple ZynqMP firmware drive to populate child nodes under
zynqmp_firmware DT node.

Signed-off-by: Rajan Vaja <rajan.vaja@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Michal Simek
3899ebdd88 arm64: zynqmp: Provide a Kconfig option to disable OCM and TCM MMU mapping
This patch provides an option to enable/disable OCM and TCM memory into MMU
table with corresponding memory attributes.

The same change was done for ZynqMP by commit 189bec47ab
("arm64: zynqmp: Provide a Kconfig option to define OCM and TCM in MMU")

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Michal Simek
aef149e9dd arm64: versal: Enable memory mapping via DT
Code reads DT and setup MMU table based on memory node. This will ensure
that only DT needs to be changed.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
T Karthik Reddy
a69814c815 arm64: zynqmp: Set initrd_high to as high as possible
This patch is setting up the initrd_high to as high as possible by leaving
max stack size for u-boot so that bigger rootfs can also be loaded by
u-boot for booting kernel.

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Siva Durga Prasad Paladugu
085201c246 arm64: versal: Set initrd_high to as high as possible
This patch is setting up the initrd_high to as high as possible by leaving
max stack size for u-boot so that bigger rootfs can also be loaded by
u-boot for booting kernel.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Siva Durga Prasad Paladugu
26e054c943 arm64: versal: fpga: Add PL bit stream load support
This patch adds PL bitstream load support for Versal platform. The PL
bitstream is loaded by making an SMC to ATF which in turn communicates
with platform firmware which configures and loads PL bitstream on to PL.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Michal Simek
13210cd951 arm64: versal: Also record versal name to versal fragment
Just to make sure that also drivers with versal name are assigned to proper
fragment.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Siva Durga Prasad Paladugu
bfd092f9ca arm64: versal: Define board_late_init for versal
Define board_late_init which performs bootmode detection
and prepares corresponding distro boot commaand sequence.

Also disable it for mini platforms because simply there is no need to have
it enabled.
But also disable it for virtual platform because Qemu is not modelling this
register space that's why travis testing would fail. This configuration
should be reverted when mainline Qemu is updated.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Michal Simek
cbe3101018 arm64: zynqmp: Enable SPI support in SPL for zcu104
It is enabling this mode but full boot is not validated yet.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Michal Simek
dd3c7b6ea1 arm64: zynqmp: Add u-boot,dm-pre-reloc to clk300 node
This node is used by qspi driver for supporting qspi boot mode in SPL.

Similar changes have beeen done by commit a9022b017a
("ARM64: zynqmp: Add u-boot,dm-pre-reloc to clk nodes")

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:14 +02:00
Michal Simek
0317a2c8c2 arm64: zynqmp: Enable gpio hog support for zcu102
Gpio hogs are used for GT mux setup after power up.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:13 +02:00
Siva Durga Prasad Paladugu
91a5964f3b xilinx: Add sd boot command script for reference
This patch adds sdboot command script for reference.
This can be converetd into uboot script using mkimage and
use for booting.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:13 +02:00
Siva Durga Prasad Paladugu
3796d133a0 xilinx: Add qspi boot command script for reference
Thsi patch adds qspiboot command script for reference.
This can be converetd into uboot script using mkimage and
use for booting.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2019-10-08 09:11:13 +02:00
Michal Simek
0413f9c3e6 arm64: zynqmp: Define default SPL_TEXT_BASE address in Kconfig
Define default address via Kconfig. There is no need to change this address
for most of the boards but it is also possible. This one line save a lot of
lines in defconfigs that's why make sense to do it.

The similar change has been done by commit 9340d8fe8b
("sunxi: move CONFIG_SPL_TEXT_BASE from *_defconfig to Kconfig")

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Luca Ceresoli <luca@lucaceresoli.net>
2019-10-08 09:11:13 +02:00
Tom Rini
61ba1244b5 Prepare v2019.10
Signed-off-by: Tom Rini <trini@konsulko.com>
2019-10-07 17:14:02 -04:00