diff options
author | FranHsu <Fran.Hsu@quantatw.com> | 2019-02-22 20:13:49 +0800 |
---|---|---|
committer | Andrew Geissler <geissonator@yahoo.com> | 2019-03-12 08:14:00 -0500 |
commit | e7428cbc37f9dc0f3f8e73be489fe3b96ee863ca (patch) | |
tree | 759e0e088dca6df88e09610914cdd4eeed33dd2e /meta-quanta/meta-gsj/recipes-phosphor/usb-network/files/usb_network.sh | |
parent | 4ba01a1378ed66f2460f31d50c515d4a3070455a (diff) | |
download | talos-openbmc-e7428cbc37f9dc0f3f8e73be489fe3b96ee863ca.tar.gz talos-openbmc-e7428cbc37f9dc0f3f8e73be489fe3b96ee863ca.zip |
meta-gsj: Add USB-NIC systemd configuration for GSJ board.
(From meta-quanta rev: 41ff54605a8df6e456e2035b410114545bc94284)
Tested: Build Quanta GSJ board image and load on the EVB.
Ensure that BMC boots to console, and the USB network interface is working.
Fix typo.
Change-Id: If93ae6fe2b0181d96630c802adc7e5e216b1de42
Signed-off-by: FranHsu <Fran.Hsu@quantatw.com>
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
Diffstat (limited to 'meta-quanta/meta-gsj/recipes-phosphor/usb-network/files/usb_network.sh')
-rw-r--r-- | meta-quanta/meta-gsj/recipes-phosphor/usb-network/files/usb_network.sh | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/meta-quanta/meta-gsj/recipes-phosphor/usb-network/files/usb_network.sh b/meta-quanta/meta-gsj/recipes-phosphor/usb-network/files/usb_network.sh new file mode 100644 index 000000000..45fa888be --- /dev/null +++ b/meta-quanta/meta-gsj/recipes-phosphor/usb-network/files/usb_network.sh @@ -0,0 +1,27 @@ +#!/bin/bash + +cd /sys/kernel/config/usb_gadget + +if [ ! -f "g1" ]; then + mkdir g1 + cd g1 + + echo 0x1d6b > idVendor # Linux foundation + echo 0x0104 > idProduct # Multifunction composite gadget + mkdir -p strings/0x409 + echo "Linux" > strings/0x409/manufacturer + echo "Ethernet/RNDIS gadget" > strings/0x409/product + + mkdir -p configs/c.1 + echo 100 > configs/c.1/MaxPower + mkdir -p configs/c.1/strings/0x409 + echo "RNDIS" > configs/c.1/strings/0x409/configuration + + mkdir -p functions/rndis.usb0 + + ln -s functions/rndis.usb0 configs/c.1 + + echo f0839000.udc > UDC + +fi +exit 0 |