Re: [PATCH 1/1] race condition fixes for usb-serial - new attempt - for review
Oliver Neukum <[email protected]>
| Newsgroups | gmane.linux.usb.devel |
|---|---|
| Organization | Novell |
| Message-ID | <[email protected]> |
Am Samstag, 24. März 2007 03:47 schrieb John:
> +struct usb_serial *usb_serial_get_by_index_ex(unsigned index, int * return_reserved)
> {
> struct usb_serial *serial;
>
> spin_lock(&table_lock);
> serial = serial_table[index];
>
> + if(return_reserved) {
> + *return_reserved = test_bit(index, ports_reserved);
> + }
> +
No. Get a separate test function.
> @@ -123,11 +166,70 @@ static void return_serial(struct usb_ser
>
> spin_lock(&table_lock);
> for (i = 0; i < serial->num_ports; ++i) {
> - serial_table[serial->minor + i] = NULL;
> + if(unreserve_ports) {
> + __clear_bit(i, ports_reserved);
No. A separate function please.
Regards
Oliver
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel