2016-10-12 |
boot: add '-w' parameter to usage help text
...
Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Yegor Yefremov
authored
on 10 Oct 2016
Sascha Hauer
committed
on 12 Oct 2016
|
2016-09-16 |
commands: exit on invalid option
...
Barebox commands should not perform any action and return 0 if an
invalid parameter was given. This might cause undetected unintended
behvaior when calling commands with wrong options, either manually or
from a script.
Signed-off-by: Enrico Jorns <ejo@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Enrico Jorns
authored
on 12 Sep 2016
Sascha Hauer
committed
on 16 Sep 2016
|
2016-07-26 |
boot: Print a message when a boot target string does not lead to a boot target
...
When doing a 'boot friesel net' one expects a message when 'friesel'
does not give any bootable results and thus 'net' is booted. This patch
adds this message.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
boot command: Explicitly complain when boot target list is empty
...
When no targets to boot are found it can happen that the boot command
just returns silently. Explicitly print a message in this case to give
a clue what might went wrong.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
boot: Move code to common/
...
Normally code in commands/ shall only do the option parsing whereas the
functionality shall be in common/ to make the code usable from C aswell.
Do this in the boot code aswell, move it to common/boot.c and add the
function prototypes to include/boot.h
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
boot: Use struct bootentries to pass around data
...
We have a struct bootentries type to collect different boot entries,
so use this to pass around data between functions rather than using
an array of strings. With this we also no longer have to convert a
string to a boot entry multiple times.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
bootentries: Move menu display string allocation to bootentries_alloc()
...
bootentries_alloc() is the place where the struct bootentries container
is allocated, so allocate the menu entry there aswell.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
blspec: separate bootentries from blspec entries
...
This completes the separation of the blspec code from the boot
code. With this the boot code only handles generic boot entries
of type struct bootentry which are embedded into the type
(blspec/bootscript) specific structs.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
bootentries: Add title/description
...
We currently have to special case blspec entries vs. boot scripts
in the common boot code since we want to print different informations
about them. This adds a 'title' and 'description' which can be filled
in with different information by bootscripts and blspec entries and
so we get rid of the special handling.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
blspec: factor out a struct bootentry
...
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
blpec: rename struct lspec -> bootentries
...
The code in common/boot.c collects the different boot entries in
lists of type struct blspec, eventhough many of them may not be
bootloader spec entries but for example boot scripts. This is the first
step of separating the data structures from boot entries and bootloader
spec: As struct blspec is merely a container for collecting boot entries
We simply rename struct blspec to struct bootentries. No functional change.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
include: Move bulk of boot.h to bootm.h
...
The majority of the stuff currently in include/boot.h is about bootm
code implemented common/bootm.c. To be more consistent move it to a
new file include/bootm.h.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jul 2016
|
2016-07-22 |
boot: Call blspec_scan_directory() only on strings containing an absolute path
...
Avoids an unnecessary "Nothing bootable found on..." warning.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 22 Jul 2016
|
blspec: Remove once/default handling
...
This is widely unused and in the way of subsequent cleanups. If you are
indeed using it please complain on the list, we'll find a solution to
add it back in a different way.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 22 Jul 2016
|
2016-06-29 |
boot command: Make verbose/dryrun options work again
...
Fixes: bc94fb3 bootm: Initialize bootm_data defaults in single place
bootm_data_init_defaults() must be called before filling in the values
from the commandline options, otherwise the values will be overwritten
in bootm_data_init_defaults().
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 29 Jun 2016
|
2016-04-15 |
string: Fix (v)asprintf prototypes
...
Our asprintf and vasprintf have different prototypes than the glibc
functions. This causes trouble when we want to share barebox code
with userspace code. Change the prototypes for (v)asprintf to match
the glibc prototypes. Since the current (v)asprintf are convenient
to use change the existing functions to b(v)asprintf.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 15 Apr 2016
|
2016-01-26 |
bootm: Initialize bootm_data defaults in single place
...
Both the bootm and the boot code initialize the struct bootm_data
with defaults from the bootm global variables. Create a common
function for doing this.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 26 Jan 2016
|
2015-08-28 |
boot command: Allow to enable watchdog
...
Enabling the watchdog before booting the kernel is a common usecase.
Add an option to the boot command and also add a global variable for
it to make it configurable easily.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 28 Aug 2015
|
2014-07-01 |
boot: fix typo
...
Signed-off-by: Rolf Evers-Fischer <rolf.evers.fischer@delphi.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Rolf Evers-Fischer
authored
on 30 Jun 2014
Sascha Hauer
committed
on 1 Jul 2014
|
2014-06-19 |
boot: Fix boot -m
...
We have to continue when bootentries_collect succeeds, not when it fails.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 19 Jun 2014
|
2014-05-14 |
commands: harmonize in-barebox documentation
...
This patch does probably too much, but it's hard (and very
cumbersome/time consuming) to break it out. What is does is this:
* each command has one short description, e.g. "list MUX configuration"
* made sure the short descriptions start lowercase
* each command has one usage. That string contains just the
options, e.g. "[-npn]". It's not part of the long help text.
* that is, it doesn't say "[OPTIONS]" anymore, every usable option
is listed by character in this (short) option string (the long
description is in the long help text, as before)
* help texts have been reworked, to make them
- sometimes smaller
- sometimes describe the options better
- more often present themselves in a nicer format
* all long help texts are now created with BUSYBOX_CMD_HELP_
macros, no more 'static const __maybe_unused char cmd_foobar_help[]'
* made sure the long help texts starts uppercase
* because cmdtp->name and cmdtp->opts together provide the new usage,
all "Usage: foobar" texts have been removed from the long help texts
* BUSYBOX_CMD_HELP_TEXT() provides the trailing newline by itself, this
is nicer in the source code
* BUSYBOX_CMD_HELP_OPT() provides the trailing newline by itself
* made sure no line gets longer than 77 characters
* delibertely renamed cmdtp->usage, so that we can get compile-time
errors (e.g. in out-of-tree modules that use register_command()
* the 'help' command can now always emit the usage, even without
compiled long help texts
* 'help -v' gives a list of commands with their short description, this
is similar like the old "help" command before my patchset
* 'help -a' gives out help of all commands
Signed-off-by: Holger Schurig <holgerschurig@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Holger Schurig
authored
on 13 May 2014
Sascha Hauer
committed
on 14 May 2014
|
commands: group 'help' output
...
The old output of "help" was just producing a long list, that usually
scrolled of the screen (even on a X11 terminal). This list is more
compact, and also sorted by groups.
The old output format (plus grouping) is now available with 'help -v'.
Example:
Information commands:
?, devinfo, help, iomem, meminfo, version
Boot commands:
boot, bootm, go, loadb, loads, loadx, loady, saves, uimage
...
Signed-off-by: Holger Schurig <holgerschurig@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Holger Schurig
authored
on 13 May 2014
Sascha Hauer
committed
on 14 May 2014
|
2014-05-13 |
boot: iterate over directories in alphabetical order
...
When iterating over directories in order to find boot scripts do
this alphabetically to get a predictable order. This can be done
with glob() rather than readdir().
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 13 May 2014
|
boot: fix multiple boot sources
...
When there are multiple bootsources barebox should try booting them
until one succeeds. This is broken because we bail out of the iteration
loop with a goto. Remove the goto to fix this.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 13 May 2014
|
2014-03-24 |
blspec: honor default/once entries again
...
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 24 Mar 2014
|
2014-03-19 |
boot command: only create boot entries from scripts
...
When given a directory ignore all files that are not shell scripts.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 19 Mar 2014
|
boot command: honour global.boot.default also for -l and -m
...
The boot command is expected to work on bootsources from the commandline
if given, on global.boot.default otherwise. Fix this behaviour for the
-m and -l options also.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 19 Mar 2014
|
2014-03-07 |
Merge branch 'for-next/nfs'
...
Conflicts:
defaultenv/defaultenv-2-base/bin/ifup
Sascha Hauer
committed
on 7 Mar 2014
|
run_command: remove unused flag parameter
...
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Sascha Hauer
committed
on 7 Mar 2014
|
2014-02-17 |
boot command: Remove redundant assignment
...
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Alexander Shiyan
authored
on 15 Feb 2014
Sascha Hauer
committed
on 17 Feb 2014
|