All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] qemu: nVidia warnings and warning format cleanup
@ 2011-03-18 17:32 Darren Hart
  2011-03-18 17:32 ` [PATCH 1/2] qemu: warn user if nVidia libGL is detected (leads to qemu segfault) Darren Hart
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Darren Hart @ 2011-03-18 17:32 UTC (permalink / raw)
  To: poky; +Cc: Darren Hart

From: Darren Hart <dvhart@linux.intel.com>

The following patches incorporate an updated version of Edwin's patch to
warn the user on the detection of nVidia's libGL and also make the warning
message format used in the script consistent.

Pull URL: git://git.pokylinux.org/poky-contrib.git
  Branch: dvhart/bernard/base
  Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dvhart/bernard/base

Thanks,
    Darren Hart <dvhart@linux.intel.com>
---


Darren Hart (2):
  qemu: warn user if nVidia libGL is detected (leads to qemu segfault)
  qemu: make warning messages consistent in format

 scripts/poky-qemu-internal |   21 +++++++++++++++++----
 1 files changed, 17 insertions(+), 4 deletions(-)



^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 1/2] qemu: warn user if nVidia libGL is detected (leads to qemu segfault)
  2011-03-18 17:32 [PATCH 0/2] qemu: nVidia warnings and warning format cleanup Darren Hart
@ 2011-03-18 17:32 ` Darren Hart
  2011-03-18 17:32 ` [PATCH 2/2] qemu: make warning messages consistent in format Darren Hart
  2011-03-18 23:25 ` [PATCH 0/2] qemu: nVidia warnings and warning format cleanup Richard Purdie
  2 siblings, 0 replies; 4+ messages in thread
From: Darren Hart @ 2011-03-18 17:32 UTC (permalink / raw)
  To: poky; +Cc: Darren Hart

From: Darren Hart <dvhart@linux.intel.com>

nVidia's OpenGL libraries are known to have compatibility issues with qemu,
resulting in a segfault. As different workarounds are required for the different
distributions, just warn the user to explain the qemu segfault to follow, and
suggest a workaround using LD_PRELOAD.

[YOCTO #649]
[YOCTO #698]

(Original patch from Edwin, Darren modified warning and git commit wording)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
CC: Mark Hatle <mark.hatle@windriver.com>
CC: Zhai Edwin <edwin.zhai@intel.com>
---
 scripts/poky-qemu-internal |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/scripts/poky-qemu-internal b/scripts/poky-qemu-internal
index 046e2b6..0f0f799 100755
--- a/scripts/poky-qemu-internal
+++ b/scripts/poky-qemu-internal
@@ -442,10 +442,22 @@ else
     echo "Warning: distccd not present, no distcc support loaded."
 fi
 
+# qemu got segfault if linked with nVidia's libgl
+if ldd $QEMUBIN | grep -i nvidia &> /dev/null
+then
+    echo "************** !!!Warning!!! **************
+    nVidia's proprietary OpenGL libraries are known to have compatibility
+    issues with qemu, resulting in a segfault. Please uninstall these
+    drivers or ensure the mesa libGL libraries precede nvidia's via LD_PRELOAD.
+    " 
+fi
+
 echo "Running $QEMU..."
 # -no-reboot is a mandatory option - see bug #100
 echo $QEMUBIN -kernel $KERNEL $QEMUOPTIONS $SERIALOPTS -no-reboot $SCRIPT_QEMU_OPT $SCRIPT_QEMU_EXTRA_OPT --append '"'$KERNCMDLINE $SCRIPT_KERNEL_OPT'"'
-$QEMUBIN -kernel $KERNEL $QEMUOPTIONS $SERIALOPTS -no-reboot $SCRIPT_QEMU_OPT $SCRIPT_QEMU_EXTRA_OPT --append "$KERNCMDLINE $SCRIPT_KERNEL_OPT" || /bin/true
+# If QEMU crashes, we need to run stty sane
+$QEMUBIN -kernel $KERNEL $QEMUOPTIONS $SERIALOPTS -no-reboot $SCRIPT_QEMU_OPT $SCRIPT_QEMU_EXTRA_OPT --append "$KERNCMDLINE $SCRIPT_KERNEL_OPT" || stty sane
+
 
 cleanup
 
-- 
1.7.1



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 2/2] qemu: make warning messages consistent in format
  2011-03-18 17:32 [PATCH 0/2] qemu: nVidia warnings and warning format cleanup Darren Hart
  2011-03-18 17:32 ` [PATCH 1/2] qemu: warn user if nVidia libGL is detected (leads to qemu segfault) Darren Hart
@ 2011-03-18 17:32 ` Darren Hart
  2011-03-18 23:25 ` [PATCH 0/2] qemu: nVidia warnings and warning format cleanup Richard Purdie
  2 siblings, 0 replies; 4+ messages in thread
From: Darren Hart @ 2011-03-18 17:32 UTC (permalink / raw)
  To: poky; +Cc: Darren Hart

From: Darren Hart <dvhart@linux.intel.com>

Try to make the output of the qemu script a bit more consistent by using the
same format for the various warning messages:

WARNING: description of warning.
Detailed description of warning, actions taken, and/or instructions to user.

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
---
 scripts/poky-qemu-internal |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/scripts/poky-qemu-internal b/scripts/poky-qemu-internal
index 0f0f799..82ef265 100755
--- a/scripts/poky-qemu-internal
+++ b/scripts/poky-qemu-internal
@@ -75,7 +75,7 @@ if [ "$MACHINE" = "qemuarm" ]; then
     RAM=`echo $QEMU_MEMORY | sed 's/M$//'`
     if [[ -z "$RAM" || $RAM -gt 128 ]]; then
         echo "WARNING: qemuarm does not support > 128M of RAM."
-        echo "*** Changing QEMU_MEMORY to default of 128M ***"
+        echo "Changing QEMU_MEMORY to default of 128M."
         QEMU_MEMORY="128M"
         SCRIPT_QEMU_EXTRA_OPT=`echo $SCRIPT_QEMU_EXTRA_OPT | sed -e "s/$mem_set/-m 128/" `
     fi
@@ -102,7 +102,7 @@ acquire_lock() {
         # Check that the lockfile is not stale
         ps=`ps -ewwo pid | grep $(cat $lockfile.lock)`
         if [ -z "$ps" ]; then
-            echo "Warning: Stale lock file detected, deleting $lockfile.lock"
+            echo "WARNING: Stale lock file detected, deleting $lockfile.lock."
             rm -f $lockfile.lock
             echo $$ > $lockfile.lock
         else
@@ -439,17 +439,18 @@ if [ -x "$DISTCCD" ]; then
     PIDFILE=`mktemp`
     $DISTCCD --allow 192.168.7.2 --daemon --pid-file $PIDFILE &
 else
-    echo "Warning: distccd not present, no distcc support loaded."
+    echo "WARNING: distccd not present, no distcc support loaded."
 fi
 
 # qemu got segfault if linked with nVidia's libgl
 if ldd $QEMUBIN | grep -i nvidia &> /dev/null
 then
-    echo "************** !!!Warning!!! **************
-    nVidia's proprietary OpenGL libraries are known to have compatibility
-    issues with qemu, resulting in a segfault. Please uninstall these
-    drivers or ensure the mesa libGL libraries precede nvidia's via LD_PRELOAD.
-    " 
+cat << EOM
+WARNING: nVidia proprietary OpenGL libraries detected.
+nVidia's OpenGL libraries are known to have compatibility issues with qemu,
+resulting in a segfault. Please uninstall these drivers or ensure the mesa libGL
+libraries precede nvidia's via LD_PRELOAD.
+EOM
 fi
 
 echo "Running $QEMU..."
-- 
1.7.1



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 0/2] qemu: nVidia warnings and warning format cleanup
  2011-03-18 17:32 [PATCH 0/2] qemu: nVidia warnings and warning format cleanup Darren Hart
  2011-03-18 17:32 ` [PATCH 1/2] qemu: warn user if nVidia libGL is detected (leads to qemu segfault) Darren Hart
  2011-03-18 17:32 ` [PATCH 2/2] qemu: make warning messages consistent in format Darren Hart
@ 2011-03-18 23:25 ` Richard Purdie
  2 siblings, 0 replies; 4+ messages in thread
From: Richard Purdie @ 2011-03-18 23:25 UTC (permalink / raw)
  To: Darren Hart; +Cc: poky

On Fri, 2011-03-18 at 10:32 -0700, Darren Hart wrote:
> From: Darren Hart <dvhart@linux.intel.com>
> 
> The following patches incorporate an updated version of Edwin's patch to
> warn the user on the detection of nVidia's libGL and also make the warning
> message format used in the script consistent.
> 
> Pull URL: git://git.pokylinux.org/poky-contrib.git
>   Branch: dvhart/bernard/base
>   Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dvhart/bernard/base
> 
> Thanks,
>     Darren Hart <dvhart@linux.intel.com>
> ---
> 
> 
> Darren Hart (2):
>   qemu: warn user if nVidia libGL is detected (leads to qemu segfault)
>   qemu: make warning messages consistent in format

Merged to master, thanks.

Richard



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-03-18 23:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-18 17:32 [PATCH 0/2] qemu: nVidia warnings and warning format cleanup Darren Hart
2011-03-18 17:32 ` [PATCH 1/2] qemu: warn user if nVidia libGL is detected (leads to qemu segfault) Darren Hart
2011-03-18 17:32 ` [PATCH 2/2] qemu: make warning messages consistent in format Darren Hart
2011-03-18 23:25 ` [PATCH 0/2] qemu: nVidia warnings and warning format cleanup Richard Purdie

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.