raspberrypi2: add usb networking and change to usb storage

Add support for USB networking and change to USB storage for the boot
device.  This requires adding in a workaround of
"dwc_otg.fiq_fsm_enable=0" to prevent a hang during boot.  Booting from
a USB devices prevents and issues with "power of 2" for emulated SD
cards and seems to be more reliable.  Also, add in the early console
help with future debugging.

Also, adding in init-ifupdown file to automatically get an IP address on
the USB network interface.  This is the same file currently in OE Core,
only with the USB interface being automatically brought up and given a
dynamic address.  This will help when testimage support is added.

Signed-off-by: Jon Mason <jon.mason@arm.com>
This commit is contained in:
Jon Mason authored and Khem Raj committed 2026-10-13 19:30:08 -07:00
1 parent 5002d6410c
commit 97e3d165a6
3 files changed
+42 -4

No files matched your search

+5 -4
View File
@@ -22,9 +22,10 @@ QB_SYSTEM_NAME = "qemu-system-arm"
QB_MACHINE = "-machine raspi2b"
QB_MEM = "-m 1024"
QB_DTB = "bcm2709-rpi-2-b.dtb"
QB_NET = "none"
QB_KERNEL_ROOT = "/dev/mmcblk0"
QB_KERNEL_CMDLINE_APPEND = "rootwait"
QB_NETWORK_DEVICE = "-device usb-net,netdev=net0,mac=@MAC@"
QB_KERNEL_ROOT = "/dev/sda"
# The dwc_otg.fiq_fsm_enable setting is necessary to get USB devices (both disk and net) working. Without this, boot hangs
QB_KERNEL_CMDLINE_APPEND = "rootwait earlycon=pl011,0x3f201000 dwc_otg.fiq_fsm_enable=0"
QB_RNG = ""
QB_ROOTFS_OPT = "-drive id=disk0,file=@ROOTFS@,if=sd,format=raw"
QB_ROOTFS_OPT = "-drive id=disk0,file=@ROOTFS@,if=none,format=raw -device usb-storage,drive=disk0"
QB_DEFAULT_FSTYPE = "ext3"
@@ -0,0 +1,31 @@
# /etc/network/interfaces -- configuration file for ifup(8), ifdown(8)
# The loopback interface
auto lo
iface lo inet loopback
# Wireless interfaces
iface wlan0 inet dhcp
wireless_mode managed
wireless_essid any
wpa-driver wext
wpa-conf /etc/wpa_supplicant.conf
iface atml0 inet dhcp
# Wired or wireless interfaces including predictable names
auto eth0
iface eth0 inet dhcp
iface eth1 inet dhcp
# Busybox ifupdown won't process /en* correctly
auto /en*=eth
iface eth inet dhcp
# Ethernet/RNDIS gadget (g_ether)
# ... or on host side, usbnet and random hwaddr
auto usb0
iface usb0 inet dhcp
# Bluetooth networking
iface bnep0 inet dhcp
@@ -0,0 +1,6 @@
#
# Enable second network interface on startup
#
PACKAGE_ARCH = "${MACHINE_ARCH}"
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"