> > drivers/usb/misc/speedtouch.c
>
> Ah good, you're using one that the source is available for :)
> I think the developer has said it will work on SMP machines, but what
> problems are you having, and have you asked the author of the code?

I am not sure about the ATM interface, but this driver has some
problems even on UP.

Details:
void udsl_atm_sar_stop (void)
Very ingenious. Look at khubd to see it done properly.

udsl_usb_send_data_complete
Is in interrupt. You must use GFP_ATOMIC (patch included)

udsl_usb_cancelsends
unlinking URBs under spinlock must be done asynchronously

udsl_usb_send_data
may be used with NFS. Use GFP_NOIO

udsl_usb_data_receive
Is in interrupt: usb_clear_halt - not allowed because it sleeps

udsl_usb_data_exit
                if (ctx->urb->status == -EINPROGRESS)
                        usb_unlink_urb (ctx->urb);
Race condition. It may miss some URBs

        Regards
                Oliver

You can import this changeset into BK by piping this whole message to:
'| bk receive [path to repository]' or apply the patch as usual.

===================================================================


[EMAIL PROTECTED], 2002-12-16 09:16:57+01:00, [EMAIL PROTECTED]
  - memory allocation deadlock fix


 speedtouch.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


diff -Nru a/drivers/usb/misc/speedtouch.c b/drivers/usb/misc/speedtouch.c
--- a/drivers/usb/misc/speedtouch.c     Mon Dec 16 09:29:50 2002
+++ b/drivers/usb/misc/speedtouch.c     Mon Dec 16 09:29:50 2002
@@ -598,7 +598,7 @@
                       (unsigned char *) ctx->skb->data,
                       ctx->skb->len, udsl_usb_send_data_complete, ctx);
 
-       err = usb_submit_urb (urb, GFP_KERNEL);
+       err = usb_submit_urb (urb, GFP_ATOMIC);
 
        PDEBUG ("udsl_usb_send_data_completion (send packet %p with length %d), retval 
= %d\n",
                ctx->skb, ctx->skb->len, err);
@@ -747,7 +747,7 @@
                       usb_rcvbulkpipe (instance->usb_dev, UDSL_ENDPOINT_DATA_IN),
                       (unsigned char *) ctx->skb->data,
                       UDSL_RECEIVE_BUFFER_SIZE, udsl_usb_data_receive, ctx);
-       usb_submit_urb (urb, GFP_KERNEL);
+       usb_submit_urb (urb, GFP_ATOMIC);
        return;
 };
 

===================================================================


This BitKeeper patch contains the following changesets:
1.1112
## Wrapped with gzip_uu ##


begin 664 bkpatch9260
M'XL(`/Z._3T``[U476_3,!1]KG_%E?8"&DE\G3A?**BCA3$!6E78<Y4/IXW2
MQ)6=P";EQ^,T4M$D5#9`6)9O[)M[?,_)42[@3@L5S^2^^B84N8`/4G=F*UK9
M"GLG&[&OVO[>EFIKDFLI3=(9CYVIPLEJJU-":&>K&"?FG57:Y3LP*1W/T'9/
M)]W#0<2S];OKNT]7:T*2!!:[M-V*+Z*#)"%9/2]ZL;=K)=/=>-UP2@^,4D1D
MG+K<1SZPT'6]`7V:%>:Q8$%49GY$#J*KTW;>&S[:UK)7N2@-CK!;`_$(C"%#
MCZ+'F3=P#**(+`'M\0J@S$$S?:!1C'[,@TN*,:4PL9W_2A>X1+`H>0M_3V%!
M<K"@$8U4#Y#N]S)/NTJV4(BT,)L:RNJ>?`3N8N21U4\!B?7,00A-*7D#6R6V
M\ZG?7#9#H4:6VNEUYC25SAU]$*+H9)^;_%$Y&K)@C"P<J,<#?Q@)E*:=R`LC
MRHORG%)/P#=?QJ<A<H8#4I=Y1Z.<+1O-\^]I/!_2=$XQHBZRL7.739ZBCQW%
M8X9/<10#B_U/1TU:WX*EOA^G<<CJO.Q_8+FE3Q&0W$QA)I2"!`SX1O=94W6;
M7F7PPBROX/K]:G/U]?;SS>+E:[(,.!W+IC#[?<'IEY/O1%[KODDBHP;W0T9^
)`,-'K"SO!```
`
end



-------------------------------------------------------
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to