[oe-commits] Adrian Alonso : xserver-kdrive-common: Xsever module_id for virtex5 platform

git version control git at git.openembedded.org
Wed Aug 4 17:48:12 UTC 2010


Module: openembedded.git
Branch: org.openembedded.dev
Commit: e827b4131ef609068d00578e696f62312393fb3a
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=e827b4131ef609068d00578e696f62312393fb3a

Author: Adrian Alonso <aalonso00 at gmail.com>
Date:   Tue Aug  3 06:23:24 2010 +0000

xserver-kdrive-common: Xsever module_id for virtex5 platform

* Return a valid module_id for xilinx virtex platform
* On Xilinx platforms there is no line `Hardware`. Instead it is
  stored in the line starting with `platform`.
* v2 split changes, nicer module_id function for handling xilinx
  virtex platforms

Signed-off-by: Adrian Alonso <aalonso00 at gmail.com>
Acked-by: Frans Meulenbroeks <fransmeulenbroeks at gmail.com>

---

 .../xserver-kdrive-common/Xserver                  |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/recipes/xserver-kdrive-common/xserver-kdrive-common/Xserver b/recipes/xserver-kdrive-common/xserver-kdrive-common/Xserver
index 347b005..b6c27df 100644
--- a/recipes/xserver-kdrive-common/xserver-kdrive-common/Xserver
+++ b/recipes/xserver-kdrive-common/xserver-kdrive-common/Xserver
@@ -34,7 +34,11 @@ module_id() {
     # grep "Module ID" /proc/hal/assets | sed "s/.*://"
     ## used to read from /proc/hal/model, but that is removed in 2.6
     # echo ' iPAQ' `cat /proc/hal/model`
-    awk 'BEGIN { FS=": " } /Hardware/ { print $2 } ' </proc/cpuinfo
+    id=`awk 'BEGIN { FS=": " } /Hardware/ { print $2 } ' </proc/cpuinfo`
+    if [ -n "$id" ]; then
+        id=`awk 'BEGIN { FS=": " } /platform/ { print $2 } ' </proc/cpuinfo`
+    fi
+    echo -n "$id"
 }
 
 export USER=root





More information about the Openembedded-commits mailing list