Subject: Re: Belkin Bluetooth vs aue vs ubt
To: Stephen Borrill <netbsd@precedence.co.uk>
From: Jason Thorpe <thorpej@shagadelic.org>
List: tech-kern
Date: 03/07/2007 13:15:47
On Mar 7, 2007, at 1:10 PM, Stephen Borrill wrote:
> On Wed, 7 Mar 2007, Jason Thorpe wrote:
>> On Mar 7, 2007, at 12:51 PM, Daniel Carosone wrote:
>>
>>
>>> On Wed, Mar 07, 2007 at 12:46:42PM -0800, Jason Thorpe wrote:
>>
>>>
>>>> Should be the other way around! ubt should avoid matching non-
>>
>>>
>>>> UDPROTO_BLUETOOTH devices!
>>
>>> No, that's not the problem - ubt doesn't get a chance because aue
>>
>>> grabs the device first (and presumably would also for a real aue
>>> with
>>
>>> the same product id's).
>>
>> Uh, no, that's not how autoconfig works.
>>
>> Autoconfig, in the direct configuration case (like what USB does)
>> gives everyone a chance and then takes the highest-priority match
>> (and if all return the same priority, takes the first one, I think).
>
> aue uses:
> #define UMATCH_VENDOR_PRODUCT 13
>
> ubt uses:
> #define UMATCH_IFACECLASS_IFACESUBCLASS_IFACEPROTO 5
>
> So aue will always win.
So either:
- aue should also match against class+subclass+proto first. It should
do affirmative matching rather than negative matching. I.e. "it is an
Ethernet" as opposed to "it is not a Bluetooth (or a storage device or
a bar code reader or a mouse or a ...)"
- Matches against against class+subclass+proto should probably match
higher than vendor+product. Matches against class+subclass+proto
+vendor+product should probably match higher than class+subclass+proto.
>
>
> --
> Stephen
-- thorpej