9
0
Fork 0
Commit Graph

12949 Commits

Author SHA1 Message Date
Pau Espin a07b1b7503 login: Follow timeout guidelines when password returns in time
If there's noise in the serial line, it will usually end up in Password:
prompt and after timeout, autoboot process will be triggered.
However, if the noise is translated to \n or whatever character code
used to finish the password string, the login() funcion will against
request the password() with the full timeout. If the noise keeps
printing the \n or similar character with a high frequency, barebox will
become stuck in the boot process.

Related: SYS#4128
2018-02-15 18:55:53 +01:00
Holger Hans Peter Freyther ca1b8e0ef2 Copy and paste header for gcc6 as well..
Same reasoning as with the gcc5 approach in this older commit
34a48171a6
2017-03-29 23:45:24 +02:00
Holger Hans Peter Freyther 68cc53455b sysmobts: Apply cargo cult and apply workaround
It is not perfectly clear that these apply to our DM6442, it is not
clear we need them but right now I would like to reduce the delta
from U-Boot to Barebox in terms of system initialization.

So apply some form of cargo cult and do the same as U-boot. This has
not been tested on a board and needs to be done. Then it can be put
back into our "master" branch. But it looks writel takes the value
first and then the address.
2016-06-28 09:36:24 +02:00
Holger Hans Peter Freyther 5c5b53555b sysmobts: Increase FPGA turn-a-round time to help NAND
For the Toshiba NAND chip if both NAND (read) and FPGA CS the
time to switch might not be enough. Wait longer as discussed
by email.
2016-06-28 09:15:35 +02:00
Holger Hans Peter Freyther ccabbeb6c2 sysmobts: Always attach as ubi1 to avoid clash with the system 2016-06-11 11:12:22 +02:00
Holger Hans Peter Freyther ae9ef45dd2 rescue: ubiattach /dev/mtd4 as ubi0
This makes the rest of the software kind of work and leaves the
rescue ubi unattached.
2016-06-10 19:00:52 +02:00
Holger Hans Peter Freyther 52b44d0271 sysmobts: Put the rescue system into a ubi on its own.
When ubifs/ubi corrupts... the only way to recover is to format it
again. We can only do that _if_ the rescue image is not in it. It is
annoying because it means system0/system1 and rescue can not share
the same reservation for badblocks.
2016-06-10 18:37:39 +02:00
Holger Hans Peter Freyther f2b03e21a8 sysmobts: Add support for revg and later versions 2016-06-06 14:34:17 +02:00
Harald Welte ec82959f05 OWHW: Reset the switch only at power-up
We use the AM335x-provided reset reason to issue the SWITCH_RESET
only on actual power-up reset, andn ot at subsequent (soft) reboots.
2016-04-10 12:49:04 +02:00
Harald Welte ccbf22a14b OWHW: Issue SWITCH_RESET during boot
The hardware timings for SWITCH_RESET at power-up might not be
sufficient for a proper reset, so let's make sure we put the switch into
reset for at least 10ms (80E6063 requirement) during the boot-up
sequence.
2016-04-10 12:48:50 +02:00
Harald Welte 341203778b OWHW: move boot state to beginning of partition
(somehow barebox-state resolves to the entire EEPROM, not the partition
 with its offset, so let's move the partition to the start to make sure
 barebox and linux agree about this)
2016-02-23 00:33:04 +01:00
Harald Welte ce8849b03a OWHW: Add device tree for hardware v2 2016-02-17 20:04:16 +01:00
Harald Welte 59d35fe8f9 Print error message if of_state_fixup() fails
If of_state_fixup() fails for some reason, boot/bootm will fail, too

However, it is completely unclear where the error has happened, and to
the user it rather seems like the kernel device tree loaded from some
file was broken/corrupt, not that in fact some fixup routine was
failing.

Adding a meaningful error message can help debugging significantly.

Signed-off-by: Harald Welte <laforge@gnumonks.org>
2016-02-17 20:04:16 +01:00
Harald Welte 862064ee4f eeprom/at25: parse partitions from device tree
Unlike at24 (I2C), the at25 (spi) EEPROM driver doesn't check if the
device tree node contains partition definitions.  This means that one
for example cannot have bootstate partitions on an at25 EEPROM, while it
works on an at24 EEPROM.

This patch adds device tree based partition support to the at25 driver.

Signed-off-by: Harald Welte <laforge@gnumonks.org>
2016-02-17 20:04:16 +01:00
Holger Hans Peter Freyther 34a48171a6 misc: Include compiler-gcc5.h from u-boot/linux
Upstream barebox has removed the compiler-gcc3/4 header files for
a unified header but I do not want to risk breaking gcc4 support
for the unknown gcc5 work right now.
2015-11-25 16:34:41 +01:00
Jan Luebbe 0b1cbb933d sysmobts: enable DSP clock
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-11-22 16:00:07 +01:00
Jan Luebbe db4205f8ba sysmobts: configure AEMIF CS3 for the FPGA
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-11-22 16:00:07 +01:00
Harald Welte 8a75b87fb2 OWHW: only set global.initrd if the system0/1 partition contains one 2015-11-07 17:22:01 +01:00
Harald Welte 238fc4b130 OWHW: Fix GPIO assignment for GPIO button (1_25 instead of 1_22) 2015-11-05 16:15:15 +01:00
Harald Welte 4e4776272a OWHW: Support AT24CM02 EEPROM 2015-11-01 23:19:08 +01:00
Harald Welte 4d1c656aa7 OWHW: Fix pinmux for I2C bus 1 (I2C_EXT) 2015-10-31 18:21:08 +01:00
Harald Welte 7b346a04b7 Initial GSMK OWHW v1 board support 2015-10-31 18:08:07 +01:00
Jan Luebbe 95e1a85cb2 sysmobts: use slot layout for the rescue volume
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-08-06 14:26:36 +02:00
Jan Luebbe b4f2980ff1 sysmocom-odu: use slot layout for the rescue volume
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-08-06 14:26:10 +02:00
Jan Luebbe 56c50b3f4b sysmocom-odu: read mac addresses from EEPROM
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-08-06 13:01:31 +02:00
Sascha Hauer 111a6aa4a9 net: make eth_register_ethaddr work on registered network devices
When eth_register_ethaddr is called after the device has been registered
it should work aswell.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2015-08-05 15:42:37 +02:00
Jan Luebbe 8d95a37cae fixup! davinci_nand: add support for the NAND controller 2015-07-30 17:20:33 +02:00
Jan Luebbe fdb5835c72 fixup! watchdog: add davinci watchdog driver 2015-07-30 17:20:32 +02:00
Jan Luebbe 7a526685a8 i2c: gpio: add bus recovery support
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-30 16:46:27 +02:00
Jan Luebbe 39e4db8376 i2c: algo-bit: check if the bus is busy
If we have a timeout while waiting, try to recover.

Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-30 16:46:27 +02:00
Jan Luebbe 8127dfdaa1 i2c: algo-bit: fix debug code
Replace jiffies from kernel code with get_time_ns. The flags variable
used in the readbytes debug output does not exist.

Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-30 16:46:27 +02:00
Jan Luebbe af26985016 i2c-omap: add bus recovery support
This is based on commit 9dcb0e7b999db6c420c70fd32497a979a044fcdf from
the kernel with some additional fixes.

Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-30 16:46:27 +02:00
Jan Luebbe 96617c5ef3 i2c-omap: clear ARDY twice
This implements the fix from the kernel commit
4cdbf7d346e7461c3b93a26707c852e2c9db3753.

Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-30 16:46:27 +02:00
Jan Luebbe 21203581e7 i2c: add bus recovery infrastructure
This is based on the code introduced to the kernel in
5f9296ba21b3c395e53dd84e7ff9578f97f24295.

Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-30 16:46:27 +02:00
Jan Luebbe 59835890e5 state: fix missing newline in error message
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-08 15:25:51 +02:00
Jan Luebbe cb9695a3ea state: handle write-protection in the raw backend
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-03 14:41:47 +02:00
Jan Luebbe 0b3fd92ffb sysmocom-odu: configure eeprom write-protect GPIO
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-03 14:41:47 +02:00
Jan Luebbe d7c8571e2e at24: support write-protect GPIO
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-07-03 14:41:47 +02:00
Jan Luebbe 9f78d1b7a7 sysmocom-odu: remove password configuration
Instead, it is configured only for the release version build using
yocto.

Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-30 18:25:01 +02:00
Hubert Feurstein 9917f610da login: fix broken login command
It was possible to login with ctrl-c or an empty password. This bug was
introduced by the recent digest changes in common/password.c (e49a47fb).
The function check_passwd returns now also negative error codes which were
not correctly handled in do_login.

Signed-off-by: Hubert Feurstein <h.feurstein@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2015-06-24 17:14:25 +02:00
Jan Luebbe 05d4d07f38 sysmocom: set the default load address to 0x81000000
This solves a problem which causes boot failure when using a uImage with
device tree. It should also speed up boot because the kernel can skip
copying itself out of the way.

Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-15 14:13:33 +02:00
Jan Luebbe ca0ad3d6ec sysmocom: configure the watchdog for 60 seconds
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-15 14:13:00 +02:00
Jan Luebbe 05bacd6d5a sysmobts: run lindent
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:33:04 +02:00
Jan Luebbe 3fde441a69 sysmobts: disable NAND write protect where needed
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:17:09 +02:00
Jan Luebbe 28d0b22dfc sysmobts: detect the eeprom variant at runtime
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:17:09 +02:00
Jan Luebbe 2d5f45ce27 sysmobts: fix board versio detection
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:17:09 +02:00
Jan Luebbe 871416425c sysmobts: use uImages for now
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:17:09 +02:00
Jan Luebbe eaac82d37f sysmocom-odu: use uImages for now
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:17:09 +02:00
Jan Luebbe 7bd41df8cd spi: only register enabled child nodes
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:17:09 +02:00
Jan Luebbe cda1089054 i2c: only register enabled child nodes
Signed-off-by: Jan Luebbe <jluebbe@debian.org>
2015-06-14 12:17:09 +02:00