openwrt/target/linux/apm821xx/sata/config-default
Christian Lamparter 8b0407d15d apm821xx: MBL DUO-only: enable USB-Storage for boot from USB support
it is possible to boot and run OpenWrt from an image on an USB-Stick
on the MyBook Live DUO. (No, the MyBook Live Single does NOT have an
USB-Port and attempts at enabling it sadly all failed... so far).

To do that:
First, prepare a USB-Stick by writing the raw and uncompressed OpenWRT
factory image for the device onto the stick (i.e.
 # gunzip -c openwrt-*wd_mybooklive*-factory.img.gz > /dev/sd$XX).

Then enter the u-boot via an attached TTL/CMOS 3.3V cable adapter and
give the following commands a try in the:

 usb start; sata init
 ext2load usb 0:1 ${fdt_addr_r} /boot/apollo3g.dtb
 ext2load usb 0:1 ${kernel_addr_r} /boot/uImage
 setenv bootargs 'root=/dev/sdc2 rw rootfstype=squashfs,ext4 rootdelay=5'
 run addtty; bootm ${kernel_addr_r} - ${fdt_addr_r}

Notes:
 - booting from USB-Sticks takes a long time! Be prepared to wait a few
   minutes. (~3 minutes for 4 MiB /boot/uImage file on a USB 2.0 Stick)

 - the bootargs part 'root=/dev/sdX2' depends on how many HDDs/SSDs are
   slotted in. (if none: then use sda, if one: sdb. if two: sdc)

 - rootdelay is important as the storage on the USB-Sticks do not show
   up fast enough. 5 seconds might be excessive though.

 - it's possible to concat these commands together in one line and
   write it into u-boot's "bootcmd" environment variable and save the
   environment to make the device to always boot from USB from then on.

   if you have accidentally overridden the 'bootcmd' and want to return
   to 'spec' enter the following commands :

   setenv bootcmd 'run boot_sata_script_ap2nc'
   saveenv

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2024-03-02 14:08:07 +01:00

63 lines
1.4 KiB
Plaintext

CONFIG_APOLLO3G=y
CONFIG_BROADCOM_PHY=y
CONFIG_EXT4_FS=y
# CONFIG_SATA_DWC_OLD_DMA is not set
CONFIG_ATA=y
CONFIG_ATA_SFF=y
CONFIG_ATA_BMDMA=y
CONFIG_SATA_PMP=y
CONFIG_GENERIC_PHY=y
CONFIG_SATA_DWC=y
# CONFIG_SATA_DWC_DEBUG is not set
CONFIG_CRYPTO_MD5_PPC=y
CONFIG_CRYPTO_SHA1_PPC=y
CONFIG_EXT4_FS=y
CONFIG_F2FS_FS=y
CONFIG_FREEZER=y
CONFIG_FW_CACHE=y
CONFIG_SCSI=y
CONFIG_BLK_DEV_SD=y
CONFIG_BLK_PM=y
CONFIG_GPIO_GENERIC=y
CONFIG_GPIO_GENERIC_PLATFORM=y
CONFIG_GPIO_74XX_MMIO=y
CONFIG_LEDS_TRIGGER_DISK=y
CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_DM=y
CONFIG_BLK_DEV_DM_BUILTIN=y
CONFIG_BLK_DEV_MD=y
CONFIG_MD=y
CONFIG_MD_AUTODETECT=y
# CONFIG_MD_LINEAR is not set
# CONFIG_MD_MULTIPATH is not set
CONFIG_MD_RAID0=y
CONFIG_MD_RAID1=y
# CONFIG_MD_RAID10 is not set
# CONFIG_MD_RAID456 is not set
CONFIG_MTD_PHYSMAP=y
CONFIG_MTD_JEDECPROBE=y
CONFIG_PM=y
CONFIG_PM_AUTOSLEEP=y
CONFIG_PM_CLK=y
CONFIG_PM_SLEEP=y
# CONFIG_PM_USERSPACE_AUTOSLEEP is not set
CONFIG_PM_WAKELOCKS=y
CONFIG_PM_WAKELOCKS_GC=y
CONFIG_PM_WAKELOCKS_LIMIT=100
CONFIG_PPC_EARLY_DEBUG=y
CONFIG_PPC_EARLY_DEBUG_44x=y
# CONFIG_PPC_EARLY_DEBUG_MEMCONS is not set
# CONFIG_PPC_EARLY_DEBUG_16550 is not set
CONFIG_PPC_EARLY_DEBUG_44x_PHYSHIGH=0x4
CONFIG_PPC_EARLY_DEBUG_44x_PHYSLOW=0xef600300
CONFIG_PPC4xx_CPM=y
CONFIG_REGULATOR_FIXED_VOLTAGE=y
CONFIG_SUSPEND=y
CONFIG_SUSPEND_FREEZER=y
CONFIG_USB=y
CONFIG_USB_COMMON=y
CONFIG_USB_DWC2=y
CONFIG_USB_DWC2_HOST=y
CONFIG_USB_ROLE_SWITCH=y
CONFIG_USB_STORAGE=y