Fix lpfc_parse_bg_err()'s use of do_div()
[firefly-linux-kernel-4.4.55.git] / drivers / scsi / lpfc / lpfc_scsi.c
index b1bd3fc7bae8293003f89168e17005a4440c0b4c..36fd2e75da1c0cbf4851468eae3fbaa8b1b3a648 100644 (file)
@@ -1394,7 +1394,7 @@ lpfc_parse_bg_err(struct lpfc_hba *phba, struct lpfc_scsi_buf *lpfc_cmd,
                 */
                cmd->sense_buffer[8] = 0;     /* Information */
                cmd->sense_buffer[9] = 0xa;   /* Add. length */
-               do_div(bghm, cmd->device->sector_size);
+               bghm /= cmd->device->sector_size;
 
                failing_sector = scsi_get_lba(cmd);
                failing_sector += bghm;