Allwinner F1C100S/F1C200S study notes (10)-buildroot changes the default terminal serial port to uart1

1. Demand

After starting the file system, the file system is stuck here, and the keys do not respond:

Starting logging: OK
Initializing random number generator... done.
random: crng init done

It means that the system is running, but the shell program is not started on the serial console. So modify the Buildroot configuration to set the appropriate port and baud rate.
The default terminal serial port of buildroot is uart0, modified here uart1.


Two, enter the graphical interface configuration

make menuconfig
System configuration	--->
	[*]Run a getty (login prompt) after boot	--->
		 --- Run a getty (login prompt) after boot 
		(/dev/ttyS1) TTY port
		Baudrate (115200)  --->                                   
		(vt100) TERM environment variable                                      
		()    other options to pass to getty 

After configuring the /etc/inittabsystem file, it will automatically adjust the generated system file so that the shell program can be started on the correct serial port.

Account: root
Password:licheepi


Three, start LOG

Liche
U-Boot SPL 2018.01-05679-g013ca457fd-dirty (Jan 28 2021 - 17:16:00)
DRAM: 64 MiB
Trying to boot from MMC1


U-Boot 2018.01-05679-g013ca457fd-dirty (Jan 28 2021 - 17:16:00 +0800) Allwinner Technology

CPU:   Allwinner F Series (SUNIV)
Model: Lichee Pi Nano
DRAM:  64 MiB
MMC:   SUNXI SD/MMC: 0
SF: unrecognized JEDEC id bytes: 00, c8, f1
*** Warning - spi_flash_probe_bus_cs() failed, using default environment

Setting up a 480x272 lcd console (overscan 0x0)
In:    serial@1c25400
Out:   serial@1c25400
Err:   serial@1c25400
Net:   No ethernet found.
starting USB...
No controllers found
Hit any key to stop autoboot:  0 
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1...
Found U-Boot script /boot.scr
reading /boot.scr
280 bytes read in 15 ms (17.6 KiB/s)
## Executing script at 80c50000
reading suniv-f1c100s-licheepi-nano.dtb
8035 bytes read in 27 ms (290 KiB/s)
reading zImage
3836208 bytes read in 201 ms (18.2 MiB/s)
## Flattened Device Tree blob at 80c00000
   Booting using the fdt blob at 0x80c00000
   Loading Device Tree to 816fb000, end 816fff62 ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.15.0-rc8-licheepi-nano+ (pjw@pjw-virtual-machine) (gcc version 7.2.1 20171011 (Linaro GCC 7.2-2017.11)) #2 Mon Jan 25 11:04:40 CST 2021
[    0.000000] CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=0005317f
[    0.000000] CPU: VIVT data cache, VIVT instruction cache
[    0.000000] OF: fdt: Machine model: Lichee Pi Nano
[    0.000000] Memory policy: Data cache writeback
[    0.000000] random: fast init done
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 16256
[    0.000000] Kernel command line: console=tty1 console=ttyS1,115200 panic=5 rootwait root=/dev/mmcblk0p2 rw
[    0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Memory: 55164K/65536K available (6144K kernel code, 236K rwdata, 1388K rodata, 1024K init, 244K bss, 10372K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc4800000 - 0xff800000   ( 944 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc4000000   (  64 MB)
[    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
[    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
[    0.000000]       .text : 0x(ptrval) - 0x(ptrval)   (7136 kB)
[    0.000000]       .init : 0x(ptrval) - 0x(ptrval)   (1024 kB)
[    0.000000]       .data : 0x(ptrval) - 0x(ptrval)   ( 237 kB)
[    0.000000]        .bss : 0x(ptrval) - 0x(ptrval)   ( 245 kB)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000046] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
[    0.000115] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[    0.000664] Console: colour dummy device 80x30
[    0.001587] console [tty1] enabled
[    0.001695] Calibrating delay loop... 203.16 BogoMIPS (lpj=1015808)
[    0.070294] pid_max: default: 32768 minimum: 301
[    0.070632] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.070724] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.072201] CPU: Testing write buffer coherency: ok
[    0.073924] Setting up static identity map for 0x80100000 - 0x80100058
[    0.076562] devtmpfs: initialized
[    0.083178] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.083344] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.083646] pinctrl core: initialized pinctrl subsystem
[    0.085745] NET: Registered protocol family 16
[    0.087260] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.089140] cpuidle: using governor menu
[    0.115244] SCSI subsystem initialized
[    0.115663] usbcore: registered new interface driver usbfs
[    0.115883] usbcore: registered new interface driver hub
[    0.116140] usbcore: registered new device driver usb
[    0.116645] pps_core: LinuxPPS API ver. 1 registered
[    0.116728] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <[email protected]>
[    0.116852] PTP clock support registered
[    0.117354] Advanced Linux Sound Architecture Driver Initialized.
[    0.118942] clocksource: Switched to clocksource timer
[    0.145382] NET: Registered protocol family 2
[    0.146871] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.147021] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[    0.147108] TCP: Hash tables configured (established 1024 bind 1024)
[    0.147438] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.147544] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.148070] NET: Registered protocol family 1
[    0.149505] RPC: Registered named UNIX socket transport module.
[    0.149620] RPC: Registered udp transport module.
[    0.149670] RPC: Registered tcp transport module.
[    0.149713] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.151972] NetWinder Floating Point Emulator V0.97 (double precision)
[    0.153862] Initialise system trusted keyrings
[    0.154506] workingset: timestamp_bits=30 max_order=14 bucket_order=0
[    0.172065] NFS: Registering the id_resolver key type
[    0.172233] Key type id_resolver registered
[    0.172291] Key type id_legacy registered
[    0.185763] Key type asymmetric registered
[    0.185868] Asymmetric key parser 'x509' registered
[    0.186108] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 251)
[    0.186205] io scheduler noop registered
[    0.186250] io scheduler deadline registered
[    0.187050] io scheduler cfq registered (default)
[    0.187143] io scheduler mq-deadline registered
[    0.187198] io scheduler kyber registered
[    0.188366] sun4i-usb-phy 1c13400.phy: Couldn't request ID GPIO
[    0.198014] suniv-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver
[    0.367992] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[    0.395022] 1c25000.serial: ttyS0 at MMIO 0x1c25000 (irq = 23, base_baud = 6250000) is a 16550A
[    0.417803] 1c25400.serial: ttyS1 at MMIO 0x1c25400 (irq = 24, base_baud = 6250000) is a 16550A
[    0.894802] console [ttyS1] enabled
[    0.905576] panel-simple panel: panel supply power not found, using dummy regulator
[    0.915091] SCSI Media Changer driver v0.25 
[    0.923018] m25p80 spi0.0: unrecognized JEDEC id bytes: 00, c8, f1
[    0.929986] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.936584] ehci-platform: EHCI generic platform driver
[    0.942248] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    0.948538] ohci-platform: OHCI generic platform driver
[    0.954314] usbcore: registered new interface driver usb-storage
[    0.961483] udc-core: couldn't find an available UDC - added [g_cdc] to list of pending drivers
[    0.970656] i2c /dev entries driver
[    1.029087] sunxi-mmc 1c0f000.mmc: base:0x6917abdb irq:19
[    1.036623] usbcore: registered new interface driver usbhid
[    1.042399] usbhid: USB HID core driver
[    1.064519] NET: Registered protocol family 17
[    1.069427] Key type dns_resolver registered
[    1.076048] Loading compiled-in X.509 certificates
[    1.094525] sun4i-drm display-engine: bound 1e60000.display-backend (ops 0xc07394b8)
[    1.103491] sun4i-drm display-engine: bound 1c0c000.lcd-controller (ops 0xc073879c)
[    1.111366] [drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
[    1.118023] [drm] No driver support for vblank timestamp query.
[    1.172279] Console: switching to colour frame buffer device 60x34
[    1.172657] mmc0: host does not support reading read-only switch, assuming write-enable
[    1.174961] mmc0: new high speed SDHC card at address b368
[    1.176068] mmcblk0: mmc0:b368 NCard 29.1 GiB 
[    1.178438]  mmcblk0: p1 p2
[    1.241825] sun4i-drm display-engine: fb0:  frame buffer device
[    1.261285] [drm] Initialized sun4i-drm 1.0.0 20150629 for display-engine on minor 0
[    1.282948] usb_phy_generic usb_phy_generic.0.auto: usb_phy_generic.0.auto supply vcc not found, using dummy regulator
[    1.313742] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
[    1.332482] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 1
[    1.355581] hub 1-0:1.0: USB hub found
[    1.366172] hub 1-0:1.0: 1 port detected
[    1.378288] using random self ethernet address
[    1.389373] using random host ethernet address
[    1.401966] usb0: HOST MAC ba:67:02:6b:d6:15
[    1.412813] usb0: MAC 5a:bf:df:fb:6d:e1
[    1.423094] g_cdc gadget: CDC Composite Gadget, version: King Kamehameha Day 2008
[    1.443077] g_cdc gadget: g_cdc ready
[    1.454012] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[    1.484021] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[    1.503183] ALSA device list:
[    1.512409]   #0: Loopback 1
[    1.522236] platform regulatory.0: Direct firmware load for regulatory.db failed with error -2
[    1.543042] cfg80211: failed to load regulatory.db
[    1.557028] EXT4-fs (mmcblk0p2): couldn't mount as ext3 due to feature incompatibilities
[    2.029350] random: crng init done
[    6.183805] EXT4-fs (mmcblk0p2): warning: mounting fs with errors, running e2fsck is recommended
[    6.240628] EXT4-fs (mmcblk0p2): recovery complete
[    6.269854] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    6.290043] VFS: Mounted root (ext4 filesystem) on device 179:2.
[    6.308334] devtmpfs: mounted
[    6.321980] Freeing unused kernel memory: 1024K
[    6.495034] EXT4-fs (mmcblk0p2): re-mounted. Opts: data=ordered
Starting logging: OK
Initializing random number generator... done.

Welcome to Lichee Pi
Lichee login: root
Password: 
# cd /
# ls
bin      lib      media    proc     sbin     usr
dev      lib32    mnt      root     sys      var
etc      linuxrc  opt      run      tmp
# 

Reference: Buildroot User Manual-Frequently Asked Questions and Troubleshooting

Guess you like

Origin blog.csdn.net/p1279030826/article/details/113449878