diff options
author | Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com> | 2025-07-28 21:51:05 +0530 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2025-08-07 11:14:23 -0600 |
commit | b32dda34506b4f486bc803d0c7251f987edd2455 (patch) | |
tree | dbe7c1f03c168f16c8bf01987b90a75db43404c0 /drivers/timer/ae3xx_timer.c | |
parent | e652183ca06d3795052df389992533fd539d8dee (diff) |
drivers: scsi: fix inaccurate block count reporting in scsi operations
The 'blks' variable in scsi_read/write/erase functions is updated
regardless of pass/fail of the scsi operation . If the scsi operation
fails, 'blkcnt' is updated using an incorrect value of 'blks'. This
wrong 'blkcnt' is returned to the caller and it assumes all blocks were
processed correctly.
Fix this by updating the 'blks' variable only if the scsi operation
succeeds.
Signed-off-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Signed-off-by: Varadarajan Narayanan <quic_varada@quicinc.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Diffstat (limited to 'drivers/timer/ae3xx_timer.c')
0 files changed, 0 insertions, 0 deletions