<div dir="ltr"><div style>In continuation to the previous mail...</div><div style><br></div><div style>In this file ./xserver/hw/xfree86/xwayland/xwayland-drm.c </div><div style>at line 83 whenever the interface is "wl_drm" ,i.e the following condition is true,</div>

<div>if (strcmp (interface, "wl_drm") == 0)<br></div>xwl_screen->registry always comes to be 0x0<br><div><br></div><div style><b>gdb output:</b></div><div style><div>Breakpoint 1, drm_handler (data=0x19ca0b0, registry=0x19c25b0, id=11, interface=0x19cf6e0 "wl_drm", version=1) at xwayland-drm.c:84</div>

<div>84<span class="" style="white-space:pre">  </span>        printf("\nxwl_screen->registry:%d\n",xwl_screen->registry);</div><div>(gdb) print xwl_screen</div><div>$1 = (struct xwl_screen *) 0x19ca0b0</div>

<div>(gdb) print xwl_screen->registry</div><div>$2 = (struct wl_registry *) 0x0</div><div>(gdb) </div><div><br></div><div style>any help?</div><div style><br></div><div style>Thanks.</div><div style><br></div><div style>

Ashish.</div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Jan 25, 2013 at 3:43 PM, ashjas <span dir="ltr"><<a href="mailto:ashjas@gmail.com" target="_blank">ashjas@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hello,<div><br></div><div>I tried attaching the Xorg process to gdb to get a more detailed backtrace.(by adding sleep to the child process)</div>

<div><br></div><div>here is the full backtrace from gdb:<a href="http://pastebin.com/pWE7px0S" target="_blank">http://pastebin.com/pWE7px0S</a></div>
<div><br></div><div>as can be seen in the 3rd frame .. all seems to be fine as there are no null values.</div><div><font color="#674ea7"> xwl_screen->drm = wl_registry_bind(xwl_screen->registry, id,</font></div>
<div><font color="#674ea7">                                           &wl_drm_interface, 1);</font></div><div><br></div><div>but when the<font color="#674ea7"> xwl_screen->registry</font> reaches to <font color="#674ea7">wl_registry_bind (wl_registry=0x0, name=11, interface=0x7feb89670c60, version=1)</font> here the value becomes null. which propagates to function</div>


<div><font color="#674ea7">wl_proxy_create (factory=0x0, interface=0x7feb89670c60)</font><br></div><div>where it segfaults at the line </div><div><font color="#674ea7">struct wl_display *display = factory->display;</font><br>


</div><div><font color="#674ea7"><br></font></div><div><font color="#000000">Any clues why?</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Thanks </font></div><div>
<font color="#000000"><br></font></div><div><font color="#000000">Regards,</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Ashish</font></div><div><br></div></div><div class="HOEnZb"><div class="h5">


<div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Jan 25, 2013 at 10:07 AM, ashjas <span dir="ltr"><<a href="mailto:ashjas@gmail.com" target="_blank">ashjas@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


<div dir="ltr">Hello Bill,<div><br></div><div>Thanks for sending the patch.</div><div>But after using it, my crash had no effect its still failing with the same log and at same place.</div><div>I guess the problem is not what you had thought?</div>



<div>Any other clues? Ill dig up more at my end in the meanwhile.</div><div><br></div><div>Thanks for helping</div><div><br></div><div>Regards,</div><div>Ashish</div></div><div><div><div class="gmail_extra">

<br><br><div class="gmail_quote">On Fri, Jan 25, 2013 at 1:47 AM, Bill Spitzak <span dir="ltr"><<a href="mailto:spitzak@gmail.com" target="_blank">spitzak@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">



<div>ashjas wrote:<br>
> Thanks Bill for that info.. after searching for your patch i found this<br>
> discussion of what you indicated.. but i couldnot find the patch that<br>
> you mentioned..<br>
> <a href="http://lists.freedesktop.org/archives/wayland-devel/2012-September/005203.html" target="_blank">http://lists.freedesktop.org/<u></u>archives/wayland-devel/2012-<u></u>September/005203.html</a><br>
><br>
> can you give me some pointers?<br>
><br>
> Thanks.<br>
<br></div>
This allows X applications to be run on wayland without having to<br>
delete conf files needed to run the legacy X server on the same<br>
machine.<br>
<br>
The --config and --configdir switches can override these changes.<br>
<br>
An extra patch to xorg was needed, as it *always* looked for<br>
xorg.conf.d. I changed it to not do this if --configdir or<br>
--wayland was given.<br>
---<br>
 hw/xfree86/common/xf86Config.c |    5 ++++-<br>
 hw/xfree86/common/xf86Init.c   |    4 ++++<br>
 2 files changed, 8 insertions(+), 1 deletion(-)<br>
<br>
diff --git a/hw/xfree86/common/<u></u>xf86Config.c b/hw/xfree86/common/<u></u>xf86Config.c<br>
index 3934ff0..2376889 100644<br>
--- a/hw/xfree86/common/<u></u>xf86Config.c<br>
+++ b/hw/xfree86/common/<u></u>xf86Config.c<br>
@@ -2386,7 +2386,10 @@ xf86HandleConfigFile(Bool autoconfig)<br>
             dirfrom = X_CMDLINE;<br>
<br>
         xf86initConfigFiles();<br>
-        sysdirname = xf86openConfigDirFiles(SYS_<u></u>CONFIGDIRPATH, NULL,<br>
+        if (xf86ConfigDir)<br>
+            sysdirname = 0;<br>
+        else<br>
+            sysdirname = xf86openConfigDirFiles(SYS_<u></u>CONFIGDIRPATH, NULL,<br>
                                             PROJECTROOT);<br>
         dirname = xf86openConfigDirFiles(<u></u>dirsearch, xf86ConfigDir, PROJECTROOT);<br>
         filename = xf86openConfigFile(filesearch, xf86ConfigFile, PROJECTROOT);<br>
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c<br>
index a062929..b2a668c 100644<br>
--- a/hw/xfree86/common/xf86Init.c<br>
+++ b/hw/xfree86/common/xf86Init.c<br>
@@ -1412,6 +1412,10 @@ ddxProcessArgument(int argc, char **argv, int i)<br>
   if (!strcmp(argv[i], "-wayland"))<br>
   {<br>
     xorgWayland = TRUE;<br>
+    if (!xf86ConfigFile)<br>
+      xf86ConfigFile = "xwayland.conf";<br>
+    if (!xf86ConfigDir)<br>
+      xf86ConfigDir = "xwayland.conf.d";<br>
     return 1;<br>
   }<br>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>