Am Samstag, 22. März 2003 21:53 schrieb Matthew Dharm: > I'm pretty much with Alan on this one. My personal style thinks that you > should log a message on entry to the function, log a different message if > there is more than 1 interface, and log a message with the result code if > the reset performed. > > Other than that, it looks good.
Very well. Here's logging. It fixes the old comments as well. 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], 2003-03-22 22:36:25+01:00, [EMAIL PROTECTED] - add logging to reset scsiglue.c | 13 ++++--------- 1 files changed, 4 insertions(+), 9 deletions(-) diff -Nru a/drivers/usb/storage/scsiglue.c b/drivers/usb/storage/scsiglue.c --- a/drivers/usb/storage/scsiglue.c Sat Mar 22 22:36:59 2003 +++ b/drivers/usb/storage/scsiglue.c Sat Mar 22 22:36:59 2003 @@ -209,17 +209,11 @@ return result; } -/* This resets the device port, and simulates the device - * disconnect/reconnect for all drivers which have claimed - * interfaces, including ourself. */ +/* This resets the device port */ +/* It refuses to work if there's more than one interface in + this device, so that other users are not affected. */ /* This is always called with scsi_lock(srb->host) held */ -/* FIXME: This needs to be re-examined in the face of the new - * hotplug system -- this will implicitly cause a detach/reattach of - * usb-storage, which is not what we want now. - * - * Can we just skip over usb-storage in the while loop? - */ static int usb_storage_bus_reset( Scsi_Cmnd *srb ) { struct us_data *us; @@ -244,6 +238,7 @@ US_DEBUGP("usb_reset_device returns %d\n", result); } else { result = -EBUSY; + US_DEBUGP("cannot reset a multiinterface device. failing to reset.\n"); } US_DEBUGP("bus_reset() complete\n"); =================================================================== This BitKeeper patch contains the following changesets: 1.1517 ## Wrapped with gzip_uu ## begin 664 bkpatch12882 M'XL(`'S7?#X``[546V_3,!1^KG_%T?8`;#3Q+6E35#1VT9A`HMKH&Q)RDY.+ MFL:[EMAIL PROTECTED]<?CI-(*8BKC%EF)[>]<OG/\.8>PM&AF(UU7=VC((;S5UODE-KK! MH-0;K*NF_1)H4WCP6FL/AOUVN/4(5^NQ,[EMAIL PROTECTED];'A%OM5`N+<&[EMAIL PROTECTED] M<5]O<3:ZOKA<OG]S3<A\#F>E:@J\00?S.5FM3[(6ZV!MM"K[A-T#W'%*&6,\ MHB**6=3QJ1"R8S%=97Z:\4F2K^*$;"F=/$;^QUB""LY90OVKDX++B)P#"UC$ M)D!%Z`?GP/E,Q#,>'5,VHQ3VQ(9C!F-*3N'[EMAIL PROTECTED]@"GP:!% M1]Y!SW1*%KNND?%O/H101<GK1XAFIB_/AJU=#2>I"@QM:JNB;C%(=^PE35C2 MT9A.9!=/4QJS))J*2"C*^+X>/2'!<"B<B9A+GR`2TT$B^_T>U\V_*&:OF)Y8 MC#]>27G'631)!H5)\9.^Y%/T)6&<_!]]>5D-K?X`8W,_#*^2Q2^Z_@>Z.^=> M'X)<<2;])SR"CV5EM\JVX$J$#.^J%.%6&P='86]QY3R>MQ9M?PGNM5E#E?>V M!I]9V&B#?J$:\/V"JG%H<I7V,[EMAIL PROTECTED]&_(E6-T;.M"]+_B`QH+RWHUVH/(< M4X=9T"?U)"<0>Y(R!D9&H^7-Y_.+T^7EXOE!JIK>?"`,"C9M[:I=TFVF`')5 CU=]?VN!3<_#BU>Z?F):8KFV[F<L\8],)S<@WCU-V&(`%```` ` end ------------------------------------------------------- This SF.net email is sponsored by:Crypto Challenge is now open! Get cracking and register here for some mind boggling fun and the chance of winning an Apple iPod: http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en _______________________________________________ [EMAIL PROTECTED] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel