Re: [Bluez-devel] Re: multi rfcomm/sco connection

Marcel Holtmann
2004-11-14T16:34:57Z

Hi Lars,

> | The ioctl() way is a no go. You have everything you must know inside the
> | kernel. You know the number of SCO connections and the voice setting and
> | the driver must be able to deal with this by itself.
>
> Question is, how can we handle the endpoint selection when we can't use
> usb_set_interface() in the notify function? Or to be more precisly, when.
>
> Next question is what happens to not-yet-send packages, I think we must
> empty all queues before we can use usb_set_interface.

you must stop the current ISOC URBs and then change the alternate
setting and then submit them again. Even more you shouldn't started them
in the open routine. Only start them when a SCO link is created.

> What function in the kernel driver would you use to add this? maybe the
> send functions? We could set a flag "change endpoint to..." in notify
> and apply the change when queues are empty - and reject/hold new send
> urbs until we were able to change the endpoint setting.

I don't think that this will more, because you are in the wrong context
too. However check with in_interrupt() and do this always on a SMP and
preempt enabled kernel.

Regards

Marcel

-------------------------------------------------------
This SF.Net email is sponsored by: InterSystems CACHE
FREE OODBMS DOWNLOAD - A multidimensional database that combines
robust object and relational technologies, making it a perfect match
for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net