Skip to content

Commit

Permalink
uenv: r3: add sata config to enable power socket
Browse files Browse the repository at this point in the history
  • Loading branch information
frank-w committed Aug 31, 2023
1 parent bb7d5f4 commit 09396f0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion uEnv_r3.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ root=/dev/mmcblk0p6 rootfstype=ext4 rootwait
console=ttyS0,115200n1 earlycon=uart8250,mmio32,0x11002000
bootopts=debug=7

sata_en=0

#netboot
ipaddr=192.168.0.19
netmask=255.255.255.0
Expand Down Expand Up @@ -51,7 +53,8 @@ bootnor=run loadnor;run useinitrd;run setbootconf; run buildargs; bootm ${kaddr}
checkmmc=if mmc partconf 0; then echo "emmc available";mmcdev="emmc";else echo "sd available";mmcdev="sd";fi
checkspi=if sf probe; then echo "NOR available";spidev="nor";else echo "NAND available";spidev="nand";fi

setbootconf=run checkmmc checkspi;echo $mmcdev $spidev;setenv bootconf "#conf-$mmcdev-$spidev"
checksata=satacfg=;if test -n "$sata_en";then satacfg="#sata"; fi;
setbootconf=run checkmmc checkspi checksata;echo $mmcdev $spidev;setenv bootconf "#conf-$mmcdev-$spidev$satacfg"

wrspimnor=if printenv bl2file;then if fatload $device $partition $loadaddr $bl2file;then sf erase 0 0x40000;sf write ${loadaddr} 0 0x40000;else echo "loading bl2 $bl2file failed";fi;else echo "bl2file not defined";fi;if printenv fipfile;then if fatload $device $partition $loadaddr $fipfile;then sf erase 0x100000 0x80000;sf write ${loadaddr} 0x100000 0x80000;else echo "loading fip $fipfile failed";fi;else echo "fipfile not defined";fi
wrspimnand=if printenv bl2file;then if fatload $device $partition $loadaddr $bl2file;then mtd erase spi-nand0 0x0 0x100000;mtd write spi-nand0 $loadaddr 0x0 0x100000;else echo "loading bl2 $bl2file failed";fi;else echo "bl2file not defined";fi;if printenv fipfile;then if fatload $device $partition $loadaddr $fipfile;then mtd erase spi-nand0 0x380000 0x200000;mtd write spi-nand0 $loadaddr 0x380000 0x200000;else echo "loading fip $fipfile failed";fi;else echo "fipfile not defined";fi
Expand Down

0 comments on commit 09396f0

Please sign in to comment.