From: Takashi Iwai Subject: Re: RFC: Expose soundcard busid to userspace Date: Mon, 09 Jan 2006 17:34:53 +0100 Message-ID: References: <20060104172150.GA14752@vidsoft.de> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Return-path: In-Reply-To: <20060104172150.GA14752@vidsoft.de> Sender: alsa-devel-admin@lists.sourceforge.net Errors-To: alsa-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: Gregor Jasny Cc: alsa-devel@lists.sourceforge.net List-Id: alsa-devel@alsa-project.org At Wed, 4 Jan 2006 18:21:52 +0100, Gregor Jasny wrote: > > Hi, > > I've got the problem, that the order of my soundcards is different > after every reboot. I've tracked this problem down to udev and kernel > hotplugging. Setting an index for every used driver seems to help. > > The real problems are starting if I plug in some webcams with audio or > USB headsets. Because my computer is in a testing lab, this happens > very often. So the id's get mixed up nearly on every boot. I'd like > the idea of an stable identifier for a soundcard. The soundcard name > would work - but what happens if there are some soundcards with the same > name? It will be xxx_1. > So I thought the bus_id would be a (nearly) perfect id. It is > stable as long as you don't plug the soundcard in another pci or usb > port. It's an interresting idea. Maybe we need to extend the id parser of alsa-lib to accept busid, too? > The attached patches are a proof of concept. The problem I see are > old kernels that don't support the busid field. The current ioctl > does not zero the reserved space. So alsa-lib don't know if the > data at busid is just garbage or a busid. Another possible > implementation would be the introduction of another ioctl. We can check a protocol number to determine the capability. Takashi ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click