Peng Fan [Thu, 19 May 2016 05:02:16 +0000 (13:02 +0800)]
imx: mx7: implement reset_misc
We need to power down lcdif to make 'reset' can pass stress test.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Sebastien Bourdelin [Fri, 20 May 2016 18:19:52 +0000 (14:19 -0400)]
cosmetic: mx6slevk: Minor coding-style fix
Fix the brace indentation in board_mmc_init().
Signed-off-by: Sebastien Bourdelin <sebastien.bourdelin@savoirfairelinux.com>
Peng Fan [Tue, 24 May 2016 12:28:47 +0000 (20:28 +0800)]
imx: mx6qsabreauto: drop duplicated net phy configuration
In 'commit
d584c68ce0f5bf2f430ccfb2ba00bd506206fb91',
ar8031 is changed to use ar8035_config. ar8035_config
actually does the same thing as mx6_rgmii_rework, so
drop mx6_rgmii_rework and board_phy_config.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Stefano Babic <sbabic@denx.de>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
Acked-by: Stefano Babic <sbabic@denx.de>
Tim Harvey [Tue, 24 May 2016 18:03:59 +0000 (11:03 -0700)]
imx: ventana: add fdt fixup to enable UHS-I support on selected boards
UHS-I support is available on Ventana boards with micro-SD sockets depending
on the board revision. For backwards compatibility to not break users
who have old bootloaders and newer kernels the device-tree on boards with
microSD disables UHS-I support by default by defining the no-1-8-v property
in the esdhc controller node. For models/revisions that support switchable
1.8V/3.3V I/O which is detectable by the presence of a pull-down on the
SD3_VSELECT pin we remove that property to enable support in the kernel.
Additionally we add SD3_VSELECT to the pinmux for clarity (even though U-Boot
does not currently support UHS-I modes requiring 1.8V I/O).
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:58 +0000 (11:03 -0700)]
imx: ventana: add GW553x support
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:57 +0000 (11:03 -0700)]
imx: ventana: remove several EEPROM config bit dependence
Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).
Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:56 +0000 (11:03 -0700)]
imx: ventana: remove dependence on EECONFIG_SATA eeprom feature bit
The MSATA feature is a board-specific feature on Gateworks Ventana boards.
In most cases a 2:1 mux will steer either PCIe or SATA to a miniPCIe socket
through an MSATA_EN gpio. In these such cases assign the gpio in the board
specific struct and use its presence to determine if we default the GPIO to
PCIe and if we later steer it according to hwconfig.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:55 +0000 (11:03 -0700)]
imx: ventana: enable pwm device-tree property based on hwconfig
Most Ventana boards have a connector with off-board digital-I/O signals
including some that can be pinmuxed as either a PWM or a GPIO. The hwconfig
env variable is used to configure these and they will be pinmuxed according
to this configuration in the bootloader.
This patch adds a device-tree fixup that will enable the pwm controller
nodes appropriately for digital-I/O's that are configured as pwm via hwconfig
so that the pin can be used with the Linux kernel /sys/class/pwm API.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:54 +0000 (11:03 -0700)]
imx: ventana: fix invalid dio configuration for pwm mode
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:53 +0000 (11:03 -0700)]
imx: ventana: export backlight gpio after gpio driver is available
Calling request_gpio to register bklt_gpio with the GPIO driver had no effect
in setup_display called from early board init (although pinmuxing it and
configuring it as output-low does do what it should). Therefore move the
request_gpio later in enable_lvds so that its registered for use by the
gpio command if LVDS is actually enabled.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:52 +0000 (11:03 -0700)]
imx: ventana: gsc: show board temp on boot
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:51 +0000 (11:03 -0700)]
imx: ventana: gsc: fix negative temperature readings
The GSC Temperature sensor is a 2's complement value - adjust accordingly
for negative temperatures.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:50 +0000 (11:03 -0700)]
imx: ventana: gsc: add gsc sleep command
The Gateworks System Controller on Ventana boards has the ability to
disable the board's primary power supply until the RTC hits a specific
time. When sleeping a button-down event on the GSC user pushbutton will
wake the board before it's wake time has been reached. This feature is
referred to as GSC sleep.
Add a command to invoke sleep mode for a specified number of seconds.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:49 +0000 (11:03 -0700)]
imx: ventana: SPL: added support for 32bit IMX6DQ 8Gb density DRAM config
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:48 +0000 (11:03 -0700)]
imx: ventana: SPL: only disable boot watchdog if Falcon mode
If not booting Falcon mode, leave the boot watchdog enabled as a work-around
for other non-resolved bootloader hangs.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:47 +0000 (11:03 -0700)]
imx: ventana: config: add PREBOOT support
This allows the 'preboot' env variable to be executed prior to bootcmd
if defined.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:46 +0000 (11:03 -0700)]
imx: ventana: config: use explicit addr in loadscript
If we are loading a script to ${loadaddr} then we need to use that address
explicitly when calling the source command in case user has changed loadaddr
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:45 +0000 (11:03 -0700)]
imx: ventana: config: use fs env var for block dev filesystem type
In order to make the default boot scripts more flexible, use the variable
'fs' to specify the filesystem type to use for block storage devices
(USB/MMC/SATA) when loading files.
Additionally default this to ext4 and enable ext4 filesystem support
(which encompasses ext2 support) instead of just ext2 support.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:44 +0000 (11:03 -0700)]
imx: ventana: config: use bootdir env var for directory of fdt files
In order to make the default boot scripts more flexible, use the variable
'bootdir' to specify the filesystem directory to look for fdt files in.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:43 +0000 (11:03 -0700)]
imx: ventana: config: add fixfdt script to apply manual fdt fixups
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Tue, 24 May 2016 18:03:42 +0000 (11:03 -0700)]
imx: ventana: config: add env vars for disk and part
In order to make the default boot scripts more flexible, use the variable
'disk' to specify the disk device number and the variable 'part' to specify
the partition number.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Sebastien Bourdelin [Thu, 21 Apr 2016 17:37:04 +0000 (13:37 -0400)]
ts4800: add CONFIG_SYS_FSL_ERRATUM_ESDHC_A001
This commit fixes the MMC data transactions timeout problem on the
TS4800.
The changes introduced in the commit
e978a31 on the timeout calculation
for the MMC data transactions has revealed there is something wrong with
the timeout setting of the eSDHC controller used in the IMX51.
The IMX51 seems to be concerned by this erratum and without this change
the MMC driver is unable to do any transactions.
Signed-off-by: Sebastien Bourdelin <sebastien.bourdelin@savoirfairelinux.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
Damien Riegel [Thu, 21 Apr 2016 21:34:02 +0000 (17:34 -0400)]
ts4800: update environment to boot with device tree
This commit updates the environment variables to be able to boot with a
device tree. The expected partition layout on the SD card is:
- partition 1: type 0xDA, contains u-boot.bin
- partition 2: type 0xC (fat), contains zImage and device tree
- partition 3: type 0x83, root filesystem.
Signed-off-by: Damien Riegel <damien.riegel@savoirfairelinux.com>
Tim Harvey [Mon, 23 May 2016 15:25:29 +0000 (08:25 -0700)]
imx: ventana: remove SPL_EXT_SUPPORT
Remove SPL_EXT_SUPPORT to resolve build issue. It may be useful to bring
it back in the future after comparing its merits to storing the args/kernel
in fixed raw locations.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Mon, 23 May 2016 15:25:28 +0000 (08:25 -0700)]
imx: ventana: use EEPROM register for falcon boot mode
NAND+MMC env support costs 12KB in the SPL which is fairly expensive just
for the ability to specify whether or not to boot to uboot or directly
to linux. The Ventana boards have plenty of EEPROM storage so we will use
a byte there to signify if we should boot to the bootloader or to the OS.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Mon, 23 May 2016 15:25:27 +0000 (08:25 -0700)]
imx: ventana: gsc: remove dependence on env
remove dependence on getenv() by using global board info struct for model.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Tim Harvey [Mon, 23 May 2016 15:25:26 +0000 (08:25 -0700)]
imx: ventana: config: remove redundant config
remove redundant define that exists in mx6_common.h
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Peng Fan [Mon, 23 May 2016 10:36:06 +0000 (18:36 +0800)]
board: mx6sabresd/auto: use simpler runtime cpu dection macros
Use simpler runtime cpu dection macros.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:36:05 +0000 (18:36 +0800)]
block: dwc_ahsata: support i.MX6DQPlus
i.MX6DQPlus support sata interface, so not return failure
when CPU is i.MX6DQPlus.
In this patch, also use simpler runtime cpu dections macros to replace
is_cpu_type.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Tang Yuantian <Yuantian.Tang@freescale.com>
Cc: Shaohui Xie <Shaohui.Xie@freescale.com>
Cc: Bin Meng <bmeng.cn@gmail.com>
Peng Fan [Mon, 23 May 2016 10:36:04 +0000 (18:36 +0800)]
net: fec_mxc: use simpler runtime cpu dection macros
Use simpler runtime cpu dection macros.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Joe Hershberger <joe.hershberger@ni.com>
Peng Fan [Mon, 23 May 2016 10:36:03 +0000 (18:36 +0800)]
ocotp: mxc: use simpler runtime cpu dection macros
Use simpler runtime cpu dection macros.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:36:02 +0000 (18:36 +0800)]
mtd: nand: mxs: use simpler runtime cpu dection macros
Use simpler runtime cpu dection macros.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Scott Wood <oss@buserror.net>
Peng Fan [Mon, 23 May 2016 10:36:01 +0000 (18:36 +0800)]
imx-common: timer: support i.MX6DQPlus
To i.MX6DQPlus, osc can be choosed as the source of gpt, so
add i.MX6DQPlus support in gpt_has_clk_source_osc.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:36:00 +0000 (18:36 +0800)]
imx-common: sata: return failure if not i.MX6DQPlus
The i.MX6DQPlus support sata interface, we should not
return failure when CPU is i.MX6DQPlus.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:35:59 +0000 (18:35 +0800)]
imx-common: hab: support i.MX6DQPlus
Support i.MX6DQPlus, otherwise wrong hab address will be used
for i.MX6QDPlus.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Ulises Cardenas <Ulises.Cardenas@freescale.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:35:58 +0000 (18:35 +0800)]
imx: mx6: correct get_cpu_speed_grade_hz for i.MX6DQP
Correct get_cpu_speed_grade_hz for i.MX6DQP, otherwise we
will get wrong speed grade info i.MX6DQP.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:35:57 +0000 (18:35 +0800)]
imx: mx6: ddr: support i.MX6D/QPlus
Support i.MX6D/QPlus.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:35:56 +0000 (18:35 +0800)]
imx-common: use simpler runtime cpu dection macros
Use simpler runtime cpu dection macros.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com>
Cc: "Benoît Thébaudeau" <benoit.thebaudeau.dev@gmail.com>
Peng Fan [Mon, 23 May 2016 10:35:55 +0000 (18:35 +0800)]
imx-common: hab: support i.MX6SOLO
Add i.MX6SOLO support for hab function.
The difference between i.MX6SOLO and i.MX6DL is
the number of CPU cores. Besides this, they work
the same.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com>
Cc: "Benoît Thébaudeau" <benoit.thebaudeau.dev@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:35:54 +0000 (18:35 +0800)]
imx: mx6: use simpler runtime cpu dection macros
Use simpler runtime cpu dection macros.
i.MX6DL and i.MX6SOLO work the same, so use is_mx6sdl.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:35:53 +0000 (18:35 +0800)]
imx: mx6: support i.MX6SOLO when enable/disable_ldb_di_clock_sources
i.MX6DL and i.MX6SOLO work the same, add i.MX6SOLO support
when enable/disable_ldb_di_clock_sources.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Peng Fan [Mon, 23 May 2016 10:35:52 +0000 (18:35 +0800)]
imx-common: introduce simpler macros for runtime dection
Introduce simpler macros for runtime cpu dection.
Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Acked-by: Stefano Babic <sbabic@denx.de>
Stefano Babic [Tue, 24 May 2016 12:55:06 +0000 (14:55 +0200)]
Merge branch 'master' of git://git.denx.de/u-boot
Tom Rini [Sat, 21 May 2016 00:43:27 +0000 (20:43 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-mips
Masahiro Yamada [Fri, 20 May 2016 03:13:10 +0000 (12:13 +0900)]
ARM: fix ifdef in ARMv8 lowlevel_init() again
Commit
116611937faa ("ARM: fix ifdefs in ARMv8 lowlevel_init()")
accidentally inverted the logic of CONFIG_ARMV8_MULTIENTRY.
Fixes:
116611937faa ("ARM: fix ifdefs in ARMv8 lowlevel_init()")
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tom Rini [Mon, 23 May 2016 15:51:13 +0000 (11:51 -0400)]
SPL: fat: Fix spl_parse_image_header() return value handling
The spl_parse_image_header() can return 0 and it is not an error.
Only treat non-zero return value as an error.
Signed-off-by: Marek Vasut <marex@denx.de>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
Reviewed-by: Peng Fan <van.freenix@gmail.com>
Reviewed-by: Stefano Babic <sbabic@denx.de>
Reviewed-by: Tom Rini <trini@konsulko.com>
Martin Hejnfelt [Thu, 19 May 2016 07:11:58 +0000 (09:11 +0200)]
omap3: Fix SPI registers on am33xx and am43xx
When the base registers are read from device tree the base is not
0x48030100 as the driver expects, but 0x48030000, resulting in
non functioning SPI. To deal with this, use same idea as how this
is done in the linux kernel (drivers/spi/spi-omap2-mcspi.c) and
add a structure with a field that is used to shift the registers
on these systems.
v2: Fixed commit subject line to correct cpu
Signed-off-by: Martin Hejnfelt <mh@newtec.dk>
Tom Rini [Fri, 13 May 2016 14:54:04 +0000 (10:54 -0400)]
kbuild: fixdep: Check fstat(2) return value
Coverity has recently added a check that will find when we don't check
the return code from fstat(2). Copy/paste the checking logic that
print_deps() has with an appropriate re-wording of the perror() message.
[ Linux commit :
46fe94ad18aa7ce6b3dad8c035fb538942020f2b ]
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Michal Marek <mmarek@suse.com>
Michal Simek [Wed, 4 May 2016 13:14:11 +0000 (15:14 +0200)]
spl: Setup default value for OF_LIST
OF_LIST can't remain empty that's why setup it up to default DTB.
If it is empty u-boot.img is created without FDT partition:
For example:
./tools/mkimage -f auto -A arm -T firmware -C none -O u-boot -a
0x8000000 -e 0 -n "U-Boot 2016.05-rc3 ..." -E -b -d u-boot-nodtb.bin u-boot.img
Can't set 'timestamp' property for '' node (FDT_ERR_NOSPACE)
FIT description: Firmware image with one or more FDT blobs
Created: Wed May 4 15:02:52 2016
Image 0 (firmware@1)
Description: U-Boot
2016.05-rc3-00080-gff2e12ae22a8-dirty for zynqmp
board
Created: Wed May 4 15:02:52 2016
Type: Firmware
Compression: uncompressed
Data Size: unavailable
Architecture: ARM
Load Address: 0x08000000
Default Configuration: 'conf@1'
Configuration 0 (conf@1)
Description: unavailable
Kernel: unavailable
And then image like this doesn't contain description and link to FDT and
can't boot.
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Michal Simek [Wed, 4 May 2016 13:08:00 +0000 (15:08 +0200)]
spl: fit: Print error message when FDT is not present
When FDT is not present in the image user doesn't get any error what's
wrong. Print error message if LIBCOMMON_SUPPORT is enabled.
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Seris-cc: uboot
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 1 May 2016 19:55:38 +0000 (13:55 -0600)]
mkimage: Add a quiet mode
Some build systems want to be quiet unless there is a problem. At present
mkimage displays quite a bit of information when generating a FIT file. Add
a '-q' flag to silence this.
Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Simon Glass [Sun, 1 May 2016 19:55:37 +0000 (13:55 -0600)]
image-fit: Don't display an error in fit_set_timestamp()
This function returns an error code and its caller may be able to fix the
error. For example fit_handle_file() expands the device tree to fit if there
is a lack of space.
In this case the caller does not want an error displayed. It is confusing,
since it suggests that something is wrong, when it fact everything is fine.
Drop the error.
Signed-off-by: Simon Glass <sjg@chromium.org>
Stephen Warren [Mon, 25 Apr 2016 21:55:42 +0000 (15:55 -0600)]
malloc: improve memalign fragmentation fix
Commit
4f144a416469 "malloc: work around some memalign fragmentation
issues" enhanced memalign() so that it can succeed in more cases where
heap fragmentation is present. However, it did not solve as many cases
as it could. This patch enhances the code to cover more cases.
The alignment code works by allocating more space than the user requests,
then adjusting the returned pointer to achieve alignment. In general, one
must allocate "alignment" bytes more than the user requested in order to
guarantee that alignment is possible. This is what the original code does.
The previous enhancement attempted a second allocation if the padded
allocation failed, and succeeded if that allocation just happened to be
aligned; a fluke that happened often in practice. There are still cases
where this could fail, yet where it is still possible to honor the user's
allocation request. In particular, if the heap contains a free region that
is large enough for the user's request, and for leading padding to ensure
alignment, but has no or little space for any trailing padding. In this
case, we can make a third(!) allocation attempt after calculating exactly
the size of the leading padding required to achieve alignment, which is
the minimal over-allocation needed for the overall memalign() operation to
succeed if the third and second allocations end up at the same location.
This patch isn't checkpatch-clean, since it conforms to the existing
coding style in dlmalloc.c, which is different to the rest of U-Boot.
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Fabio Estevam [Tue, 17 May 2016 13:51:44 +0000 (10:51 -0300)]
pico-imx6ul: Select CONFIG_HUSH_PARSER option
Select CONFIG_HUSH_PARSER option in order to fix the following
problem:
Unknown command 'if' - try 'help'
Unknown command 'then' - try 'help'
Unknown command 'else' - try 'help'
Unknown command 'fi' - try 'help'
Reported-by: Daiane Angolini <daiane.angolini@nxp.com>
Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Tested-by: Daiane Angolini <daiane.angolini@nxp.com>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:13 +0000 (17:55 +0300)]
eeprom: merge cmdline parsing of eeprom commands
Merge the parsing of layout aware and layout unaware eeprom commands into
one parsing function. With this change, layout aware commands now follow
the eeprom read and eeprom write conventions of making i2c bus and i2c address
parameters optional.
Cc: Heiko Schocher <hs@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:12 +0000 (17:55 +0300)]
eeprom: use eeprom_execute_command for all eeprom functions
Update eeprom_execute_command() and related code to accommodate both layout
aware and layout unaware functions.
No functional changes.
Cc: Heiko Schocher <hs@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
[trini: Make eeprom_execute_command have ulong for i2c_addr]
Signed-off-by: Tom Rini <trini@konsulko.com>
Paul Burton [Mon, 16 May 2016 09:52:14 +0000 (10:52 +0100)]
malta: Support MIPS32r6 configurations
Both real Malta boards & QEMU's Malta emulation can feature MIPS32r6
CPUs. Allow building U-Boot for such systems by selecting
CONFIG_SUPPORTS_CPU_MIPS32_R6 for Malta.
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Paul Burton [Mon, 16 May 2016 09:52:13 +0000 (10:52 +0100)]
malta: Remove ".set mips32" directive
We always build for a mips32 or higher ISA, so this ".set mips32"
directive is redundant. Once MIPSr6 support is added it will become
harmful since some instruction encodings change & this directive will
cause the older encodings to be incorrectly emitted instead of the
appropriate ones for the build.
In preparation for supporting MIPSr6, remove this redundant directive.
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Paul Burton [Mon, 16 May 2016 09:52:12 +0000 (10:52 +0100)]
MIPS: Support for targetting MIPSr6
Add support for targetting MIPS32r6 & MIPS64r6 systems, in the same way
that we currently select release 1 or release 2 targets. MIPSr6 is not
entirely backwards compatible with earlier releases of the architecture.
Some instructions are encoded differently, some are removed, some are
reused, so it is not practical to run U-Boot built for earlier revisions
on a MIPSr6 system. Update their Kconfig help text to reflect that.
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Paul Burton [Mon, 16 May 2016 09:52:11 +0000 (10:52 +0100)]
MIPS: Simplify CONFIG_SYS_CPU values
Rather than having the values for CONFIG_SYS_CPU depend upon each
architecture revision, have them depend upon the more general
CONFIG_CPU_MIPS32 & CONFIG_CPU_MIPS64 which in turn depend upon the
architecture revisions.
This is done in preparation for adding MIPSr6 support, which would
otherwise need to introduce new cases here.
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Paul Burton [Mon, 16 May 2016 09:52:10 +0000 (10:52 +0100)]
MIPS: Use unchecked immediate addition/subtraction
In MIPS assembly there have historically been 2 variants of immediate
addition - the standard "addi" which traps if an overflow occurs, and
the unchecked "addiu" which does not trap on overflow. In release 6 of
the MIPS architecture the trapping variants of immediate addition &
subtraction have been removed. In preparation for supporting MIPSr6,
stop using the trapping instructions from assembly & switch to their
unchecked variants.
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Marek Vasut [Fri, 6 May 2016 18:10:41 +0000 (20:10 +0200)]
mips: ath79: Add support for TPLink WDR4300
Add support for the TPLink WDR4300 router, which is based on the
AR9344 MIPS 74Kc CPU and has 128 MiB of RAM. The USB is supported
on this system as well.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:40 +0000 (20:10 +0200)]
mips: ath79: Add AR934x support
Add support for the Atheros AR934x WiSoCs. This patchs adds complete
system init, including PLL and DRAM init, both of which happen from
full C environment, since the AR934x has proper SRAM.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:39 +0000 (20:10 +0200)]
mips: ath79: Add support for ungating ethernet on ar933x and ar934x
Add code to ungate the ethernet controller on ar933x and ar934x .
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:38 +0000 (20:10 +0200)]
mips: ath79: dts: Add ethernet MAC nodes for ar933x
Add node for both ethernet controllers in the ar933x.
The PHY is attached only to the first ethernet controller.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:37 +0000 (20:10 +0200)]
mips: ath79: Add support for ungating USB on ar933x and ar934x
Add code to ungate the USB controller on ar933x and ar934x .
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:36 +0000 (20:10 +0200)]
mips: ath79: dts: Add generic-ehci node
Add generic EHCI node for the ChipIdea EHCI controller in the ath79.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:35 +0000 (20:10 +0200)]
mips: ath79: Fix compiler warning on const assignment
The assignment const T var; var = value; is illegal, since var is
constant. Drop the const to fix the compiler warning.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:34 +0000 (20:10 +0200)]
mips: ath79: Fix ar71xx_regs.h indent
The indent in this file triggers my OCD, so fix it. Replace multiple
spaces with tabs and align the values in one column.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
Marek Vasut [Fri, 6 May 2016 18:10:33 +0000 (20:10 +0200)]
mips: Add MIPS 74Kc tune
Add MIPS 74Kc tune Kconfig option.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Cc: Wills Wang <wills.wang@live.com>
[added missing tune-y entry in arch/mips/Makefile]
Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Marek Vasut [Thu, 5 May 2016 18:14:00 +0000 (20:14 +0200)]
mips: Fix compiler warning in cpu.c
There really is zero reason for including netdev.h in generic mips CPU code.
Removing the netdev.h from cpu.c also fixes the following compiler warning:
In file included from arch/mips/cpu/cpu.c:10:0:
include/netdev.h:204:41: warning: 'struct eth_device' declared inside parameter list [enabled by default]
int fecmxc_register_mii_postcall(struct eth_device *dev, int (*cb)(int));
^
include/netdev.h:204:41: warning: its scope is only this definition or declaration, which is probably not what you want [enabled by default]
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Paul Burton <paul.burton@imgtec.com>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Wills Wang [Tue, 12 Apr 2016 10:24:10 +0000 (18:24 +0800)]
ath79: add readonly attribute for ath79_soc_desc
use 'const' keywork to qualify readonly attribute for lookup-table member
Signed-off-by: Wills Wang <wills.wang@live.com>
Wills Wang [Tue, 12 Apr 2016 03:09:20 +0000 (11:09 +0800)]
ath79: ar933x: use BIT macro for bit shift operation
used a uniform BIT macro for register bit-field shift
Signed-off-by: Wills Wang <wills.wang@live.com>
Wills Wang [Tue, 12 Apr 2016 03:09:19 +0000 (11:09 +0800)]
ar933x: serial: Remove the explicit pinctrl setting
The correct pinctrl is handled automatically so we don't need to do it in
the driver.
Signed-off-by: Wills Wang <wills.wang@live.com>
Wills Wang [Tue, 12 Apr 2016 03:09:18 +0000 (11:09 +0800)]
ath79: spi: Remove the explicit pinctrl setting
The correct pinctrl is handled automatically so we don't need to do it in
the driver.
Signed-off-by: Wills Wang <wills.wang@live.com>
Tim Chick [Thu, 31 Mar 2016 11:51:20 +0000 (12:51 +0100)]
mips: Report reloc information in bdinfo
Signed-off-by: Tim Chick <tim.chick@mediatek.com>
Purna Chandra Mandal [Fri, 18 Mar 2016 13:06:08 +0000 (18:36 +0530)]
drivers: mtd: add Microchip PIC32 internal non-CFI flash driver.
PIC32 internal flash devices are parallel NOR flash divided into
number of banks to allow erase-programming in one while fetch and
execution continues on other. As the flash banks are memory mapped
stored code can be executed directly from flash (XIP), also there
is additional hardware logic to prefetch and cache contents to
improve execution performance. These flash can also be used to
store user data (like environment).
Flash erase and programming are handled by on-chip NVM controller.
Driver implemented driver model but MTD is not really support.
Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Purna Chandra Mandal [Fri, 18 Mar 2016 13:06:07 +0000 (18:36 +0530)]
flash: add device ID for Microchip PIC32 internal flash.
Microchip PIC32 has internal parallel flash (non-CFI compliant).
These flash devices do not support any identifier command so no
standard IDs. Added unique IDs to seperate these flash devices
from others supported by U-Boot.
Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com>
Wills Wang [Wed, 16 Mar 2016 09:00:00 +0000 (17:00 +0800)]
mips: ath79: add AP143 reference board
This patch add board-level code and base DT for AP143.
Signed-off-by: Wills Wang <wills.wang@live.com>
[updated defconfig, enabled CONFIG_USE_PRIVATE_LIBGCC=y]
Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Wills Wang [Wed, 16 Mar 2016 08:59:59 +0000 (16:59 +0800)]
mips: ath79: add AP121 reference board
This patch add board-level code and base DT for AP121.
Signed-off-by: Wills Wang <wills.wang@live.com>
[updated defconfig, enabled CONFIG_USE_PRIVATE_LIBGCC=y]
Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Wills Wang [Wed, 16 Mar 2016 08:59:58 +0000 (16:59 +0800)]
drivers: spi: add spi support for QCA/Atheros ath79 SOCs
This patch add a compatible spi driver for ath79 series SOC.
Signed-off-by: Wills Wang <wills.wang@live.com>
Reviewed-by: Thomas Chou <thomas@wytron.com.tw>
Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Wills Wang [Wed, 16 Mar 2016 08:59:57 +0000 (16:59 +0800)]
drivers: serial: add serial driver for ar933x SOC
This patch add support for ar933x serial.
Signed-off-by: Wills Wang <wills.wang@live.com>
Reviewed-by: Thomas Chou <thomas@wytron.com.tw>
Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Wills Wang [Wed, 16 Mar 2016 08:59:56 +0000 (16:59 +0800)]
drivers: pinctrl: Add simple pinctrl driver for Qualcomm/Atheros qca953x.
This is a simple pinctrl driver, it just support uart and spi pin-mux now.
Signed-off-by: Wills Wang <wills.wang@live.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
[fixed typo in commit subject line]
Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Wills Wang [Wed, 16 Mar 2016 08:59:55 +0000 (16:59 +0800)]
drivers: pinctrl: Add simple pinctrl driver for Qualcomm/Atheros ar933x.
This is a simple pinctrl driver, it just support uart and spi pin-mux now.
Signed-off-by: Wills Wang <wills.wang@live.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
[fixed typo in commit subject line]
Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Wills Wang [Wed, 16 Mar 2016 08:59:54 +0000 (16:59 +0800)]
mips: ath79: add support for QCA953x SOCs
This patch enable work for qca953x SOC.
Signed-off-by: Wills Wang <wills.wang@live.com>
Wills Wang [Wed, 16 Mar 2016 08:59:53 +0000 (16:59 +0800)]
mips: ath79: add support for AR933x SOCs
This patch enable work for ar933x SOC.
Signed-off-by: Wills Wang <wills.wang@live.com>
Wills Wang [Wed, 16 Mar 2016 08:59:52 +0000 (16:59 +0800)]
mips: add base support for QCA/Atheros ath79 SOCs
This patch add some common code for QCA/Atheros ath79 SOCs such as
DDR tuning, chip reset and CPU detection.
Signed-off-by: Wills Wang <wills.wang@live.com>
Stanislav Galabov [Wed, 17 Feb 2016 13:23:33 +0000 (15:23 +0200)]
Add support for 64-bit MIPS to examples/standalone
Signed-off-by: Stanislav Galabov <sgalabov@gmail.com>
Stanislav Galabov [Wed, 17 Feb 2016 13:23:31 +0000 (15:23 +0200)]
Fix FreeBSD loader API so that it works on both 32-bit and 64-bit targets.
Specifically tested on MIPS under QEMU (works with all combination of bit-ness and endian-ness)
Signed-off-by: Stanislav Galabov <sgalabov@gmail.com>
Stanislav Galabov [Wed, 17 Feb 2016 13:23:30 +0000 (15:23 +0200)]
Use CONFIG_IDE_SWAP_IO when running on big-endian MIPS (32 or 64-bit) in QEMU so that IDE transfers work properly
Signed-off-by: Stanislav Galabov <sgalabov@gmail.com>
Stanislav Galabov [Wed, 17 Feb 2016 13:23:29 +0000 (15:23 +0200)]
Properly calculate ATA_SECTORWORDS, using a fixed-size integer, so it works for both 32-bit and 64-bit targets
Signed-off-by: Stanislav Galabov <sgalabov@gmail.com>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:11 +0000 (17:55 +0300)]
eeprom: refactor i2c bus and devaddr parsing
Introduce parse_i2c_bus_addr() to generalize the parsing of i2c bus number and
i2c device address. This is done in preparation for merging layout aware and
layout unaware command parsing into one function.
No functional changes.
Cc: Heiko Schocher <hs@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:10 +0000 (17:55 +0300)]
arm: cm-t43: add support for eeprom layout comands
Add support for EEPROM and EEPROM layout commands for CM-T43.
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:09 +0000 (17:55 +0300)]
arm: cm-t35: add support for eeprom layout comands
Add support for EEPROM and EEPROM layout commands for CM-T35.
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:08 +0000 (17:55 +0300)]
arm: cm-t3517: add support for eeprom layout comands
Add support for EEPROM and EEPROM layout commands for CM-T3517.
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:07 +0000 (17:55 +0300)]
arm: cm-t54: add support for eeprom layout comands
Add support for EEPROM and EEPROM layout commands for CM-T54.
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:06 +0000 (17:55 +0300)]
arm: cm-t335: add support for eeprom layout comands
Add support for EEPROM and EEPROM layout commands for CM-T335.
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:05 +0000 (17:55 +0300)]
arm: cm-fx6: add support for eeprom layout comands
Add support for EEPROM and EEPROM layout commands for CM-FX6.
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:04 +0000 (17:55 +0300)]
compulab: add support for layout aware eeprom commands
Add layout definitions and implement functions for field printing/updating,
layout detection, layout assignment, and layout parsing.
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Nikita Kiryanov [Sat, 16 Apr 2016 14:55:03 +0000 (17:55 +0300)]
cmd: eeprom: add support for layout aware commands
Introduce the (optional) eeprom print and eeprom update commands.
These commands are eeprom layout aware:
* The eeprom print command prints the contents of the eeprom in a human
readable way (eeprom layout fields, and data formatted to be fit for human
consumption).
* The eeprom update command allows user to update eeprom fields by specifying
the field name, and providing the new data in a human readable format (same
format as displayed by the eeprom print command).
* Both commands can either auto detect the layout, or be told which layout to
use.
New CONFIG options:
CONFIG_CMD_EEPROM_LAYOUT - enables commands.
CONFIG_EEPROM_LAYOUT_HELP_STRING - tells user what layout names are supported
Feature API:
__weak int parse_layout_version(char *str)
- override to provide your own layout name parsing
__weak void __eeprom_layout_assign(struct eeprom_layout *layout, int layout_version);
- override to setup the layout metadata based on the version
__weak int eeprom_layout_detect(unsigned char *data)
- override to provide your own algorithm for detecting layout version
eeprom_field.c
- contains various printing and updating functions for common types of
eeprom fields. Can be used for defining custom layouts.
Cc: Heiko Schocher <hs@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>