9
0
Fork 0
Commit Graph

116 Commits

Author SHA1 Message Date
Sascha Hauer 98360be0fe Documentation: remove doxygen documentation
The doxygen documentation is long outdated. Remove it. It will
be replaced with sphinx based documentation later.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2014-06-26 10:09:52 +02:00
Holger Schurig c524f74d5b commands: NET_DHCP -> CMD_DHCP
* this compile option actually turns on a command, so name it
  accordingly
* also move the Kconfig definition into commands/Kconfig, thus
  placing getopt into the "Network commands" section
* while at it, improve Kconfig documention

Signed-off-by: Holger Schurig <holgerschurig@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2014-05-14 10:03:49 +02:00
Holger Schurig 5bd055b660 commands: NET_PING -> CMD_PING
* this compile option actually turns on a command, so name it
  accordingly
* also move the Kconfig definition into commands/Kconfig, thus
  placing getopt into the "Network commands" section
* while at it, improve Kconfig documention

Signed-off-by: Holger Schurig <holgerschurig@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2014-05-14 10:03:48 +02:00
Holger Schurig f1f532084a 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>
2014-05-14 10:03:43 +02:00
Holger Schurig ab23d0bb3f 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>
2014-05-14 07:59:55 +02:00
Sascha Hauer 9bd67f5e61 bootm: introduce bootm_load_os helper
The common bootm code used to load uImage contents to SDRAM
before calling into the handlers if possible. This makes the
handlers complicated since they have to handle many cases. Instead,
introduce a helper to load the os after the handlers have figured
out a good load address.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2014-01-10 11:53:18 +01:00
Sascha Hauer 068bed22a6 Set model and hostname at boardlevel
With multiboard support the compiletime generated BOARDINFO string
gets more and more meaningless. This removes it from Kconfig and
replaces it with a variable that can be set at boardlevel.

Also many boards have a standard setting for the hostname in the
environment. This patch also moves the standard to C code by calling
barebox_set_hostname().

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-08-16 08:40:55 +02:00
Alexander Shiyan 0a9ec16872 blackfin: Remove unneeded assignment
Assignment of function parameter has no effect outside the function.

Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-07-09 08:41:31 +02:00
Sascha Hauer 1d9547773c blackfin: initialize malloc pool before start_barebox()
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-03-14 08:41:27 +01:00
Sascha Hauer 2749fbac48 nor flash: integrate into mtd
CFI Flash is currently handled outside the mtd layer which makes it
a special case. Integrate it into mtd so that we get rid of this
special status.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-02-14 23:37:53 +01:00
Sascha Hauer da5fe0ba47 Merge branch 'for-next/misc' 2013-02-04 15:49:00 +01:00
Sascha Hauer 02c13ee875 blackfin: Use unsigned long for __kernel_size_t
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-01-27 14:24:39 +01:00
Alexander Aring 43afe67390 barebox-data: add barebox-data sections
Add barebox-data section in arm branch to get complete
barebox regions in sdram regions tree.

Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-01-18 11:56:50 +01:00
Alexander Aring 47326f80a9 remap_range: make function 'remap_range' global
Change function remap_range in arm architecture to make it
global accessable. For example command 'memtest' can change
pte flags to enable or disable cache.

Add dummy function for others architectures that doesn't
have mmu or pte support.

Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-01-18 08:28:20 +01:00
Alexander Shiyan 4c20f9af97 Cleanup Kconfig files
This patch provides a global cleanup barebox Kconfig files. This includes
replacing spaces to tabs, formatting in accordance format, removing
extraneous lines and spaces. No functional changes.

Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-12-08 12:22:12 +01:00
Sascha Hauer edf068e9cf Merge branch 'for-next/tftp' 2012-10-03 21:17:39 +02:00
Sascha Hauer b51a11be84 defconfig: Switch all defconfig to new tftp command
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-09-28 16:23:55 +02:00
Sascha Hauer 77322aa896 Treewide: remove address of the Free Software Foundation
The FSF address has changed in the past. Instead of updating it
each time the address changes, just drop it completely treewide.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-09-17 10:57:41 +02:00
Sascha Hauer 40830caf4e Merge branch 'for-next/smc911x' 2012-09-05 12:59:59 +02:00
Sascha Hauer bed1a6ffab Merge branch 'for-next/pbl' 2012-09-05 12:59:29 +02:00
Sascha Hauer e83bd38479 blackfin: Add unaligned support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-09-04 09:08:39 +02:00
Jean-Christophe PLAGNIOL-VILLARD 655dc6b8aa smc911x: add support to pass the shift via platform data
switch ipe337: to it at the same time to do not brake it

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-09-03 09:49:06 +02:00
Sascha Hauer b615445564 Makefile: generate a barebox-flash-image link
Depending on the SoC a barebox.bin, barebox.netx, barebox.s5p, MLO image
is generated. With pbl support there now is an additional
arch/arm/pbl/zbarebox.bin image.

To help the user to determine which image should be flashed to his device,
generate a barebox-flash-image link.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2012-08-12 16:16:44 +02:00
Sascha Hauer dd3c898d06 Merge branch 'for-next/dma-cache-align' 2012-07-02 10:59:22 +02:00
Marc Kleine-Budde ed2180d658 blackfin, mips, openrisc, ppc, sandbox, x86: add generic dma_alloc, dma_free inlines
Some drivers call dma_inv_range() on buffers, on arm these buffers must
be cache line aligned. This patch introduces a generic dma_alloc,
dma_free. Archs can implement in their own functions in "asm/dma.h" and add a:

	#define dma_alloc dma_alloc
	#define dma_free dma_free

On all other archs the generic versions, which translate into xmalloc
and free are used.

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-06-30 12:46:25 +02:00
Sascha Hauer 1a5503118a blackfin: Add missing fls include
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-06-28 13:49:17 +02:00
Sascha Hauer e2e494bc02 blackfin: add __ashrdi3
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-06-28 13:49:16 +02:00
Sascha Hauer 39e450ca1c blackfin: Fix build due to missing __raw_* io accessors
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-06-21 11:56:53 +02:00
Sascha Hauer ee4cab9e58 booting: more flexible Linux bootargs generation
We currently use the environment variable 'bootargs' to get the
Linux bootargs. This patch allows for a more flexible bootargs
generation using global variables. With it the Linux bootargs
are concatenated from multiple variables. This allows to replace
parts of the bootargs string without having to reconstruct it
completely.
With this bootargs can be constructed like:

global linux.bootargs.base="console=ttyS0,115200"
global linux.bootargs.ip="ip=dhcp"
global linux.mtdparts="physmap-flash.0:512K(nor0.barebox),-(root)"

This will then automatically be combined into a kernel bootargs
string during boot.

If the 'linux.bootargs.' variables are all empty the old standard
'bootargs' way will be used.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-05-14 09:16:31 +02:00
Alexander Shiyan 714c20c568 Removed duplicate definition for DEVFS_PARTITION_xxx
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-05-13 21:58:19 +02:00
Sascha Hauer abe4560c8a Use DEVICE_ID_DYNAMIC where applicable
We now have DEVICE_ID_DYNAMIC for dynamic allocation of device ids,
Use it where applicable.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-04-16 09:43:02 +02:00
Sascha Hauer 33d1cc4bf2 commands: remove struct command pointer from commands
This is unused in all commands and thus can be removed.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-02-27 20:28:07 +01:00
Sascha Hauer d4e5c6b8a0 bootm: use new uimage code
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>
2011-12-15 11:07:11 +01:00
Sascha Hauer e629a53a14 fix underscore count in bss_start/bss_stop
As done in the Linux Kernel

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-07 13:05:25 +01:00
Sascha Hauer 0ee6847f7b Merge branch 'next' 2011-12-07 12:03:13 +01:00
Sascha Hauer 6b1d8ea9fa blackfin: remove contents of page.h to make barebox compilable again
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-07 11:26:20 +01:00
Sascha Hauer 70f7691d41 fix malloc space sizes
end is start + size - 1, not start + size.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-03 10:09:29 +01:00
Sascha Hauer 351058fa51 bootm: push relocate_image up to the generic command
All handlers used to just relocate the image without any checks, so
we are doomed if we write outside of SDRAM or will overwrite ourselves.
Move the relocation up to the generic part where we have a chance
of catching these issues.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-11-29 20:59:56 +01:00
Sascha Hauer 020a30be0d add magicvar command
The magicvar command gives an overview about all environment variables
with a special meaning.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-11-29 20:51:31 +01:00
Sascha Hauer 6b8503baab Merge branch 'master' into next 2011-10-23 13:38:39 +02:00
Loïc Minier 4e26fba680 Only pass -P to cpp when generating ld scripts
When building sandbox with ccache, one would hit warnings such as:
    warning: 'struct mmsghdr' declared inside parameter list
on random files; a way to reproduce this issue is to build a simple
file doing just:
    #include <sys/socket.h>

    int main(void) {
        return 0;
    }

    gcc -Wall -P -c -o foo foo.c

But actually the -P flag is only useful when generating non-C files,
such as linker scripts in the case of barebox.  Removing the -P flag
from all the gcc invocations, except when generating .lds files makes
the warning go away.  It turns out that this is what
linux/scripts/Makefile.build also does nowadays.

Signed-off-by: Loïc Minier <loic.minier@linaro.org>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-10-18 09:18:41 +02:00
Jean-Christophe PLAGNIOL-VILLARD 4ac3a1f9e0 move digest to crypto/
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-10-12 08:52:48 +02:00
Sascha Hauer 0fc7fb6b4f rename include/mem_malloc.h to include/memory.h
Which is a better name and also better to collect other
things.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-09-23 16:32:48 +02:00
Jean-Christophe PLAGNIOL-VILLARD 3d59ba2669 ipe337: switch to resources
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-30 02:05:26 +08:00
Jean-Christophe PLAGNIOL-VILLARD 166388bcf6 resource: introduce add_cfi_device to register simple cfi device
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-23 09:23:40 +08:00
Sascha Hauer f928efa818 add a add_mem_device function
Add a helper function for boards to register their memory
devices. This makes the board code smaller and also helps
getting rid of map_base and struct memory_platform_data.

And switch all of the memory to it

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-18 20:32:45 +08:00
Jean-Christophe PLAGNIOL-VILLARD 88618eb5f1 mem: replace DEVFS_RDWR by IORESOURCE_MEM_WRITEABLE
we keep struct memory_platform_data for now on we will switch off the memories
resources to struct resource

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-18 20:31:51 +08:00
Sascha Hauer 92c1c6cfb1 add sections.h header file
The file location and variable names from the Linux Kernel have been
used here.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-01-17 11:04:24 +01:00
Sascha Hauer bdaf02175c blackfin: provide __bss_stop in linker script
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-01-17 11:03:07 +01:00
Sascha Hauer 2f0109b1bb Merge branch 'master' into next 2011-01-17 09:43:40 +01:00