aboutsummaryrefslogtreecommitdiffstats
path: root/packages/mdev
diff options
context:
space:
mode:
authorMichael-Luke Jones <mlj28@cam.ac.uk>2006-09-25 18:46:53 +0000
committerMichael-Luke Jones <mlj28@cam.ac.uk>2006-09-25 18:46:53 +0000
commit41fa5a8dbe2037292318aeab9d41af4de3688414 (patch)
tree0a3ea40d87f54e9d484f55a419eecba8bbeeb5c6 /packages/mdev
parentb9c26c23aa50e080a857261b64312966ae0f327d (diff)
downloadopenembedded-41fa5a8dbe2037292318aeab9d41af4de3688414.tar.gz
mdev: add missing file
Diffstat (limited to 'packages/mdev')
-rw-r--r--packages/mdev/mdev-1.2.1/slugos/loadmicrocode.sh29
1 files changed, 29 insertions, 0 deletions
diff --git a/packages/mdev/mdev-1.2.1/slugos/loadmicrocode.sh b/packages/mdev/mdev-1.2.1/slugos/loadmicrocode.sh
new file mode 100644
index 0000000000..ad1a9e7a44
--- /dev/null
+++ b/packages/mdev/mdev-1.2.1/slugos/loadmicrocode.sh
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+# Manual firmware loading with firmware_class
+# Reason: Because I can (or because mdev doesn't support firmware loading)
+# Trigger: Creation of the /dev/ixp4xx_ucode device (this is hacky too, unfortunately)
+
+sleep 1
+
+# Cancel NPE-A microcode upload
+echo -1 > /sys/class/firmware/ixp4xx_npe.0/loading
+
+sleep 1
+
+# Test for NPE-B presence
+
+if test -f /lib/firmware/NPE-B; then
+ # Upload NPE-B microcode
+ echo 1 > /sys/class/firmware/ixp4xx_npe.1/loading
+ cat /lib/firmware/NPE-B > /sys/class/firmware/ixp4xx_npe.1/data
+ echo 0 > /sys/class/firmware/ixp4xx_npe.1/loading
+else
+ # Cancel NPE-B microcode upload
+ echo -1 > /sys/class/firmware/ixp4xx_npe.1/loading
+fi
+
+sleep 1
+
+# Cancel NPE-C microcode upload
+echo -1 > /sys/class/firmware/ixp4xx_npe.2/loading