patch-1.3.22 linux/drivers/block/cdu31a.c

Next file: linux/drivers/block/cm206.c
Previous file: linux/drivers/block/blk.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.21/linux/drivers/block/cdu31a.c linux/drivers/block/cdu31a.c
@@ -625,7 +625,7 @@
    }
 
    current->state = TASK_INTERRUPTIBLE;
-   current->timeout = jiffies + 200;
+   current->timeout = jiffies + 2*HZ;
    schedule();
 
    do_sony_cd_cmd(SONY_READ_TOC_CMD, NULL, 0, res_reg, &res_size);
@@ -834,6 +834,7 @@
             result_buffer[0] = 0x20;
             result_buffer[1] = SONY_SIGNAL_OP_ERR;
             *result_size = 2;
+            restore_flags(flags);
             return;
          }
       }
@@ -887,7 +888,7 @@
    {
       num_retries++;
       current->state = TASK_INTERRUPTIBLE;
-      current->timeout = jiffies + 10; /* Wait .1 seconds on retries */
+      current->timeout = jiffies + HZ/10; /* Wait .1 seconds on retries */
       schedule();
       goto retry_cd_operation;
    }
@@ -2137,6 +2138,7 @@
       interruptible_sleep_on(&sony_wait);
       if (current->signal & ~current->blocked)
       {
+         restore_flags(flags);
          return -EAGAIN;
       }
    }

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