Commit Graph

89 Commits

Author SHA1 Message Date
Tom Rini 40ace028f1 am335x_evm.h: Make 'am335x_boneblack' use redundant environment
Signed-off-by: Tom Rini <trini@ti.com>
2013-10-14 16:06:52 -04:00
Tom Rini 31cd065df0 Revert "am335x_evm.h: If mmcdev and bootpart switch to mmcdev 1, so should mmcroot."
Upon further inspection and review and chatting with kernel folks, what
happens here is that what mmcblk# a device gets is based on probe order.
So a system with an SD card inserted with place eMMC on mmcblk1, but
without an SD card, it will be on mmcblk0.  So U-boot can only provide a
best guess.  In this case, if no SD card is present, we would want to
pass mmcblk0p2 still.  If an SD card is present, it woudl be able to
provide a uEnv.txt that would be loaded (even if the kernel is NOT
there) which can still update mmcroot variable.

This reverts commit 827512fb11.

Cc: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Tom Rini <trini@ti.com>
2013-10-08 11:09:17 -04:00
Tom Rini 9f3fe6da27 Merge branch 'master' of git://git.denx.de/u-boot-arm 2013-10-08 09:51:48 -04:00
Tom Rini e3cf969205 am335x_evm: Switch to zImage as default rather than uImage
Signed-off-by: Tom Rini <trini@ti.com>
2013-10-07 07:43:46 -04:00
Tom Rini 6297872cd5 Merge branch 'master' of git://git.denx.de/u-boot-arm 2013-10-02 11:45:22 -04:00
Afzal Mohammed e473b8b65b am335x_evm: enable DFU RAM
Enable DFU for RAM, provide example dfu_alt_info

Signed-off-by: Afzal Mohammed <afzal.mohd.ma@gmail.com>
Cc: Heiko Schocher <hs@denx.de>
Cc: Tom Rini <trini@ti.com>
Cc: Marek Vasut <marex@denx.de>
Cc: Lukasz Majewski <l.majewski@samsung.com>
Cc: Pantelis Antoniou <panto@antoniou-consulting.com>
Reviewed-by: Lukasz Majewski <l.majewski@samsung.com>
2013-09-24 17:51:35 +02:00
Robert P. J. Day 827512fb11 am335x_evm.h: If mmcdev and bootpart switch to mmcdev 1, so should mmcroot.
If, in CONFIG_BOOTCOMMAND, the environment switches both the mmcdev
and bootpart variables to refer to MMC device 1, it would make sense
that the mmcroot env variable should switch to that device as well.

Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
2013-09-20 16:57:40 -04:00
Tom Rini 9721027aae am335x_evm: am33xx_spl_board_init function and scale core frequency
Add a am33xx_spl_board_init (and enable the PMICs) that we may see,
depending on the board we are running on.  In all cases, we see if we
can rely on the efuse_sma register to tell us the maximum speed.  In the
case of Beaglebone White, we need to make sure we are on AC power, and
are on later than rev A1, and then we can ramp up to the PG1.0 maximum
of 720Mhz.  In the case of Beaglebone Black, we are either on PG2.0 that
supports 1GHz or PG2.1.  As PG2.0 may or may not have efuse_sma set, we
cannot rely on this probe.  In the case of the GP EVM, EVM SK and IDK we
need to rely on the efuse_sma if we are on PG2.1, and the defaults for
PG1.0/2.0.

Signed-off-by: Tom Rini <trini@ti.com>
2013-09-20 16:57:35 -04:00
Tom Rini 47f75cf2e1 Merge branch 'master' of git://git.denx.de/u-boot-arm 2013-09-06 20:25:35 -04:00
Robert P. J. Day 3c950c4fca am335x_evm.h: Add back the actual load of the kernel image
Somewhere along the line of refactoring the am335x header files, the
kernel image load was lost, so put it back in.

Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
2013-09-06 09:36:51 -04:00
Tom Rini 85a02aa9cc am335x_evm: Regroup USB options
Signed-off-by: Tom Rini <trini@ti.com>
2013-08-28 11:44:58 -04:00
Tom Rini 610af383f1 am335x_evm: Add comment by SPL SPI support
Signed-off-by: Tom Rini <trini@ti.com>
2013-08-28 11:44:58 -04:00
Tom Rini a7a0640085 TI:am335x: Better comment and organize the networking related options
While in here, drop CONFIG_BOOTP_DEFAULT as it is unused in the code.

Signed-off-by: Tom Rini <trini@ti.com>
2013-08-28 11:44:58 -04:00
Tom Rini 8769455861 TI:am33xx: Create common config files for TI ARMv7 platforms, and AM33xx
We create two new files, include/configs/ti_armv7_common.h for all of
the common IP blocks and related features / commands we share in
virtually all of our platforms.  We then create
include/configs/ti_am335x_common.h for everything common to the am335x
SoC leaving just the board specific parts to
include/configs/ti_am335x_common.h.

Signed-off-by: Tom Rini <trini@ti.com>
2013-08-15 18:38:36 -04:00
Tom Rini bc6fff9ac7 am335x_evm: Bring in 'boot_fdt' logic from i.MX
Bring in the 'boot_fdt' environment variable that i.MX boards use to try
and load a device tree when booting.

Signed-off-by: Tom Rini <trini@ti.com>
2013-08-15 18:38:35 -04:00
Tom Rini 4db4076206 am335x_evm: Use default baud rate table
Signed-off-by: Tom Rini <trini@ti.com>
2013-08-15 18:38:35 -04:00
Lokesh Vutla 806d279247 ARM: OMAP: Add CONFIG_OMAP_COMMON
Adding a new CONFIG_OMAP_COMMON which is included by all boards
that needs to build cpu/armv7/omap-common folder.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
2013-08-15 08:51:10 -04:00
Justin Waters 8c6ede1fd2 am335x_evm: Add support for eMMC environment
Some boards, such as the BeagleBone Black, have an eMMC chip intstead
of NAND. We can use the eMMC boot partition to store the environment,
since it isn't used for anything else. This allows us to have a
configurable environment on those boards.

Signed-off-by: Justin Waters <justin.waters@timesys.com>
2013-07-30 09:21:42 -04:00
Justin Waters a3aa70afb7 am335x_evm: Rework bootcmd to handle two MMC devs
The BeagleBone Black can boot from either the MMC card
or eMMC chip on board. We should try both interfaces.

This modification also allows a graceful fallback if
a device exists but boot images are not present on it.

Changes for v2:

* Fix boot partition - it should always show up as mmcblk0p2
* Fix missing FDT load

Signed-off-by: Justin Waters <justin.waters@timesys.com>
2013-07-30 09:21:42 -04:00
Justin Waters 2c7c03bed1 am335x_evm: Add command line editing
Many modern U-Boot ports enable command line editing and
a history buffer. The am335x_evm configuration is fairly
comprehensive as it is, so a few extra kb should not be
noticable, and it adds a very convenient feature.

Signed-off-by: Justin Waters <justin.waters@timesys.com>
2013-07-30 09:21:42 -04:00
Justin Waters 317fab2df2 am335x_evm: Make NAND support modular
Give the user the ability to disable NAND support by defining
CONFIG_NO_NAND. This will allow custom hardware to easily support
this configuration.

Signed-off-by: Justin Waters <justin.waters@timesys.com>
[trini: Make apply on top of other series]
Signed-off-by: Tom Rini <trini@ti.com>
2013-07-30 09:21:42 -04:00
Steve Kipisz c5c7a7c32d am335x_evm: Add support to boot from NOR.
NOR requires that s_init be within the first 4KiB of the image so that
we can perform the rest of the required pinmuxing to talk with the rest
of NOR that we are found on.  When NOR_BOOT is set we save our
environment in NOR at 512KiB and a redundant copy at 768KiB.  We avoid
using SPL for this case and u-boot.bin is written directly to the start
of NOR.

We enclose the DMM-related parts of arch/arm/cpu/armv7/am33xx/emif4.c
with TI81xx checks as at this time U-Boot does not discard unused
sections in the main build and this code relies on functions specific to
(and only provided in) ti81xx-related code.

Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
Signed-off-by: Steve Kipisz <s-kipisz2@ti.com>
Signed-off-by: Tom Rini <trini@ti.com>
2013-07-30 09:21:41 -04:00
Steve Kipisz cd8845d7a4 am335x_evm: Add support for the NOR module on the memory cape
This patch adds support for the NOR module that attaches
to the memory cape for a Beaglebone board. This does not
add booting support; only support so that you can boot from
SD/MMC and see the NOR module so that it can be programmed.

Signed-off-by: Steve Kipisz <s-kipisz2@ti.com>
[trini: Clean up config changes slightly]
Signed-off-by: Tom Rini <trini@ti.com>
2013-07-30 09:21:41 -04:00
Tom Rini 6454028abb am335x_evm: Update SPI_BOOT support, add MTDPARTS info
- Style cleanup (# define -> #define)
- Due to ROM issues, redudant loading isn't feasible, so drop.
- Given extra space, increase max size of U-Boot to 512KiB
- Correct env size to match usage (we had not re-defined ENV_SIZE).
- Given extra space, keep env size as 128KiB, add redundant environment.

Reviewed-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Tom Rini <trini@ti.com>
2013-07-30 09:21:41 -04:00
Tom Rini 989bd7a8cb am335x_evm: Drop useless CONFIG_ENV_IS_NOWHERE
We always set a CONFIG_ENV_IS_...somewhere... so drop the initial define
of NOWHERE.

Reviewed-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Tom Rini <trini@ti.com>
2013-07-30 09:21:41 -04:00
Tom Rini a7d39afbb0 am335x_evm: Correct CONFIG_CMD_SPL_WRITE_SIZE
We use CONFIG_CMD_SPL_WRITE_SIZE when reading/writing the args portion
of falcon mode to NAND.  Previously it was half the size of the
eraseblock which is too small, increase to eraseblock size.

Signed-off-by: Tom Rini <trini@ti.com>
2013-07-26 16:39:10 -04:00
Tom Rini 3afd8e0828 am335x_evm: Update eMMC falcon mode locations
The previous location used for the "args" portion of falcon mode was too
small to allow for a device tree to be saved there, so move the location
slightly and increase the size.  In addition, our previous kernel
location was part of the area we set aside for U-Boot itself, so move it
up a bit higher.

Signed-off-by: Tom Rini <trini@ti.com>
Reviewed-by: Peter Korsgaard <jacmet@sunsite.dk>
2013-07-26 16:39:10 -04:00
Tom Rini d78959937f am335x_evm: Correct DFU ALT settings for falcon mode
Now that we have falcon mode enabled, the partiton numbers for NAND have
changed, and we need to list entries for updating these parts of the
system.  While adding falcon mode entires for eMMC (raw), we round up
the limit on U-Boot for ease of math later.

Signed-off-by: Tom Rini <trini@ti.com>
Reviewed-by: Peter Korsgaard <jacmet@sunsite.dk>
2013-07-26 16:39:10 -04:00
Tom Rini 20cb5fbec6 am335x_evm: Add missing ';' in findfdt
In a714321 we add a check at the end of findfdt to make sure we have
updated it from undefined and if not, warn the user.  This however
forgot a ';' on the end of the previous last test.

Signed-off-by: Tom Rini <trini@ti.com>
2013-06-27 09:55:39 -04:00
Tom Rini 348e47f766 Merge branch 'master' of git://git.denx.de/u-boot-arm 2013-06-22 07:38:12 -04:00
Ying Zhang ba1bee43ec common/Makefile: Add new symbol CONFIG_SPL_ENV_SUPPORT for environment in SPL
There will need the environment in SPL for reasons other than network
support (in particular, hwconfig contains info for how to set up DDR).

Add a new symbol CONFIG_SPL_ENV_SUPPORT to replace CONFIG_SPL_NET_SUPPORT
for environment in common/Makefile.

Signed-off-by: Ying Zhang <b40530@freescale.com>
Reviewed-by: Tom Rini <trini@ti.com>
Signed-off-by: Andy Fleming <afleming@freescale.com>
2013-06-20 17:08:51 -05:00
Dan Murphy a71432151f arm: omap: Add check for fdtfile in the findfdt macro
In the omap4, omap5 and am335x common files add a check to ensure that the fdtfile is
defined after the findfdt macro has run.  If the file is not defined then warn the user that the
dtb file is not defined.

Signed-off-by: Dan Murphy <dmurphy@ti.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-06-18 10:43:29 -04:00
Peter Korsgaard 12d7a47420 am335x: enable falcon boot mode for mmc (raw and fat) and nand
Jump into full u-boot mode if a 'c' character is received on the uart.

We need to adjust the spl bss/malloc area to not overlap with the
loadaddr of the kernel (sdram + 32k), so move it past u-boot instead.

For raw mmc, we store the kernel parameter area in the free space after
the MBR (if used). For nand, we use the last sector of the partition
reserved for u-boot.

This also enables the spl command in the full u-boot so the kernel
parameter area snapshot can be created.

Signed-off-by: Peter Korsgaard <peter.korsgaard@barco.com>
2013-06-07 14:17:01 -04:00
Tom Rini edfcf85a0a am33xx/omap4+: Move SRAM_SCRATCH_SPACE_ADDR to <asm/arch/omap.h>
The location of valid scratch space is dependent on SoC, so move that
there.  On OMAP4+ we continue to use SRAM_SCRATCH_SPACE_ADDR.  On
am33xx/ti814x we want to use what the ROM defines as "public stack"
which is the area after our defined download image space.  Correct the
comment about and location of CONFIG_SPL_TEXT_BASE.

Signed-off-by: Tom Rini <trini@ti.com>
2013-06-06 08:57:45 -04:00
Tom Rini 320d9746d3 am33xx: Correct NON_SECURE_SRAM_START/END
Prior to Sricharan's cleanup of the boot parameter saving code, we
did not make use of NON_SECURE_SRAM_START on am33xx, so it wasn't a
problem that the address was pointing to the middle of our running SPL.
Correct to point to the base location of the download image area.
Increase CONFIG_SPL_TEXT_BASE to account for this scratch area being
used.  As part of correcting these tests, make use of the fact that
we've always been placing our stack outside of the download image area
(which is fine, once the downloaded image is run, ROM is gone) so
correct the max size test to be the ROM defined top of the download area
to where we link/load at.

Signed-off-by: Tom Rini <trini@ti.com>

---
Changes in v2:
- Fix typo noted by Peter Korsgaard
2013-06-04 16:32:31 -04:00
SRICHARAN R 47c6ea076e ARM: OMAP: Add arch_cpu_init function
The boot parameters passed from SPL to UBOOT
must be saved as a part of uboot's gd data
as early as possible, before we will inadvertently
overwrite it. So adding a arch_cpu_init for the required
Socs to save it.

Signed-off-by: Sricharan R <r.sricharan@ti.com>
[trini: Add igep0033 hunk]
Signed-off-by: Tom Rini <trini@ti.com>
2013-05-10 08:25:56 -04:00
SRICHARAN R 4a0eb75752 ARM: OMAP: Cleanup boot parameters usage
The boot parameters are read from individual variables
assigned for each of them. This been corrected and now
they are stored as a part of the global data 'gd'
structure. So read them from 'gd' instead.

Signed-off-by: Sricharan R <r.sricharan@ti.com>
[trini: Add igep0033 hunk]
Signed-off-by: Tom Rini <trini@ti.com>
2013-05-10 08:25:56 -04:00
Mark Jackson 15191c91a2 Remove duplicate / unused #defines on AM335x boards
As part of a review of a recent patch to add a new AM335x board, Tom
found several duplicate and/or unused #defines.

This patch simply removes them.

The two affected configs have been recompiled to check nothing was
broken (from a compilation point of view !!)

Reported-by: Tom Rini <trini@ti.com>
Signed-off-by: Mark Jackson <mpfj-list@mimc.co.uk>
2013-05-10 08:25:55 -04:00
Albert ARIBAUD 1812201997 Merge branch 'u-boot/master' into 'u-boot-arm/master'
Conflicts:
	drivers/video/exynos_fb.c
2013-04-12 22:07:57 +02:00
Pantelis Antoniou ef4e9fc6aa am335x_evm: Enable DFU for NAND and MMC, provide example alt_infos
- Add CONFIG_DFU_NAND, CONFIG_DFU_MMC
- Set dfu_alt_info_nand, dfu_alt_info_emmc and dfu_alt_info_mmc to show
  working examples for those cases.
- Increase CONFIG_SYS_MAXARGS due to hush parsing bugs that would
  otherwise disallow 'setenv dfu_alt_info ${dfu_alt_info_nand}'.
- Enable CONFIG_FAT_WRITE to allow updating on MMC

Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
Signed-off-by: Tom Rini <trini@ti.com>
2013-04-10 15:22:24 +02:00
Tom Rini af5666c885 am335x_evm: Add CONFIG_CMD_MTDPARTS and relevant defaults
Signed-off-by: Tom Rini <trini@ti.com>
2013-04-10 15:22:24 +02:00
Pantelis Antoniou 559eae1cb6 am335x_evm: Define CONFIG_SYS_CACHELINE_SIZE
drivers/usb/gadget/composite.c requires that this is defined early.

Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
Signed-off-by: Tom Rini <trini@ti.com>
Acked-by: Tom Rini <trini@ti.com>
2013-04-10 15:22:24 +02:00
Bin Liu 4de602f2b0 musb: am335x: disable bulk split-combine feature
On TI AM335x devices, MUSB has bulk split/combine feature enabled
in the ConfigData register, but the current MUSB driver does not
support it yet. Therefore, disable the feature for now, until the
driver adds the support.

One usecase which is broken because of this feature is that Ether
gadget stops working in Fullspeed mode (by un-defining
CONFIG_USB_GADGET_DUALSPEED)

After desabled this feature, MUSB driver send packets in proper size
(no more than 64 bytes) in Fullspeed mode.

This has been validated with Ether gadget in Fullspeed mode on AM335x
EVM.

Signed-off-by: Bin Liu <b-liu@ti.com>
2013-04-08 11:29:04 -04:00
Tom Rini 98f92001b3 am33xx: Add required includes to some omap/am33xx code
- In arch/arm/cpu/armv7/omap-common/timer.c,
  drivers/mtd/nand/omap_gpmc.c and drivers/net/cpsw.c add #include files
  that the driver needs but had been relying on <config.h> to bring in.
- In arch/arm/cpu/armv7/omap-common/lowlevel_init.S add <config.h>
- In am335x_evm.h and pcm051.h don't globally include
  <asm/arch/hardware.h> and <asm/arch/cpu.h> but just <asm/arch/omap.h>
  as that is the only include which defines things the config uses.

Cc: Lars Poeschel <poeschel@lemonage.de>
Signed-off-by: Tom Rini <trini@ti.com>
2013-03-24 12:49:11 -04:00
Koen Kooi 951d582778 am335x_evm: Add more variables and switch to DT booting.
Make bootcmd run findfdt so that we know what dtb file to load.  Add a
loadfdt command to load this file in.  Make mmcboot pass in ${fdtaddr}
and make the mmc section of bootcmd run loadfdt.

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Tom Rini <trini@ti.com>
Acked-by: Peter Korsgaard <jacmet@sunsite.dk>
2013-03-22 11:02:31 -04:00
Koen Kooi 73a27a84e5 am335x_evm: Enable CMD_EXT4 and CMD_FS_GENERIC, add bootpart to env
The kernel is loaded from some form of ext[234] or FAT, depending on the
distribution used.  We add a bootpart variable to the environment so
that we can load from the correct mmc partition as well.  We leave
CONFIG_CMD_EXT2 for existing scripts that use ext2load.

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Tom Rini <trini@ti.com>
Acked-by: Peter Korsgaard <jacmet@sunsite.dk>
2013-03-22 10:58:04 -04:00
Koen Kooi 2077590644 am335x_evm: add support for BeagleBone Black DT name
Cc: Matt Porter <mporter@ti.com>
Cc: Nishanth Menon <nm@ti.com>
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Tom Rini <trini@ti.com>
Acked-by: Matt Porter <mporter@ti.com>
Acked-by: Peter Korsgaard <jacmet@sunsite.dk>
Acked-by: Nishanth Menon <nm@ti.com>
2013-03-22 10:57:00 -04:00
Albert ARIBAUD 65cdd6430e Remove linker lists (LGAs) from SPL linker scripts
Many SPL linker scripts needlessly include linker lists (aka LGAs).
Remove them whenever possible; keep it only in the seven am335x_evm
variants (am335x_evm, am335x_evm_uart[1-5], am335x_evm_spiboot),
where there is actual content in output section .u_boot_list.

This commit keeps all u-boot.bin and u-boot-spl.bin in ARM targets
byte-identical.

Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
2013-03-12 23:28:29 +01:00
Tom Rini d446c90383 am335x_evm: Enable CONFIG_CMD_BOOTZ
With v3.9 and later of the Linux Kernel defaulting to multi-platform
images with omap2plus_defconfig, uImage isn't builtable anymore by
default.  Add CONFIG_CMD_BOOTZ so that we can still boot something the
kernel spits out.

Signed-off-by: Tom Rini <trini@ti.com>
Acked-by: Peter Korsgaard <jacmet@sunsite.dk>
2013-03-11 11:06:08 -04:00
Tom Rini 98bc1228c8 am335x_evm: Add am335x_evm_usbspl build target
We add USB (RNDIS gadget) SPL support as a separate target.  We need to
pull out YMODEM support in order to be a small enough target binary.

Signed-off-by: Tom Rini <trini@ti.com>
2013-03-08 16:41:12 -05:00