Commit Graph

1052 Commits

Author SHA1 Message Date
Bartlomiej Sieka fbc87dc054 FIT: output image load address for type 'firmware', fix message while there
Now that the auto-update feature uses the 'firmware' type for updates, it is
useful to inspect the load address of such images.

Signed-off-by: Bartlomiej Sieka <tur@semihalf.com>
2008-10-18 21:54:00 +02:00
Bartlomiej Sieka 4bae90904b Automatic software update from TFTP server
The auto-update feature allows to automatically download software updates
from a TFTP server and store them in Flash memory during boot. Updates are
contained in a FIT file and protected with SHA-1 checksum.

More detailed description can be found in doc/README.update.

Signed-off-by: Rafal Czubak <rcz@semihalf.com>
Signed-off-by: Bartlomiej Sieka <tur@semihalf.com>
2008-10-18 21:54:00 +02:00
Bartlomiej Sieka 3f0cf51dab flash: factor out adjusting of Flash address to the end of sector
The upcoming automatic update feature needs the ability to adjust an
address within Flash to the end of its respective sector. Factor out
this functionality to a new function flash_sect_roundb().

Signed-off-by: Rafal Czubak <rcz@semihalf.com>
Signed-off-by: Bartlomiej Sieka <tur@semihalf.com>
Signed-off-by: Stefan Roese <sr@denx.de>
2008-10-18 21:54:00 +02:00
richardretanubun c68a05feeb Adds two more ethernet interface to 83xx
Added as a convenience for other platforms that uses MPC8360 (has 8 UCC).
Six eth interface is chosen because the platform I am using combines
UCC1&2 and UCC3&4 as 1000 Eth and the other four UCCs as 10/100 Eth.

Signed-off-by: Richard Retanubun <RichardRetanubun@RugggedCom.com>
Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
2008-10-18 21:54:00 +02:00
Peter Tyser 9bc2e4eee3 cmd_i2c: Fix help for CONFIG_I2C_CMD_TREE && !CONFIG_I2C_MULTI_BUS
Original code displayed:
 => help i2c
 i2c i2c speed [speed] - show or set I2C bus speed
 i2c md chip address[.0, .1, .2] [# of objects] - read from I2C device
 ...

Signed-off-by: Peter Tyser <ptyser@xes-inc.com>
2008-10-14 22:27:04 +02:00
Mike Frysinger c46980f6d2 cmd_spi: remove broken signed casting for display
Since we're working with unsigned data, you can't apply a signed pointer
cast and then attempt to print the result.  Otherwise you get wrong output
when the sign bit is set like "0xFF" incorrectly extended to "0xFFFFFFFF".

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2008-10-14 14:19:34 +02:00
Mike Frysinger d5fd0b4921 strings cmd: drop old CONFIG_CFG_STRINGS define
We don't need CONFIG_CFG_STRINGS anymore now that we have the define
CONFIG_CMD_STRINGS and Makefile control.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2008-10-14 14:17:20 +02:00
Luigi 'Comio' Mantellini d977a57356 Fix lzma uncompress call (image_start wrongly used instead image_len)
Signed-off-by: Luigi 'Comio' Mantellini <luigi.mantellini@idf-hit.com>
2008-10-13 14:46:15 +02:00
Heiko Schocher 56844a22b7 powerpc: Fix bootm to boot up again with a Ramdisk
Commit 2a1a2cb6 didnt remove the dummy mem reservation in fdt_chosen,
and this stopped Linux from booting with a Ramdisk. This patch fixes
this, by deleting the useless dummy mem reservation.

When booting with a Ramdisk, a fix offset FDT_RAMDISK_OVERHEAD is now
added to of_size, so we dont need anymore a dummy mem reservation.

I measured the value of FDT_RAMDISK_OVERHEAD on a MPC8270 based
system (=0x44 bytes) and rounded it up to 0x80).

Signed-off-by: Heiko Schocher <hs@denx.de>
Acked-by: Kumar Gala <galak@kernel.crashing.org>
2008-09-13 02:03:38 +02:00
Luigi 'Comio' Mantellini fc9c1727b5 Add support for LZMA uncompression algorithm.
Signed-off-by: Luigi 'Comio' Mantellini <luigi.mantellini@idf-hit.com>
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-13 01:59:07 +02:00
Jean-Christophe PLAGNIOL-VILLARD 0e8d158664 rename CFG_ENV macros to CONFIG_ENV
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:06 +02:00
Jean-Christophe PLAGNIOL-VILLARD 1ede78710c nvedit: rename error comment to CONFIG_ENV_IS_IN_
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:05 +02:00
Jean-Christophe PLAGNIOL-VILLARD b64b775e75 cmd_mem: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:05 +02:00
Jean-Christophe PLAGNIOL-VILLARD 8a40fb148e move cmd_get_data_size to command.c
add CMD_DATA_SIZE macro to enable it

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:05 +02:00
Jean-Christophe PLAGNIOL-VILLARD 507641d249 env_flash: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:04 +02:00
Jean-Christophe PLAGNIOL-VILLARD 5a1aceb068 rename CFG_ENV_IS_IN_FLASH in CONFIG_ENV_IS_IN_FLASH
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:04 +02:00
Jean-Christophe PLAGNIOL-VILLARD 0cf4fd3cf8 rename environment.c in env_embedded.c to reflect is functionality
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:01 +02:00
Jean-Christophe PLAGNIOL-VILLARD c0878af6e3 env_nowhere: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:01 +02:00
Jean-Christophe PLAGNIOL-VILLARD 93f6d72544 rename CFG_ENV_IS_NOWHERE in CONFIG_ENV_IS_NOWHERE
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:00 +02:00
Jean-Christophe PLAGNIOL-VILLARD 2556ef7811 env_sf: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:00 +02:00
Jean-Christophe PLAGNIOL-VILLARD 0b5099a841 rename CFG_ENV_IS_IN_SPI_FLASH in CONFIG_ENV_IS_IN_SPI_FLASH
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:00 +02:00
Jean-Christophe PLAGNIOL-VILLARD 55c5f49910 env_onenand: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:48:00 +02:00
Jean-Christophe PLAGNIOL-VILLARD 9656138ff1 rename CFG_ENV_IS_IN_ONENAND in CONFIG_ENV_IS_IN_ONENAND
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:59 +02:00
Jean-Christophe PLAGNIOL-VILLARD 957a0e6957 env_nvram: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:59 +02:00
Jean-Christophe PLAGNIOL-VILLARD 9314cee691 rename CFG_ENV_IS_IN_NVRAM in CONFIG_ENV_IS_IN_NVRAM
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:59 +02:00
Jean-Christophe PLAGNIOL-VILLARD 06f6135439 env_nand: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:59 +02:00
Jean-Christophe PLAGNIOL-VILLARD 51bfee1920 rename CFG_ENV_IS_IN_NAND in CONFIG_ENV_IS_IN_NAND
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:58 +02:00
Jean-Christophe PLAGNIOL-VILLARD d8cc04d0ac env_dataflash: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:58 +02:00
Jean-Christophe PLAGNIOL-VILLARD 057c849c45 rename CFG_ENV_IS_IN_DATAFLASH in CONFIG_ENV_IS_IN_DATAFLASH
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:58 +02:00
Jean-Christophe PLAGNIOL-VILLARD d1034bc8db cmd_eeprom: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 22:47:52 +02:00
Jean-Christophe PLAGNIOL-VILLARD bf5a7710ec env_eeprom: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 21:09:38 +02:00
Jean-Christophe PLAGNIOL-VILLARD bb1f8b4f8b rename CFG_ENV_IS_IN_EEPROM in CONFIG_ENV_IS_IN_EEPROM
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 21:09:38 +02:00
Jean-Christophe PLAGNIOL-VILLARD 32628c5008 cmd_mac: Move conditional compilation to Makefile
finish remaning CFG_ID_EEPROM in CONFIG_ID_EEPROM
start in commit ad8f8687b7

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 21:09:37 +02:00
Jean-Christophe PLAGNIOL-VILLARD e5648acab1 cmd_fdc: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 21:09:37 +02:00
Jean-Christophe PLAGNIOL-VILLARD 2d02d91d53 common/Makefile: add core command section
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 21:09:37 +02:00
Jean-Christophe PLAGNIOL-VILLARD 0d92d4a699 cmd_vfd: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-10 21:09:37 +02:00
Petri Lehtinen 3591293509 autoscr: Fix one-character lines and non-newline terminated scripts
When not using hush, the autoscr command now executes lines that are
only one character long. It also runs the last line of scripts even if
it does not end in a newline.

Signed-off-by: Petri Lehtinen <petri.lehtinen@inoi.fi>
2008-09-10 11:09:39 +02:00
Wolfgang Denk f6808c48a5 Merge branch 'master' of git://git.denx.de/u-boot-mpc85xx 2008-09-10 11:07:35 +02:00
Andrew Klossner 5251469943 Fix printf errors under -DDEBUG
Fix printf format-string/arg mismatches under -DDEBUG.

These warnings occur with DEBUG defined for a platform using
cpu/mpc85xx.  Users of other architectures can unearth similar
problems by adding the line "CFLAGS += -DDEBUG=1" in config.mk right
after "CFLAGS += $(call cc-option,-fno-stack-protector)".

Signed-off-by: Andrew Klossner <andrew@cesa.opbu.xerox.com>
Signed-off-by: Andy Fleming <afleming@freescale.com>
2008-09-09 17:02:41 -05:00
Jean-Christophe PLAGNIOL-VILLARD 54b4ab3c96 bootm_load_os: fix load_end debug message
print load_end value not pointer

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-09 23:38:15 +02:00
Jean-Christophe PLAGNIOL-VILLARD 1d9af0be76 bootm: enable fdt support only on ppc, m68k and sparc
...as done in image.c

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-09-09 23:37:50 +02:00
Markus Heidelberg 748b5274e7 common/cmd_mem.c: remove nested #if defined(CONFIG_CMD_MEMORY)
Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
2008-09-09 23:35:53 +02:00
Ryan CHEN 3b20fd83c7 Correct drv_usb_kbd_init function
The patch is that check if usb_get_dev_index() function return valid
pointer. If valid, continue. Otherwise return -1.

Signed-off-by: Ryan Chen <ryan.chen@st.com>
Acked-by: Markus Klotzbuecher <mk@denx.de>
2008-09-09 17:02:59 +02:00
Remy Bohmer eba1f2fc75 Make usb-stop() safe to call multiple times in a row.
A recent commit (936897d4d1)
enabled the usb_stop() command in common/cmd_bootm.c which was
not enabled for some time, because no board did actually set the
CFG_CMD_USB flag. So, now the usb_stop() is executed before
loading the linux kernel.

However, the usb_ohci driver hangs up (at least on AT91SAM) if the
driver is stopped twice (e.g. the peripheral clock is stopped on AT91).
If some other piece of code calls usb_stop() before the bootm command,
this command will hangup the system during boot.
(usb start and stop is typically used while booting from usb memory stick)

But, stopping the usb stack twice is useless anyway, and a flag already
existed that kept track on the usb_init()/usb_stop() calls.
So, we now check if the usb stack is really started before we stop it.

This problem is now fixed in both the upper as low-level layer.

Signed-off-by: Remy Bohmer <linux@bohmer.net>
Acked-by: Markus Klotzbuecher <mk@denx.de>
2008-09-09 16:59:25 +02:00
Wolfgang Denk 2c8ccf2728 Makefile: fix bug introduced by commit 47ffd6c2 2008-09-09 16:55:47 +02:00
Bartlomiej Sieka a4f243452c FIT: make iminfo check hashes of all images in FIT, return 1 on failed check
Signed-off-by: Bartlomiej Sieka <tur@semihalf.com>
2008-09-09 15:58:57 +02:00
Bartlomiej Sieka 919f550dc1 FIT: add ability to check hashes of all images in FIT, improve output
- add function fit_all_image_check_hashes() that verifies if all
  hashes of all images in the FIT are valid
- improve output of fit_image_check_hashes() when the hash check fails

Signed-off-by: Bartlomiej Sieka <tur@semihalf.com>
2008-09-09 15:58:11 +02:00
Peter Tyser f5ed9e3908 Add support for booting of INTEGRITY operating system uImages
Signed-off-by: Peter Tyser <ptyser@xes-inc.com>
2008-09-09 15:54:10 +02:00
Kumar Gala 9ba2e2c819 Remove support for booting ARTOS images
Pantelis Antoniou stated:
	AFAIK, it is still used but the products using PPC are long gone.
	Nuke it plz (from orbit).

So remove it since it cleans up a usage of env_get_char outside of
the environment code.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-09-09 15:52:35 +02:00
Wolfgang Denk 47ffd6c2fc Makefile: compile and link each module just once
Several source files need to be compiled and linked when one or more
config options are selected. To allow for easy selection in the
Makefiles yet to avoild multiple compilation (which costs build time)
and especially multiple linking (which causes errors), we use
"COBJS = $(sort COBJS-y)" which eliminates duplicates.

By courtesy of Detlev Zundel who suggested this approach.

Signed-off-by: Wolfgang Denk <wd@denx.de>
2008-09-09 15:45:18 +02:00