<font class="Apple-style-span" face="arial, helvetica, sans-serif">An update on this -- At Linux Plumbers and XDC last week, we had a chance to have some discussions about USB multiseat and how to fit it in. Here&#39;s the thoughts.</font><div>
<font class="Apple-style-span" face="arial, helvetica, sans-serif"><br></font></div><div><font class="Apple-style-span" face="arial, helvetica, sans-serif">The current plug and play usb seat demos are using GDM &lt;= 2.20 and launching multiple independent X servers via  gdmdynamic from within udev rules, using the USB topology to automatically know which displays, keyboards, and mice (and other devices) go together.  To get a more visceral image of how the plug and play terminals behave without needing devices, there will be a video from plumbers up from the conference organizers soon.  People were pretty excited about how slick it could be if it &quot;just worked&quot; out of the box with the distros.<br>
</font><div><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br></font></div><div><font class="Apple-style-span" face="arial, helvetica, sans-serif">So now we need to map this onto the new ConsoleKit&#39;s dynamic seats mechanism, etc.</font></div>
<div><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br></font></div><div><font class="Apple-style-span" face="arial, helvetica, sans-serif">David Zeuthen, Kay Sievers, Lennart Poettering, </font><span class="Apple-style-span" style="font-size: 13px; border-collapse: collapse; color: rgb(68, 68, 68); "><font class="Apple-style-span" face="arial, helvetica, sans-serif">Kristian Høgsberg, and others discussed alternatives, and everyone seemed generally aligned with a simple approach.  I&#39;ll try to capture it here -- if anyone has any comments or corrections, they&#39;ve very welcome. I&#39;ve likely missed or mis-conveyed key elements.</font></span></div>
<div><font class="Apple-style-span" color="#444444"><span class="Apple-style-span" style="border-collapse: collapse;"><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br></font></span></font></div><div>
<font class="Apple-style-span" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="font-size: 13px; "></span></font><font class="Apple-style-span" color="#444444"><span class="Apple-style-span" style="border-collapse: collapse;"><b><font class="Apple-style-span" face="arial, helvetica, sans-serif">Proposal</font></b><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br>
</font></span></font><div><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br></font></div><div><font class="Apple-style-span" face="arial, helvetica, sans-serif">Define a udev property called ID_SEAT(1) which is applied to every device and is meant to map 1-1 with ConsoleKit&#39;s SEAT_ID and </font><span class="Apple-style-span" style="font-size: 13px; color: rgb(51, 51, 51); white-space: pre; "><font class="Apple-style-span" face="arial, helvetica, sans-serif">ck-seat-tool&#39;s --seat-id parameter. Add a udev rule which assigns all hardware devices to the default/primary seat(2). Later udev rules can then re-assign devices to another unique seat id if they want, e.g. if a USB terminal (display, keyboard, mouse, ...) is found. This udev rule work can be safely committed at any time, in preparation for the other pieces.</font></span></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br></span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">Later udev rules may then set permissions on devices to a group matching the seat ID.</span></font></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br></span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">GDM/ConsoleKit will pass the seat ID to X (does it already?) and, upon user login/flex-switch/logout, add and remove that user from the group matching their seat so they may have special access to their seat-attached devices.</span></font></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br></span></font></div><div><span class="Apple-style-span" style="font-size: 13px; color: rgb(51, 51, 51); white-space: pre; "><font class="Apple-style-span" face="arial, helvetica, sans-serif">When X is updated to use libudev(3), its auto detect/enable devices mechanisms will use the udev tree and properties to only autoconfigure devices on the seat it is assigned, solving the problem we have today that the primary seat grabs all devices.</font></span></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br></span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">That&#39;s the big pieces.  Thoughts? Better/corrected ideas?  Major unanswered questions?</span></font></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br></span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">Thanks!</span></font></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">Bernie</span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br>
</span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">Notes:</span></font></div><div><font class="Apple-style-span" color="#333333"><span class="Apple-style-span" style="white-space: pre;"><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br>
</font></span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">(1) udev has a bit of tradition of ID_this and ID_that. Would it be better still to call it SEAT_ID?</span></font></div>
<div><font class="Apple-style-span" color="#333333"><span class="Apple-style-span" style="white-space: pre;"><font class="Apple-style-span" face="arial, helvetica, sans-serif">(2) ConsoleKit currently calls this default seat &quot;StaticSeat1&quot;.  To avoid any confusing connotations/conflicts as we start interpreting the meaning of this in the X and udev worlds, it might be better to simply call this seat &quot;DefaultSeat&quot;, and have the udev default name be the same.</font></span></font></div>
<div><font class="Apple-style-span" color="#333333"><span class="Apple-style-span" style="white-space: pre;"><font class="Apple-style-span" face="arial, helvetica, sans-serif">(3) At XDC, the consensus (with much discussion/concern) seemed to be that there&#39;s no better alternative than replacing Hal with libudev.</font></span></font></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br></span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">Two relevant checkins from Halton which are close to this direction:</span></font></div>
<div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;"><br></span></font></div><div><font class="Apple-style-span" color="#333333" face="arial, helvetica, sans-serif"><span class="Apple-style-span" style="white-space: pre;">ConsoleKit: <span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: arial; white-space: normal; "><a href="http://cgit.freedesktop.org/ConsoleKit/commit/?h=multi-seat&amp;id=f9de25b48fea80f4334d9f1f9c4e594f14b9cf8c">http://cgit.freedesktop.org/ConsoleKit/commit/?h=multi-seat&amp;id=f9de25b48fea80f4334d9f1f9c4e594f14b9cf8c</a></span></span></font></div>
<div>GDM: <a href="http://git.gnome.org/cgit/gdm/commit/?h=display-configuration&amp;id=ff0b34677e7eb3aecdd10b08e50daddec6ed3abb">http://git.gnome.org/cgit/gdm/commit/?h=display-configuration&amp;id=ff0b34677e7eb3aecdd10b08e50daddec6ed3abb</a></div>
<div><br><div class="gmail_quote">On Fri, Sep 18, 2009 at 10:33 AM, Bernie Thompson <span dir="ltr">&lt;<a href="mailto:bernie@plugable.com">bernie@plugable.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi All,<br><br>I&#39;m emailing about some peripheral work that&#39;s happening on recent distros, but not yet integrated with the latest ConsoleKit work, but hopefully will ultimately.<br><br>It&#39;s support for USB seats that automatically launch gdmdynamic instances on arrival via udev rules.  Background and all the code to do it are at <a href="http://libdlo.freedesktop.org/wiki/MultiSeatTerminal" target="_blank">http://libdlo.freedesktop.org/wiki/MultiSeatTerminal</a><br>

<br>This type of solution is going to be demoed and discussed at a Birds of a Feather session at next week&#39;s Linux Plumbers conference: <a href="http://linuxplumbersconf.org/ocw/proposals/110" target="_blank">http://linuxplumbersconf.org/ocw/proposals/110</a><a href="mailto:consolekit@lists.freedesktop.org" target="_blank"></a>  This session is being held Wed afternoon: <a href="http://linuxplumbersconf.org/2009/schedule/" target="_blank">http://linuxplumbersconf.org/2009/schedule/</a><br>

<br></blockquote></div></div></div></div>