* [patch 4/7] scsi/qla_os: replace schedule_timeout() with ssleep()
@ 2005-01-11 23:22 domen
2005-01-12 16:32 ` James Bottomley
0 siblings, 1 reply; 4+ messages in thread
From: domen @ 2005-01-11 23:22 UTC (permalink / raw)
To: James.Bottomley; +Cc: linux-scsi, domen, nacc
Any comments would be, as always, appreciated.
-Nish
Description: Use ssleep() instead of schedule_timeout() to guarantee the
task delays as expected. Change the values of the constants being used
appropriately. I left the arithmetic there as it was before, even though
it could be easily simplified away.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
Signed-off-by: Domen Puncer <domen@coderock.org>
---
kj-domen/drivers/scsi/qla2xxx/qla_os.c | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff -puN drivers/scsi/qla2xxx/qla_os.c~ssleep-drivers_scsi_qla2xxx_qla_os drivers/scsi/qla2xxx/qla_os.c
--- kj/drivers/scsi/qla2xxx/qla_os.c~ssleep-drivers_scsi_qla2xxx_qla_os 2005-01-10 18:00:26.000000000 +0100
+++ kj-domen/drivers/scsi/qla2xxx/qla_os.c 2005-01-10 18:00:26.000000000 +0100
@@ -885,8 +885,8 @@ qla2x00_queuecommand(struct scsi_cmnd *c
static int
qla2x00_eh_wait_on_command(scsi_qla_host_t *ha, struct scsi_cmnd *cmd)
{
-#define ABORT_POLLING_PERIOD HZ
-#define ABORT_WAIT_TIME ((10 * HZ) / (ABORT_POLLING_PERIOD))
+#define ABORT_POLLING_PERIOD 1000
+#define ABORT_WAIT_TIME ((10 * 1000) / ABORT_POLLING_PERIOD)
int found = 0;
int done = 0;
@@ -923,8 +923,7 @@ qla2x00_eh_wait_on_command(scsi_qla_host
spin_unlock_irq(ha->host->host_lock);
- set_current_state(TASK_UNINTERRUPTIBLE);
- schedule_timeout(ABORT_POLLING_PERIOD);
+ msleep(ABORT_POLLING_PERIOD);
spin_lock_irq(ha->host->host_lock);
_
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [patch 4/7] scsi/qla_os: replace schedule_timeout() with ssleep()
2005-01-11 23:22 [patch 4/7] scsi/qla_os: replace schedule_timeout() with ssleep() domen
@ 2005-01-12 16:32 ` James Bottomley
2005-01-12 23:43 ` Nishanth Aravamudan
0 siblings, 1 reply; 4+ messages in thread
From: James Bottomley @ 2005-01-12 16:32 UTC (permalink / raw)
To: domen; +Cc: SCSI Mailing List, nacc
On Wed, 2005-01-12 at 00:22 +0100, domen@coderock.org wrote:
> Description: Use ssleep() instead of schedule_timeout() to guarantee the
[...]
> - set_current_state(TASK_UNINTERRUPTIBLE);
> - schedule_timeout(ABORT_POLLING_PERIOD);
> + msleep(ABORT_POLLING_PERIOD);
The description doesn't match the code.
Also, the qla driver is maintained. You should cc
andrew.vasquez@qlogic.com (I know they don't make it easy, like having
an entry in the MAINTAINERS file or even an email address in the code).
James
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [patch 4/7] scsi/qla_os: replace schedule_timeout() with ssleep()
2005-01-12 16:32 ` James Bottomley
@ 2005-01-12 23:43 ` Nishanth Aravamudan
2005-01-14 16:50 ` Andrew Vasquez
0 siblings, 1 reply; 4+ messages in thread
From: Nishanth Aravamudan @ 2005-01-12 23:43 UTC (permalink / raw)
To: James Bottomley; +Cc: domen, SCSI Mailing List, andrew.vasquez
On Wed, Jan 12, 2005 at 10:32:11AM -0600, James Bottomley wrote:
> On Wed, 2005-01-12 at 00:22 +0100, domen@coderock.org wrote:
> > Description: Use ssleep() instead of schedule_timeout() to guarantee the
> [...]
> > - set_current_state(TASK_UNINTERRUPTIBLE);
> > - schedule_timeout(ABORT_POLLING_PERIOD);
> > + msleep(ABORT_POLLING_PERIOD);
>
> The description doesn't match the code.
>
> Also, the qla driver is maintained. You should cc
> andrew.vasquez@qlogic.com (I know they don't make it easy, like having
> an entry in the MAINTAINERS file or even an email address in the code).
Please find the corrected Description with this patch (and the appropriate CC).
Thanks!
-Nish
Description: Use msleep() instead of schedule_timeout() to guarantee the
task delays as expected. Change the values of the constants being used
appropriately. I left the arithmetic there as it was before, even though
it could be easily simplified away.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
Signed-off-by: Domen Puncer <domen@coderock.org>
---
kj-domen/drivers/scsi/qla2xxx/qla_os.c | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff -puN drivers/scsi/qla2xxx/qla_os.c~ssleep-drivers_scsi_qla2xxx_qla_os drivers/scsi/qla2xxx/qla_os.c
--- kj/drivers/scsi/qla2xxx/qla_os.c~ssleep-drivers_scsi_qla2xxx_qla_os 2005-01-10 18:00:26.000000000 +0100
+++ kj-domen/drivers/scsi/qla2xxx/qla_os.c 2005-01-10 18:00:26.000000000 +0100
@@ -885,8 +885,8 @@ qla2x00_queuecommand(struct scsi_cmnd *c
static int
qla2x00_eh_wait_on_command(scsi_qla_host_t *ha, struct scsi_cmnd *cmd)
{
-#define ABORT_POLLING_PERIOD HZ
-#define ABORT_WAIT_TIME ((10 * HZ) / (ABORT_POLLING_PERIOD))
+#define ABORT_POLLING_PERIOD 1000
+#define ABORT_WAIT_TIME ((10 * 1000) / ABORT_POLLING_PERIOD)
int found = 0;
int done = 0;
@@ -923,8 +923,7 @@ qla2x00_eh_wait_on_command(scsi_qla_host
spin_unlock_irq(ha->host->host_lock);
- set_current_state(TASK_UNINTERRUPTIBLE);
- schedule_timeout(ABORT_POLLING_PERIOD);
+ msleep(ABORT_POLLING_PERIOD);
spin_lock_irq(ha->host->host_lock);
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [patch 4/7] scsi/qla_os: replace schedule_timeout() with ssleep()
2005-01-12 23:43 ` Nishanth Aravamudan
@ 2005-01-14 16:50 ` Andrew Vasquez
0 siblings, 0 replies; 4+ messages in thread
From: Andrew Vasquez @ 2005-01-14 16:50 UTC (permalink / raw)
To: Nishanth Aravamudan; +Cc: James Bottomley, domen, SCSI Mailing List
On Wed, 2005-01-12 at 15:43 -0800, Nishanth Aravamudan wrote:
> On Wed, Jan 12, 2005 at 10:32:11AM -0600, James Bottomley wrote:
> > On Wed, 2005-01-12 at 00:22 +0100, domen@coderock.org wrote:
> > > Description: Use ssleep() instead of schedule_timeout() to guarantee the
> > [...]
> > > - set_current_state(TASK_UNINTERRUPTIBLE);
> > > - schedule_timeout(ABORT_POLLING_PERIOD);
> > > + msleep(ABORT_POLLING_PERIOD);
> >
> > The description doesn't match the code.
> >
> > Also, the qla driver is maintained. You should cc
> > andrew.vasquez@qlogic.com (I know they don't make it easy, like having
> > an entry in the MAINTAINERS file or even an email address in the code).
>
> Please find the corrected Description with this patch (and the appropriate CC).
> Thanks!
>
> -Nish
>
> Description: Use msleep() instead of schedule_timeout() to guarantee the
> task delays as expected. Change the values of the constants being used
> appropriately. I left the arithmetic there as it was before, even though
> it could be easily simplified away.
>
> Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
> Signed-off-by: Domen Puncer <domen@coderock.org>
ACK.
James, please add to your tree.
I'll forward over a diff to add an entry to the MAINTAINERS file in
another email.
Thanks,
Andrew Vasquez
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2005-01-14 16:50 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-01-11 23:22 [patch 4/7] scsi/qla_os: replace schedule_timeout() with ssleep() domen
2005-01-12 16:32 ` James Bottomley
2005-01-12 23:43 ` Nishanth Aravamudan
2005-01-14 16:50 ` Andrew Vasquez
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox