summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* efi: add support for initrd loadingMichael Olbrich2015-07-232-14/+181
| | | | | Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* efi: improve malloc pool allocationMichael Olbrich2015-07-231-3/+17
| | | | | | | | | | Use allocate_pages() instead of allocate_pool(). With allocate_pages() we can specify the address. This way, any address passed to the kernel will never exceed the lower 32 bit. If possible, try to allocate a larger pool. Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* xfuncs: add wrapper for wchar strdup functionsMichael Olbrich2015-07-232-0/+36
| | | | | Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* xfuncs: add xasprintf() and xvasprintf()Michael Olbrich2015-07-232-0/+27
| | | | | Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* drop <stddef.h> includesSascha Hauer2015-07-233-4/+0
| | | | | | | The compilers stddef.h should not be included. We declare all types ourselves. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* net: eth_send: Allow to use multiple network interfaces at onceAntony Pavlov2015-07-231-1/+1
| | | | | | | | | | | | | | | | | | | | The commit commit be0404c21f22da2d736168b2e56a9ae583cc3e95 Author: Sascha Hauer <s.hauer@pengutronix.de> Date: Wed May 14 16:08:04 2014 +0200 net: Allow to use multiple network interfaces at once changes the eth_send() function: - return eth_current->send(eth_current, packet, length); + return edev->send(eth_current, packet, length); But we have to change the both eth_current occurrences to edev here! Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Makefile: Use cc-option for -fno-delete-null-pointer-checksSascha Hauer2015-07-131-2/+3
| | | | | | To only pass this option when it's supported by the compiler. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* ARM: omap: xload: Fix func uninitialized warningSascha Hauer2015-07-131-0/+1
| | | | | | | When doing USB boot without having it enabled in the config func is used unitialized. Explicitly set this to NULL so that booting fails in this case. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Build with -fno-delete-null-pointer-checksSascha Hauer2015-07-081-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | This becomes important with gcc-4.9. Without this gcc assumes that accessing NULL pointers traps and everything that happens behind the access is not executed. This recently happened with i.MX53 which has: static int imx53_silicon_revision(void) { void __iomem *rom = MX53_IROM_BASE_ADDR; rev = readl(rom + SI_REV); ... } This resulted in object code in which the last instruction is the readl, the reset of the function is missing because gcc assumes this is never executed. Disable this optimization with -fno-delete-null-pointer-checks since in barebox NULL pointers can indeed be valid. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* digest: digest doesn't return an error if the signature length is incorrectPhilippe Leduc2015-07-061-2/+3
| | | | | | | | fix: digest return no error even if the digest length is wrong fix: documentation error (-v -> -s / -V -> -S) Signed-off-by: Philippe Leduc <ledphilippe@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/blspec'Sascha Hauer2015-07-0614-1/+166
|\
| * blspec: Automatically append rootargSascha Hauer2015-06-182-1/+35
| | | | | | | | | | | | | | | | | | | | | | This patch makes it possible to automatically add a suitable root= option for booting Linux from the same filesystem on which the bootspec entry has been found. This adds an additional 'linux-appendroot' option to bootspec which if set to 'true' will cause barebox to automatically add a root= option. This currently works for NFS, UBIFS and regular block devices like ATA, SD/MMC using the root=PARTUUID= mechanism. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * fs: nfs: Implement Linux rootargSascha Hauer2015-06-182-0/+37
| | | | | | | | | | | | | | Add the root= parameter for NFS filesystems. We currently hardcode v3 and tcp which probably needs to become configurable at some point. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * fs: ubifs: Implement Linux rootargSascha Hauer2015-06-183-0/+25
| | | | | | | | | | | | | | | | Add the parameter to boot from ubifs fileystems. This assumes that there will be only one UBI device registered in the kernel, otherwise there is no way to predict the ubi number. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * fs: Add device parameter for Linux root= optionSascha Hauer2015-06-182-0/+41
| | | | | | | | | | | | | | | | | | | | When registering a filesystem device add a device parameter suitable for the Linux root= option to boot from exactly this filesystem. Currently the fs layer sets this parameter to the root=PARTUUID= mechanism if a partuuid is available. Other filesystems like NFS and UBIFS which do not have a PARTUUID can overwrite this. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * cdev: Add partuuid string to struct cdevSascha Hauer2015-06-184-0/+9
| | | | | | | | | | | | | | | | This adds the partuuid string to struct cdev in order to have this available for constructing a suitable Linux root=PARTUUID= option for booting Linux. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * Add globalvar_add_simple_string functionSascha Hauer2015-06-181-0/+19
| | | | | | | | | | | | | | | | This adds a globalvar string function to pass a pointer to a string. With this we can directly access the string to get the variable and don't have to getenv() the string first. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/state'Sascha Hauer2015-07-035-19/+229
|\ \
| * | state: fixup: only export default value during fixup if setMarc Kleine-Budde2015-06-261-8/+19
| | | | | | | | | | | | | | | Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | state: add support for fixed length stringsMarc Kleine-Budde2015-06-262-4/+167
| | | | | | | | | | | | | | | Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | state: struct variable_type::import: remove const from node argumentMarc Kleine-Budde2015-06-181-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | This patch removes the const qualifier of the node argument from struct variable_type::import. This is a preparation patch to support fixed strings in state. Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | xfuncs: import xstrndup() from busyboxMarc Kleine-Budde2015-06-182-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | This function is needed for the fixed length string feature in the state framework. Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | parameter: allow setting of string parameters of zero lengthMarc Kleine-Budde2015-06-181-1/+1
| | | | | | | | | | | | | | | Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | state: uint8: add range check for uint8Marc Kleine-Budde2015-06-171-2/+15
| | | | | | | | | | | | | | | | | | | | | | | | Bail out, if the user tries to set a value > 255. Cc: Jan Luebbe <jluebbe@debian.org> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | state: uint8: use %u as format stringMarc Kleine-Budde2015-06-171-1/+1
| | | | | | | | | | | | | | | | | | Cc: Jan Luebbe <jluebbe@debian.org> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | Merge branch 'for-next/pwm'Sascha Hauer2015-07-0313-13/+554
|\ \ \
| * | | PWM: Add MXS PWM supportSascha Hauer2015-06-123-0/+181
| | | | | | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | PWM: Allow multiple PWMs per device nodeSascha Hauer2015-06-122-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Matching a device node is enough since a device node may have multiple PWMs. Check for a id aswell. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | ARM: i.MX28: Add PWM clk supportSascha Hauer2015-06-122-0/+2
| | | | | | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | video: Add PWM backlight supportSascha Hauer2015-06-123-0/+208
| | | | | | | | | | | | | | | | | | | | | | | | This adds a backlight driver for backlights controlled by a PWM. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | video: Add backlight supportSascha Hauer2015-06-124-0/+115
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds a small backlight layer. It provides a backlight device on which the brightness parameter can be used to adjust the brightness. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | video: stmfb: Add device tree supportSascha Hauer2015-06-121-10/+42
| | | | | | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/omap'Sascha Hauer2015-07-0327-91/+1468
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | Conflicts: arch/arm/boards/beagle/board.c
| * | | | ARM: beagleboard: Move to multiimage supportSascha Hauer2015-07-0213-53/+132
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Breathe some life back into the beagleboard: - switch to multiimage support - update config - initialize early UART for debugging Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | ARM: add a machine number mechanism for boarddataSascha Hauer2015-07-022-17/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Multi machine barebox builds have to pass information on which board we are running on via boarddata. Usually this will be a pointer to a device tree. Some boards might not have a device tree available though because they are either not ported over to device tree yet, or are running in some limited first state environment which does not offer enough space for a device tree. For these cases this patch adds a mechanism to embed a machine number into a struct type along with a magic number. This makes it possible to check for a specific machine later during regular runtime. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | bus: omap-gpmc: Add Generic device supportSascha Hauer2015-07-021-0/+142
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for generic devices like NOR flash and ethernet to the gpmc bus driver. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | of: export of_platform_device_createSascha Hauer2015-07-022-1/+3
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | bus: omap-gpmc: fix wrong bit settingSascha Hauer2015-07-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GPMC_CONFIG4_WEEXTRADELAY should be set depending on we_extra_delay, not on oe_extra_delay. This seems to be copy-pasted from two lines above. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | ARM: OMAP: Add omap3 USB loader toolSascha Hauer2015-07-027-2/+1134
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The OMAP3 supports uploading the first stage bootloader via USB. The ROM leaves the MUSB controller enabled and it can then be used to upload a 2nd stage image. This patch adds the omap3-usb-loader tool and the necessary barebox support to upload the 2nd stage image. The omap usb loader tool is downloaded from https://github.com/grant-h/omap_loader and changed to also accept CHSETTINGS images. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | ARM: OMAP3: Change DSS divider to the one U-Boot usesSascha Hauer2015-07-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | U-Boot uses 2 as the DSS divider, so do the same in barebox. This shouldn't currently have any effect to barebox, but makes porting some U-Boot code easier which makes assumptions about the DSS clock rate. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | ARM: OMAP: remove unused CONFIG_OMAP3_CLOCK_CONFIG optionSascha Hauer2015-06-224-16/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All boards have this option enabled and there should be no reason to disable it. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | | Merge branch 'for-next/net'Sascha Hauer2015-07-032-25/+35
|\ \ \ \ \
| * | | | | dns: handle incoming packets in the separate dns_recv() functionAntony Pavlov2015-07-011-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The separation of incoming packets handling makes it much easier to run barebox dns client on top of picotcp network stack in the future. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | | tftp_recv(): handle opcode field in a more natural wayAntony Pavlov2015-06-291-8/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RFC1350 uses the 'opcode' term for the first 2-bytes field of TFTP packet. But the U-boot tftp code uses the 'proto' term for the same thing. The patch takes back original term and makes opcode calculation more clear. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | | tftp_recv(): according to RFC1350 minimal tftp packet length is 4 bytesAntony Pavlov2015-06-291-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | | fs/tftp: handle incoming packets in the separate tftp_recv() functionAntony Pavlov2015-06-291-10/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The separation of incoming packets handling makes it much easier to run barebox tftp client on top of picotcp network stack in the future. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | | | Merge branch 'for-next/mxs'Sascha Hauer2015-07-031-1/+8
|\ \ \ \ \ \
| * | | | | | ARM: MXS: ocotp: Register a separate deviceSascha Hauer2015-06-121-1/+8
| | |_|/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With device tree the device name starts with a number, so the device parameters are not accessible on the shell. Register a separate device for the ocotp to make the permanent_write_enable variable accessible again. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | | | Merge branch 'for-next/mtd'Sascha Hauer2015-07-038-54/+84
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: drivers/mtd/core.c
| * | | | | | ubi: Update documentationSascha Hauer2015-06-261-29/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous patches changed the UBI naming and made automounting UBIFS easier. Update the documentation accordingly. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>