[Buildroot] [PATCH] raspberrypi, raspberrypi2: add a serial console

Alexander Dahl post at lespocky.de
Tue Mar 29 11:30:18 UTC 2016


Hei hei,

Am 2016-03-29 00:08, schrieb Luca Ceresoli:
> The current Buildroot defconfigs for Raspberry Pi and Raspberry Pi 2
> instantiate a console on tty1, which appears on HDMI. Add a console on
> the serial port (ttyAMA0) to be more consistent with other defconfigs
> and provide a better out-of-the-box experience to users used to have a
> serial console from Buildroot defconfigs.

I ran in the very problem last week. So +1 for the idea.

> This requires two changes:
>  1. have two 'console=' entries in the kernel command line;
>  2. add a new getty process to the generated inittab.

Then why not split up those two changes in two patches? ;-)

> -BR2_TARGET_GENERIC_GETTY_PORT="tty1"
> +BR2_TARGET_GENERIC_GETTY_PORT="ttyAMA0"

+1

> diff --git a/package/rpi-firmware/cmdline.txt b/package/rpi-firmware/cmdline.txt
> index 38aa3782621b..155a54693bff 100644
> --- a/package/rpi-firmware/cmdline.txt
> +++ b/package/rpi-firmware/cmdline.txt
> @@ -1 +1 @@
> -root=/dev/mmcblk0p2 rootwait
> +root=/dev/mmcblk0p2 rootwait console=tty1 console=ttyAMA0,115200

+1

Not sure about the post build script though, maybe someone with more
experience in buildroot could comment on that.

Greets
Alex

-- 
»With the first link, the chain is forged. The first speech censured,
the first thought forbidden, the first freedom denied, chains us all
irrevocably.« (Jean-Luc Picard, quoting Judge Aaron Satie)
*** GnuPG-FP: C28E E6B9 0263 95CF 8FAF  08FA 34AD CD00 7221 5CC6 ***



More information about the buildroot mailing list