summaryrefslogtreecommitdiffstats
path: root/commands
Commit message (Collapse)AuthorAgeFilesLines
* menu: fix non command management supportJean-Christophe PLAGNIOL-VILLARD2012-04-231-8/+9
| | | | | | the auto select is always available Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* Merge branch 'binfmt' of git://git.jcrosoft.org/barebox into nextSascha Hauer2012-04-181-0/+12
|\
| * bootm: add uimage binfmt supportJean-Christophe PLAGNIOL-VILLARD2012-04-181-0/+12
| | | | | | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* | bootm: Align oftreeSteffen Trumtrar2012-04-181-6/+10
| | | | | | | | | | | | | | | | | | | | Arm needs 64-Bit alignment of the oftree as mentioned in the documentation Documentation/arm/Booting. Other architectures may need a bigger alignment so align to 4K. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | bootm: Fix check for ret-valueSteffen Trumtrar2012-04-181-4/+3
|/ | | | | | | | The intention of this code was to check the return value of fdt_open_into. Fix this. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'master' into nextSascha Hauer2012-04-171-1/+0
|\
| * addpart: remove duplicate line in help textSascha Hauer2012-04-141-1/+0
| | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | automount: optionally make directorySascha Hauer2012-04-151-2/+11
| | | | | | | | | | | | Add an option to create the mount path to make using this command easier. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | automount: fix argument parsingSascha Hauer2012-04-151-2/+2
| | | | | | | | | | | | With getopt we have to use argv[optind] instead of hardcoded argv[0] Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | bootm: be more informative with oftreesSascha Hauer2012-04-141-4/+6
| | | | | | | | | | | | | | | | - print error message when the specified oftree cannot be opened - move verbose info to top of function so that the information is printed before something else fails. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | arm: add Android boot image supportJean-Christophe PLAGNIOL-VILLARD2012-04-131-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Android Image contains 3 components and params - kernel - initrd - second stage (optional) - tags addr - bootargs In fast boot the initrd is mandatory, in barebox we are less restrictive use the initrd only if present add to env params: aimage_noverwrite_bootargs Disable overwrite of the bootargs with the one present in aimage aimage_noverwrite_tags Disable overwrite of the tags addr with the one present in aimage Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Cc: Magnus Damm <magnus.damm@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Remove EXPERIMENTAL flag from loady.Uwe Hermann2012-04-101-2/+1
|/ | | | | | | | | | | | | From bd6c5c884337ae2d4ef41d85d59c2d5ec525f8a5 Mon Sep 17 00:00:00 2001 From: Uwe Hermann <uwe@hermann-uwe.de> Date: Fri, 6 Apr 2012 17:30:01 +0200 The loady command seems to work just fine (tested on an S3C2440 target). Also, mark it as TRISTATE like loadb and loads. Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* partition command: optionally do not automatically prepend the device nameSascha Hauer2012-03-181-8/+25
| | | | | | | | | | | | | | | | | | | | | We used to automatically prepend the device name before the partition name. So when we added a partition named 'barebox' to a device named 'nor0' the partition was named 'nor0.barebox'. The Kernel can mount its rootfs based on the mtd name, for example with root=mtd:root. If for example we have multiple mtd devices (nor and nand) 'root' is a bad name for the partition, it should better be 'nor0.root' This patch adds an additional commandline switch to addpart to optionally skip the automatic device name adding. This makes it possible to define our mtd partitions like this: nor_parts="512k(nor0.barebox)ro,128k(nor0.bareboxenv),2M(nor0.kernel),-(nor0.root)" This way the barebox partition names stay the same, but we can now pass the exact name to the kernel (root=mtd:nor0.root). Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* usb command: by default scan only once for USB devicesSascha Hauer2012-03-181-4/+22
| | | | | | | | | | We normally do not expect USB devices to be hotplugged. Instead of rescanning each time the usb command is called, scan only once. This makes the usb command safe for being called multiple times without making already registered USB devices reinitialized. To really scan multiple times a '-f' option is introduced. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Add automount supportSascha Hauer2012-03-183-0/+77
| | | | | | | | | | | | | | This patch adds an automount command which makes it possible to execute a script when a certain directory is first accessed. It's the commands responsibility to make this directory available (bringing devices up and mounting it). This results in automount support which makes sure that from the shell every file can be accessed without having to care for device bringup. Bringing up devices may be expensive (USB, dhcp). The automount support makes it easy for the environment to bringup devices when they are actually needed. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: drop struct mtab_entrySascha Hauer2012-03-171-5/+5
| | | | | | | | | | every struct fs_device_d contains a struct mtab_entry, so they have a 1:1 relationship. Instead of having to use container_of to get from a struct mtab_entry to a struct fs_device_d we can better embed the members of struct mtab_entry into struct fs_device_d directly. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'work/thumb2' into nextSascha Hauer2012-03-061-1/+5
|\
| * ARM: Allow to compile in thumb-2 modeSascha Hauer2012-03-061-1/+5
| | | | | | | | | | | | | | | | | | This shrinks the resulting binary size by ~25%. Exceptions are still handled in arm mode, so we have to explicitely put .arm directives into the exception code. Thumb-2 mode has been tested on i.MX51 Babbage board. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | commands: remove struct command pointer from commandsSascha Hauer2012-02-2765-86/+85
|/ | | | | | This is unused in all commands and thus can be removed. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* cp: fix memory leakSascha Hauer2012-02-271-1/+1
| | | | | | | dst is an allocated string, we have to free it also when copy_file fails. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'pu/device-cleanup' into nextSascha Hauer2012-02-171-10/+7
|\
| * fs: Store mtab entries in listSascha Hauer2012-02-171-10/+7
| | | | | | | | | | | | | | To make the code a bit easier to read. Also, do not allow to umount / when something else is mounted. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'master' into nextSascha Hauer2012-02-151-1/+1
|\ \ | |/ |/|
| * uimage: Fix error messageSascha Hauer2012-02-131-1/+1
| | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | dfu: add description how to specify the "description" to the long helpJean-Christophe PLAGNIOL-VILLARD2012-02-141-0/+4
|/ | | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* CMD_UNCOMPRESS: select UNCOMPRESSJean-Christophe PLAGNIOL-VILLARD2012-01-161-0/+1
| | | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'pu/jean-codesize' into nextSascha Hauer2012-01-131-0/+3
|\
| * filetype: add config to disable itJean-Christophe PLAGNIOL-VILLARD2012-01-111-0/+1
| | | | | | | | | | | | remove 160 bytes Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
| * uncompress: add config to disable itJean-Christophe PLAGNIOL-VILLARD2012-01-111-0/+1
| | | | | | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
| * banner: add config to disable itJean-Christophe PLAGNIOL-VILLARD2012-01-111-0/+1
| | | | | | | | | | | | this will allow to save 144 bytes Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* | nandtest: add missing select.Alexander Aring2012-01-061-0/+1
| | | | | | | | | | | | | | Add select PARTITION_NEED_MTD in nandtest. Signed-off-by: Alexander Aring <a.aring@phytec.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | nandtest: fix typoAlexander Aring2012-01-061-1/+1
|/ | | | | | | Fix typo nand -> nandtest. Signed-off-by: Alexander Aring <a.aring@phytec.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* nandtest: add nandtest commandAlexander Aring2012-01-043-0/+372
| | | | | | | | Add nandtest command to test nand devices and display ecc stats at the end of test. Signed-off-by: Alexander Aring <a.aring@phytec.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* serial gadget: enable/disable on requestEric Bénard2012-01-042-0/+109
| | | | | | | | | | | | | | - add a usbserial command to enable/disable the serial gadget - allow dfu and usbserial to cohexist in the same barebox - add a timeout in u_serial so that we don't get locked if the user enable usbserial from a UART console but doesn't consume the data on the usbserial port created on the PC - remove debug or verbose printf - tested on i.MX25 & i.MX35 & usb-a926x Signed-off-by: Eric Bénard <eric@eukrea.com> Tested-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* command: flash: remove broken filename checkWolfram Sang2011-12-221-10/+0
| | | | | | | | | It makes no sense to check the filename pointer here, because a) we have already been using it and b) argc has been tested against 1 already, so argv[1] should not be NULL. So, drop the checks. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* commands/ls: add to use sorted-insertAlexander Aring2011-12-211-2/+2
| | | | | | | Added sorted insert to ls command. Signed-off-by: Alexander Aring <a.aring@phytec.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* bootm: Add missing Kconfig dependencySascha Hauer2011-12-171-0/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'work/uimage' into nextSascha Hauer2011-12-175-200/+467
|\ | | | | | | | | | | | | | | | | Conflicts: arch/ppc/lib/ppclinux.c commands/bootm.c include/boot.h Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * remove now obsolete iminfo commandSascha Hauer2011-12-153-78/+0
| | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * add uimage commandSascha Hauer2011-12-153-0/+115
| | | | | | | | | | | | | | | | | | The uimage command superseeds the iminfo command. Unlike the iminfo command the uimage command can also be used to verify the data crc on demand and to extract uImages to files. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * bootm: use new uimage codeSascha Hauer2011-12-152-125/+348
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This switches the bootm code to the new uimage code. Also bootm can now handle other types of images than uImages. Currently the only architecture making use of this is arm which allows to boot zImages, raw images and barebox images. I intended to make a more bisectable series from this but I failed becuase there are many dependencies and no matter how I tried the patches grew bigger and and bigger. So I decided to put this all in a single patch. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ppc: switch to libfdt based oftree implementationSascha Hauer2011-12-141-0/+5
| | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'pu/ppc-oftree' into nextSascha Hauer2011-12-151-0/+5
|\ \
| * | ppc: switch to libfdt based oftree implementationSascha Hauer2011-12-151-0/+5
| |/ | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'pu/misc' into nextSascha Hauer2011-12-151-1/+0
|\ \
| * | remove unused watchdog headerSascha Hauer2011-12-151-1/+0
| |/ | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'master' into nextSascha Hauer2011-12-151-1/+1
|\| | | | | | | | | | | | | | | | | Conflicts: arch/arm/boards/usb-a926x/init.c arch/arm/mach-pxa/include/mach/clock.h arch/arm/mach-pxa/speed-pxa27x.c Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * time command: Fix needed string lengthSascha Hauer2011-12-081-1/+1
| | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Add missing code from linux_exec commandSascha Hauer2011-12-131-0/+60
|/ | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* bootm: factor out initrd code from option parserSascha Hauer2011-12-071-11/+15
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>