From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dmitry Torokhov Subject: Re: sound connector detection Date: Sun, 2 Jul 2006 22:48:35 -0400 Message-ID: <200607022248.36459.dtor@insightbb.com> References: <1151671786.13412.6.camel@localhost> <200607011609.59426.dtor@insightbb.com> <1151832510.5536.32.camel@localhost.localdomain> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0189343689==" Return-path: In-Reply-To: <1151832510.5536.32.camel@localhost.localdomain> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@lists.sourceforge.net Errors-To: alsa-devel-bounces@lists.sourceforge.net To: Richard Purdie Cc: Liam Girdwood , Linux Kernel list , linuxppc-dev list , linux-input , Johannes Berg , alsa-devel@lists.sourceforge.net List-Id: alsa-devel@alsa-project.org --===============0189343689== Content-Type: multipart/alternative; boundary="Boundary-00=_EWIqEeBHqzA5FH+" Content-Transfer-Encoding: 7bit Content-Disposition: inline --Boundary-00=_EWIqEeBHqzA5FH+ Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On Sunday 02 July 2006 05:28, Richard Purdie wrote: > One thing the input system does well is pass simple switch events to > userspace though its event devices. Not using the input system for > switch like events like these is going to result in code duplication. > I think that hotplug/uevent like mechanism would be better suited here. You want to monitor changes in system state and you do not really want to monitor myriad of devices but just latch onto one data feed and get all the data from it (unlike input devices where you might want to separate data coming from different devices). The following "event" might be a good starting point: struct system_change_event { struct timeval time; /* look for 32/64 bit issues */ __u16 type; __u16 code; __s32 value; char object_path[224]; }; Maybe we should start looking into connector or a pure netlink implementation. -- Dmitry --Boundary-00=_EWIqEeBHqzA5FH+ Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: 7bit

On Sunday 02 July 2006 05:28, Richard Purdie wrote:

> One thing the input system does well is pass simple switch events to

> userspace though its event devices. Not using the input system for

> switch like events like these is going to result in code duplication.

>

I think that hotplug/uevent like mechanism would be better suited here.

You want to monitor changes in system state and you do not really want

to monitor myriad of devices but just latch onto one data feed and get

all the data from it (unlike input devices where you might want to

separate data coming from different devices). The following "event"

might be a good starting point:

struct system_change_event {

struct timeval time; /* look for 32/64 bit issues */

__u16 type;

__u16 code;

__s32 value;

char object_path[224];

};

Maybe we should start looking into connector or a pure netlink implementation.

--

Dmitry

--Boundary-00=_EWIqEeBHqzA5FH+-- --===============0189343689== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 --===============0189343689== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Alsa-devel mailing list Alsa-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/alsa-devel --===============0189343689==-- From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from asav02.manage.insightbb.com (gateway.insightbb.com [74.128.0.19]) by ozlabs.org (Postfix) with ESMTP id B7343679E7 for ; Mon, 3 Jul 2006 12:48:59 +1000 (EST) From: Dmitry Torokhov To: Richard Purdie Subject: Re: sound connector detection Date: Sun, 2 Jul 2006 22:48:35 -0400 References: <1151671786.13412.6.camel@localhost> <200607011609.59426.dtor@insightbb.com> <1151832510.5536.32.camel@localhost.localdomain> In-Reply-To: <1151832510.5536.32.camel@localhost.localdomain> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="Boundary-00=_EWIqEeBHqzA5FH+" Message-Id: <200607022248.36459.dtor@insightbb.com> Cc: Liam Girdwood , Linux Kernel list , linuxppc-dev list , linux-input , Johannes Berg , alsa-devel@lists.sourceforge.net List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , --Boundary-00=_EWIqEeBHqzA5FH+ Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On Sunday 02 July 2006 05:28, Richard Purdie wrote: > One thing the input system does well is pass simple switch events to > userspace though its event devices. Not using the input system for > switch like events like these is going to result in code duplication. > I think that hotplug/uevent like mechanism would be better suited here. You want to monitor changes in system state and you do not really want to monitor myriad of devices but just latch onto one data feed and get all the data from it (unlike input devices where you might want to separate data coming from different devices). The following "event" might be a good starting point: struct system_change_event { struct timeval time; /* look for 32/64 bit issues */ __u16 type; __u16 code; __s32 value; char object_path[224]; }; Maybe we should start looking into connector or a pure netlink implementation. -- Dmitry --Boundary-00=_EWIqEeBHqzA5FH+ Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: 7bit

On Sunday 02 July 2006 05:28, Richard Purdie wrote:

> One thing the input system does well is pass simple switch events to

> userspace though its event devices. Not using the input system for

> switch like events like these is going to result in code duplication.

>

I think that hotplug/uevent like mechanism would be better suited here.

You want to monitor changes in system state and you do not really want

to monitor myriad of devices but just latch onto one data feed and get

all the data from it (unlike input devices where you might want to

separate data coming from different devices). The following "event"

might be a good starting point:

struct system_change_event {

struct timeval time; /* look for 32/64 bit issues */

__u16 type;

__u16 code;

__s32 value;

char object_path[224];

};

Maybe we should start looking into connector or a pure netlink implementation.

--

Dmitry

--Boundary-00=_EWIqEeBHqzA5FH+--