patch-1.3.46 linux/drivers/scsi/sg.c

Next file: linux/fs/Makefile
Previous file: linux/drivers/scsi/scsicam.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.45/linux/drivers/scsi/sg.c linux/drivers/scsi/sg.c
@@ -215,7 +215,7 @@
 	if (filp->f_flags & O_NONBLOCK)
 	{
 	    restore_flags(flags);
-	    return -EWOULDBLOCK;
+	    return -EAGAIN;
 	}
 	interruptible_sleep_on(&device->read_wait);
 	if (current->signal & ~current->blocked)
@@ -323,7 +323,7 @@
     while(device->pending)
     {
 	if (filp->f_flags & O_NONBLOCK)
-	    return -EWOULDBLOCK;
+	    return -EAGAIN;
 #ifdef DEBUG
 	printk("sg_write: sleeping on pending request\n");
 #endif     
@@ -392,7 +392,7 @@
 	wake_up(&device->write_wait);
 	sg_free(device->buff,device->buff_len);
 	device->buff = NULL;
-	return -EWOULDBLOCK;
+	return -EAGAIN;
     } 
 #ifdef DEBUG
     printk("device allocated\n");

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this