new aic7xxx 6.2.5 extra hunks
Hi,
I was trying the new 6.2.5 version of AIC driver from Justin Gibss, and as always it includes changes to the generic SCSI layer.
Are this really needed ????? (some look just cosmetic if -> switch...)
Hunks follow:
drivers/scsi/scsi_error.c renamed from drivers/scsi/scsi_error.c.orig +1 -7
@@ -1009,13 +1009,7 @@ SCpnt->flags &= ~IS_RESETTING ; goto maybe_retry; } -/* -* Examine the sense data to figure out how to proceed from here. -* If there is no sense data, we will be forced into the error -* handler thread, where we get to examine the thing in a lot more -* detail. -*/ -return scsi_check_sense (SCpnt); +return SUCCESS ;default :return FAILED ; }
drivers/scsi/sd.c renamed from drivers/scsi/sd.c.orig +25 -6
@@ -595,6 +595,7 @@int this_count = SCpnt->bufflen >>9 ;int good_sectors = (result ==0 ? this_count :0 );int block_sectors =1 ; +long error_sector;SCSI_LOG_HLCOMPLETE (1 ,sd_devname (DEVICE_NR (SCpnt->request.rq_dev), nbuff));
@@ -611,10 +612,11 @@*/ /* An error occurred */ -if (driver_byte (result) !=0 ) { -/* Sense data is valid */ -if (SCpnt->sense_buffer[0 ] ==0xF0 && SCpnt->sense_buffer[2 ] ==MEDIUM_ERROR ) { -long error_sector = (SCpnt->sense_buffer[3 ] <<24 ) | +if (driver_byte (result) !=0 &&/* An error occured */ + SCpnt->sense_buffer[0 ] ==0xF0 ) {/* Sense data is valid */ +switch (SCpnt->sense_buffer[2 ]) { +case MEDIUM_ERROR : + error_sector = (SCpnt->sense_buffer[3 ] <<24 ) | (SCpnt->sense_buffer[4 ] <<16 ) | (SCpnt->sense_buffer[5 ] <<8 ) | SCpnt->sense_buffer[6 ];
@@ -647,13 +649,30 @@ good_sectors = error_sector - SCpnt->request.sector;if (good_sectors <0 || good_sectors >= this_count) good_sectors =0 ; - } -if (SCpnt->sense_buffer[2 ] ==ILLEGAL_REQUEST ) { +break ; + +case RECOVERED_ERROR : +/* +* An error occured, but it recovered. Inform the +* user, but make sure that it's not treated as a +* hard error. +*/ +print_sense ("sd" , SCpnt); + result =0 ; + SCpnt->sense_buffer[0 ] =0x0 ; + good_sectors = this_count; +break ; + +case ILLEGAL_REQUEST :if (SCpnt->device->ten ==1 ) {if (SCpnt->cmnd[0 ] ==READ_10 || SCpnt->cmnd[0 ] ==WRITE_10 ) SCpnt->device->ten =0 ; } +break ; + +default : +break ; } }/*
drivers/scsi/sr.c renamed from drivers/scsi/sr.c.orig +47 -27
86 lines not on this page · raw message
Signature · 4 lines
J.A. Magallon # Let the source be with you... mailto:[email protected] Mandrake Linux release 8.2 (Cooker) for i586 Linux werewolf 2.4.18-pre9-slb2 #1 SMP Tue Feb 12 20:16:13 CET 2002 i686