9
0
Fork 0
Commit Graph

15083 Commits

Author SHA1 Message Date
Sascha Hauer 024912ba32 ARM: i.MX6 esdctl: Add i.MX6ul support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 17:06:52 +01:00
Sascha Hauer 16e251993e ARM: i.MX: ocotp: Add i.MX6ul support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 14:43:43 +01:00
Sascha Hauer aed902c6ee serial: i.MX: Add i.MX6ul support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 14:43:43 +01:00
Sascha Hauer 068267d554 pinmux: imx-iomux-v3: Add i.MX6ul support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 14:43:42 +01:00
Sascha Hauer 6ad62ff6db ARM: i.MX6 gpt: Add i.MX6ul support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 14:43:42 +01:00
Sascha Hauer 9be6e1db5a ARM: i.MX6ul: Add clock support
Nearly identical to Linux-4.8 clock support, only some unnecessary
clocks skipped.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 14:43:42 +01:00
Sascha Hauer e73608ca3d ARM: i.MX: beginning i.MX6ul support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 14:43:42 +01:00
Sascha Hauer ce864aa5a4 ARM: i.MX: OCOTP: Add functions to access fuses field wise
Add functions to access the OCOTP fuses field wise, similar to what has
been done for the IIM. Also add a i.MX6 fusemap header file.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 14:43:26 +01:00
Sascha Hauer 36be2505d6 serial: i.MX uart: Allow DTE mode in lowlevel code
Some consoles must be configured for DTE mode. Allow to set this
in lowlevel code.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 13:11:45 +01:00
Sascha Hauer 9549b10a7e net: phy: micrel: Do not overwrite reserved bits
ksz8021_config_init() unconditionally sets the KSZPHY_OMSO_RMII_OVERRIDE
bit. This is since the initial micrel phy commit, so it's not
reproducible where this comes from and why this is done. Neither U-Boot
nor the kernel ever touch this bit and so should we. Also, instead
of doing a write only operation, read/modify/write the bit we actually
want to change.
This fixes operation on a KSZ8081MLX which is a MII only phy.
KSZPHY_OMSO_RMII_OVERRIDE is reserved here and must be written to 0.
KSZPHY_OMSO_MII_OVERRIDE is default 1 and must be written as 1.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 12:54:21 +01:00
Stefan Lengfeld 7649dc9ec9 commands: spi: fix chip select validation
The chip selects are numbered 0..(max chip selects - 1). Chip select
with number <max chip selects> is invalid. Fix the check for that. Using
the out of bound chip select may hang your board.

Signed-off-by: Stefan Lengfeld <s.lengfeld@phytec.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 08:55:48 +01:00
Antony Pavlov e6876cde69 command.h: drop unused Struct_Section attribute
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 08:54:52 +01:00
Antony Pavlov b131488f37 MIPS: drop redundant start_barebox() declaration
The start_barebox() function is defined in the <common.h> header file.

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 08:54:13 +01:00
Sascha Hauer 047ee22b89 ARM: Fix appended device tree when CONFIG_OFTREE is enabled
When CONFIG_OFTREE is enabled the appended device tree is unflattened
and put into data->of_root_node, but there it is never used again.
To actually use the appended device tree put it into data->oftree
instead.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-08 08:27:22 +01:00
Alexander Kurz c3223f98c0 scripts imx-image: add DCD NOP command support
The DCD NOP command is available for all flash header v2 devices (i.MX28,
50, 53, 6 and 7).

Signed-off-by: Alexander Kurz <akurz@blala.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-07 08:55:15 +01:00
Alexander Kurz a3390e16ed mfd: mc13892: more descriptive charger register defines
Make access to the mc13892 charger parameter voltage, current and max power
dissipation readable in terms of millivolts, milliamps and milliwatts.

Signed-off-by: Alexander Kurz <akurz@blala.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-07 08:54:31 +01:00
Stefan Lengfeld 63cc1eb8eb docs: state: make string variable type clearer
Only fixed length strings are supported. Make the wording clearer.

Signed-off-by: Stefan Lengfeld <s.lengfeld@phytec.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:20:13 +01:00
Stefan Lengfeld 2e93886c38 state: fix indentation
Signed-off-by: Stefan Lengfeld <s.lengfeld@phytec.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:20:13 +01:00
Stefan Lengfeld 88b67f8ee4 state: use packed attribute for on storage structs
These structs are used for on-storage data layouts. They should be not
affected by different integer precisions and alignment optimizations of
32bit or 64bit machines. Using the architecture independent integer data
types, like uint32_t, achieves the former, using the packed attribute
the later.

Signed-off-by: Stefan Lengfeld <s.lengfeld@phytec.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:19:13 +01:00
Stefan Lengfeld d0f1f07dfa state: fix state is not saved when string variable is changed
The dirty flag was not set properly.

Signed-off-by: Stefan Lengfeld <s.lengfeld@phytec.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:18:08 +01:00
Steffen Trumtrar c93b21178d ARM: socfpga: dtsi: add dw-wdt reset lines
Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:13:19 +01:00
Steffen Trumtrar 9ec4f328f6 watchdog: add designware driver
Port the linux v4.8-rc1 Synopsys DesignWare watchdog driver to barebox.

Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:13:18 +01:00
Lucas Stach 046c5fd251 PCI: split PCI hierarchy enumeration and config from device registration
This gets rid of some of the special cases in the bus scanning function
by splitting hierarchy enumeration and configuration and the actual
device registration into 2 passes.

This ensures that the PCI hierarchy below a root port is completely
set up before any device driver is probed.

This simplifies the code and makes it less error prone, while moving
the PCI address space layout closer to the one used by Linux.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:12:10 +01:00
Lucas Stach 589b62ac9c PCI: align BAR address to BAR size
PCI BARs require their address to be at least aligned to their
size, otherwise address decoding will fail as the base address
gets rounded down.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:12:10 +01:00
Lucas Stach 18ee9aade8 PCI: align address range before scanning bridge
Otherwise we may end up with a too low base address and push
requests for the upstream bus onto the downstream side.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:12:10 +01:00
Lucas Stach 9c29edf10b PCI: only check specific flag for 64bit BAR
The memory type may include other flags, so just check for
the 64bit allocation flag to see if the BAR is a 64bit one.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:12:10 +01:00
Lucas Stach a793b694be PCI: add some useful debug output
This makes diagnosing problems in address space allocation
much easier.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:12:10 +01:00
Lucas Stach 86b716c06a net: e1000: set edev parent pointer
This way the ethernet device will show up at the correct point
in the device hierarchy.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:10:50 +01:00
Lucas Stach 037fa2fedb ARM: riotboard: fix barebox partition size
This was missed when updating all the partition sizes. The
environment partition has been moved to the correct location,
but the barebox partition size remained unchanged.

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:10:00 +01:00
Lucas Stach 8ecc3823cd net: e1000: fix i210 register remapping
Don't mask out the remapping flag before checking the register offset,
otherwise none of the switch statements will ever match.

Fixes: ff6a64d42f (e1000: Consolidate register offset fixups)
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Acked-by: Andrey Smirnov <andrew.smirnov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-11-03 07:08:28 +01:00
Teresa Remmet 91a55bc00f ARM: dts: am33xx.dtsi: Add spi aliases
We need to add the spi aliases to set the bus number correct in
the driver.

Delete the spi1 alias again in the am33xx-strip.dtsi for MLO as
the node is deleted there also.

Signed-off-by: Teresa Remmet <t.remmet@phytec.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-28 08:52:48 +02:00
Sascha Hauer 3b5c343782 dts: update to v4.9-rc2
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-28 08:52:27 +02:00
Sascha Hauer 8129a0a972 fs: squashfs: Enable squashfs XZ support when XZ is enabled
XZ support itself is much more expensive than the squashfs XZ wrapper,
so it makes sense to just compile XZ support into barebox when XZ
support is available. No need to ask the user for it.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-24 08:21:45 +02:00
Enrico Jorns 8a0fb01161 fs: squashfs: append linux rootarg for ubi volume
If squashfs runs from an ubi volume, append appropriate root kernel
options.

Note that ubiblock support is required in the kernel for that.

Signed-off-by: Enrico Jorns <ejo@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-24 08:14:41 +02:00
Enrico Jorns 9bcbb51263 Add filetype and detection for squashfs images
This adds `filetype_squashfs` to the list of known filetypes and adds a
detection for squashfs files to file_detect_type(). This currently
matches on the `hsqs` start sequence of an image file.

Additionally, the newly introduced filetype is registered as the type of
the squashfs_driver which allows, for example, to mount squashfs without
the need to specify a type parameter.

This changes enable booting a squashfs with the simple `boot` command
pointing to the location (device) that holds the squashfs.

Note that booting with blspec is limited as the current squashfs driver
is not capable of handling symbolic links.

Signed-off-by: Enrico Jorns <ejo@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-24 08:14:41 +02:00
Enrico Jorns 6feed0b491 fs: squashfs: port zlib compression support from kernel
As this is the default compression method for squashfs, make this the
default in kconfig selection, too

Signed-off-by: Enrico Jorns <ejo@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-24 08:14:40 +02:00
Enrico Jorns c699e731ae fs: squashfs: port lz4 compression support from kernel
Signed-off-by: Enrico Jorns <ejo@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-24 08:14:40 +02:00
Enrico Jorns 38bc0d55cf fs: squashfs: port lzo compression support from kernel
This ports lzo_wrapper from kernel code and adds some minimal adaptions
to make squashfs lzo compression work in barebox.

Signed-off-by: Enrico Jorns <ejo@pengutronix.de>
Tested-by: Yegor Yefremov <yegorslists@googlemail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-24 08:14:40 +02:00
Sascha Hauer 02ede48e67 gen-dtb-s: Put compressed dtb in different section
For builtin dtbs all compiled dtbs matching section .dtb.rodata.*
are collected in a single section. Since every dtb is compiled as
uncompressed and also as compressed binary each dtb ends up twice
in the section. Let's put the compressed variants in .dtbz.rodata.*
sections rather than .dtb.rodata.*.z so they end up in the binary
only once.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Tested-by: Daniel Krüger <daniel.krueger@systec-electronic.com>
2016-10-24 07:50:18 +02:00
Uwe Kleine-König 6d6d5314fe pinctrl: mvebu: fix a comment about mv78460
It's pin mpp57 that has function vdd/cpu2-3-pd

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-21 09:18:37 +02:00
Yegor Yefremov b4746e29ad arm: Baltos: don't invoke baltos_read_eeprom in MLO
EEPROM information is needed in barebox.bin in order to setup MACs and
select appropriate DTB from kernel-fit.itb, so disable this initcall
in MLO.

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-21 08:53:43 +02:00
Sascha Hauer 28d5eb1bbc state: Use dev_* for information rather than pr_*
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-20 09:34:42 +02:00
Sascha Hauer 82eb3dff10 of_path: handle no driver for device
in __of_find_path it can happen that there is a device, but there
is no driver for this device because it hasn't been probed yet.
Return -ENODEV in this case to let the caller know that it has to
try later again.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-20 09:31:15 +02:00
Sascha Hauer 70af08d863 state: driver: handle EPROBE_DEFER
When state_new_from_node() returns -ENODEV that means that there
is no device available for the node, so return -EPROBE_DEFER in this
case and hope a device is there later.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-20 09:31:11 +02:00
Sascha Hauer 8099956f6a state: pass error code instead of inventing new one
Both of_find_path() and of_find_path_by_node() return a meaningful
error code, so forward it instead of inventing a new one. Do this
especially for the -EPROBE_DEFER case which currently does not work.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-20 09:31:07 +02:00
Uwe Kleine-König 11b7b33971 pinctrl: mvebu: sync mpp names to Linux 4.9-rc1
Linux changed several mpp names in commits:

	438881dfddb9 (pinctrl: mvebu: armada-370: fix spi0 pin description)
	bc99357f3690 (pinctrl: mvebu: armada-xp: remove non-existing NAND pins)
	80b3d04feab5 (pinctrl: mvebu: armada-xp: remove non-existing VDD cpu_pd functions)
	100dc5d84095 (pinctrl: mvebu: armada-{38x,39x,xp}: normalize naming of DRAM functions)
	7bd6a26db6f9 (pinctrl: mvebu: armada-{370,375,38x,39x}: normalize dev pins)
	dae5597f253a (pinctrl: mvebu: armada-{370,375,38x,39x,xp}: normalize TDM pins)
	d4974c16ed22 (pinctrl: mvebu: armada-{370,375}: normalize PCIe pins)
	f32f01e1ba6b (pinctrl: mvebu: armada-{370,375}: normalize audio pins)
	a361cbc575d6 (pinctrl: mvebu: armada-{370,xp}: normalize ethernet txclkout pins)
	bfacb5669474 (pinctrl: mvebu: armada-370: align VDD cpu-pd pin naming with datasheet)
	9e05db29e2ac (pinctrl: mvebu: armada-370: align spi1 clock pin naming)
	50a7d13d2410 (pinctrl: mvebu: armada-xp: rename spi to spi0)
	88b355f1e4e5 (pinctrl: mvebu: armada-xp: add spi1 function)
	fb53b61d7768 (pinctrl: mvebu: armada-xp: add nand rb function)
	b19bf3797679 (pinctrl: mvebu: armada-xp: add dram functions)

Adapt the barebox mvebu drivers accordingly.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-19 15:53:23 +02:00
Sascha Hauer 75ee6ab076 mtd: ubi: enable thread earlier
Since "57cebc4 mtd: ubi: Fix scrubbing during attach" we make sure
that the wear level worker does not start too early. However, now
there are cases when the worker starts too late. When a ubi image is
freshly written a volume may be autoresized. This has to be done
after the wear level worker is started because otherwise the initial
fastmap update will not be able to find any anchor PEBs.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-19 14:49:10 +02:00
Antony Pavlov 0e1b3c4a15 sandbox: eliminate sdl_init()
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-19 12:22:13 +02:00
Uwe Kleine-König 27974c3bae spi: mvebu: make more than one device on a bus work
The mvebu socs support up to 8 chip selects. Make use of them.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-19 12:13:49 +02:00
Yegor Yefremov 1bed248f20 arm: Baltos: setup MPU PLL to run at 600MHz
Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2016-10-19 12:07:42 +02:00