[Bug 212007] New: wrong timeout calculation in scsi device_handler (scsi_dh_emc.c and scsi_dh_rdac.c)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



https://bugzilla.kernel.org/show_bug.cgi?id=212007

            Bug ID: 212007
           Summary: wrong timeout calculation in scsi device_handler
                    (scsi_dh_emc.c and scsi_dh_rdac.c)
           Product: SCSI Drivers
           Version: 2.5
    Kernel Version: 5.11.2 (all kernels since 4.11)
          Hardware: All
                OS: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: Other
          Assignee: scsi_drivers-other@xxxxxxxxxxxxxxxxxxxx
          Reporter: t.wede@xxxxxxxxxxx
        Regression: No

Created attachment 295549
  --> https://bugzilla.kernel.org/attachment.cgi?id=295549&action=edit
patch to correct wrong timeout calculations in scsi device handler

scsi_dh_emc.c:
--------------

In scsi_dh_emc.c (line 34) CLARIION_TIMEOUT ist defined as (60 * HZ).

In send_trespass_cmd (lines 279 - 281) the following is calculated:

err = scsi_execute(sdev, cdb, DMA_TO_DEVICE, csdev->buffer, len, NULL,
                        &sshdr, CLARIION_TIMEOUT * HZ, CLARIION_RETRIES,
                        req_flags, 0, NULL);

The result is "(60 * HZ) * HZ".


scsi_dh_rdac.c:
---------------

In scsi_dh_rdac.c (line 55) RDAC_TIMEOUT is defined as (60 * HZ).

In send_mode_select (lines 558 - 566) the following is calculated:

        if (scsi_execute(sdev, cdb, DMA_TO_DEVICE, &h->ctlr->mode_select,
                        data_size, NULL, &sshdr, RDAC_TIMEOUT * HZ,
                        RDAC_RETRIES, req_flags, 0, NULL)) {
                err = mode_select_handle_sense(sdev, &sshdr);
                if (err == SCSI_DH_RETRY && retry_cnt--)
                        goto retry;
                if (err == SCSI_DH_IMM_RETRY)
                        goto retry;
        }

The result is "(60 * HZ) * HZ".

-- 
You may reply to this email to add a comment.

You are receiving this mail because:
You are watching the assignee of the bug.



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux