U-boot serial console output disabled

Hi,

In an effort to mitigate a potential security vulnerability, I am attempting to disable u-boot Serial Console output which I am monitoring via FTDI. This can be done by modifying the source of U-Boot to configure the device for silent booting (https://github.com/rickyzhang82/u-boot4bbb/blob/master/doc/README.silent)

I am running Debian 9.9 Stretch IoT on a Beaglebone Black Wireless.

Here is what I have done thus far:

I guess the real question is, how do we update the Beaglebone’s MLO and u-boot.img if we are running the OS from eMMC?

Thanks,
Robert

Open /boot/uEnv.txt and add "silent=1" to the end of the enabled
"cmdline=" value..

Regards,

Is it that easy…?

I tried though and no cigar.

cmdline=coherent_pool=1M net.ifnames=0 rng_core.default_quality=100 quiet silent=1

FTDI serial port still shows logging

U-Boot SPL 2019.04 (Jul 17 2020 - 21:33:18 +0000)
Trying to boot from MMC2
Loading Environment from EXT4… Card did not respond to voltage select!

U-Boot 2019.04 (Jul 17 2020 - 21:33:18 +0000)

CPU : AM335X-GP rev 2.1
I2C: ready
DRAM: 512 MiB



Thanks,
Robert

Idk, i got a little bit to be disabled...

BeagleBone: cape eeprom: i2c_probe: 0x56:
BeagleBone: cape eeprom: i2c_probe: 0x57:
Net: eth0: MII MODE
cpsw, usb_ether
Press SPACE to abort autoboot in 0 seconds
[ 0.002632] timer_probe: no matching timers found
[ 0.224072] l3-aon-clkctrl:0000:0: failed to disable
[ 1.762727] wkup_m3_ipc 44e11324.wkup_m3_ipc: could not get rproc handle

diff --git a/configs/am335x_evm_defconfig b/configs/am335x_evm_defconfig
index 41aa4f2..86c91ea 100644
--- a/configs/am335x_evm_defconfig
+++ b/configs/am335x_evm_defconfig
@@ -5,7 +5,11 @@ CONFIG_AM33XX=y
CONFIG_SPL=y
CONFIG_DISTRO_DEFAULTS=y
CONFIG_BOOTDELAY=0
-CONFIG_BOOTCOMMAND="if test ${boot_fit} -eq 1; then run
update_to_fit; fi; run findfdt; run init_console; run envboot; run
distro_bootcmd"
+CONFIG_BOOTCOMMAND="setenv silent 1; if test ${boot_fit} -eq 1; then
run update_to_fit; fi; run findfdt; run init_console; run envboot; run
distro_bootcmd"
+CONFIG_DISABLE_CONSOLE=y
+CONFIG_LOGLEVEL=0
+CONFIG_SILENT_CONSOLE=y
+CONFIG_SILENT_U_BOOT_ONLY=y
CONFIG_SYS_CONSOLE_INFO_QUIET=y
CONFIG_VERSION_VARIABLE=y
CONFIG_ARCH_MISC_INIT=y

On top of this patch:

https://www.digikey.com/eewiki/display/linuxonarm/BeagleBone+Black#BeagleBoneBlack-Bootloader:U-Boot

and you can update the blobs on the eMMC via the dd lines here:

https://www.digikey.com/eewiki/display/linuxonarm/BeagleBone+Black#BeagleBoneBlack-SetupmicroSDcard

Regards,

Your output looks much better than mine. Recompiled fresh u-boot with patches and updated blobs on the eMMC via:

export DISK=/dev/mmcblk0

sudo dd if=/u-boot/MLO of=${DISK} count=1 seek=1 bs=128k
sudo dd if=/u-boot/u-boot.img of=${DISK} count=2 seek=1 bs=384k

However, lsblk yields:

NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
mmcblk1 179:0 0 3.6G 0 disk
└─mmcblk1p1 179:1 0 3.6G 0 part /
mmcblk1boot0 179:8 0 4M 1 disk
mmcblk1boot1 179:16 0 4M 1 disk
mmcblk1rpmb 179:24 0 4M 0 disk

Is eMMC mmcblk0 as I see all over the forums or mmcblk1 as shown above?

Neither seem to silence the serial console output. uEnv.txt attached.

Thanks

uEnv.txt (2.38 KB)

Use what lsblk lists. :wink:

export DISK=/dev/mmcblk1

Regards,

Thanks Robert. Appreciate the help!