public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/4] scsi: st: scsi_error: More reset patches
@ 2025-01-20 19:49 Kai Mäkisara
  2025-01-20 19:49 ` [PATCH v3 1/4] scsi: st: Restore some drive settings after reset Kai Mäkisara
                   ` (5 more replies)
  0 siblings, 6 replies; 14+ messages in thread
From: Kai Mäkisara @ 2025-01-20 19:49 UTC (permalink / raw)
  To: linux-scsi, jmeneghi
  Cc: martin.petersen, James.Bottomley, loberman, Kai Mäkisara

The first patch re-applies after device reset some settings changed
by the user (partition, density, block size).

The second and third patch address the case where more than one ULD
access the same device. The Unit Attention (UA) sense data is sent only
to one ULD and the others miss it. The st driver needs to find out
if device reset or media change has happened.

The second patch adds counters for New Media and Power On/Reset (POR)
Unit Attentions to the scsi_device struct. The third one changes st
so that these are used: if the value in the scsi_device struct does
not match the one stored locally, the corresponding UA has happened.
Use of the was_reset flag has been removed.

The fourth patch adds a file to sysfs to tell the user if reads/writes
to a tape are blocked following a device reset.
---
Changes since V2:
- applies to 6.13 + patch "scsi: st: Regression fix: Don't set
  pos_unknown just after device recognition"
- the UA counters changed to u16 (suggested by Bart van Assche)
- the macros to use the counters moved from patch 2 to patch 3
  (suggested by Bart Van Assche)
- remove clearing was_reset in patch 3 and not in patch 1

Changes since V1:
- replace the patch removing was_reset handling with patches two and three
- add sysfs file reset_blocked

Kai Mäkisara (4):
  scsi: st: Restore some drive settings after reset
  scsi: scsi_error: Add counters for New Media and Power On/Reset UNIT
    ATTENTIONs
  scsi: st: scsi_device: Modify st.c to use the new scsi_error counters
  scsi: st: Add sysfs file reset_blocked

 Documentation/scsi/st.rst  |  5 +++
 drivers/scsi/scsi_error.c  | 12 +++++++
 drivers/scsi/st.c          | 73 +++++++++++++++++++++++++++++++++-----
 drivers/scsi/st.h          |  6 ++++
 include/scsi/scsi_device.h |  9 +++++
 5 files changed, 97 insertions(+), 8 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2025-02-10  2:59 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-01-20 19:49 [PATCH v3 0/4] scsi: st: scsi_error: More reset patches Kai Mäkisara
2025-01-20 19:49 ` [PATCH v3 1/4] scsi: st: Restore some drive settings after reset Kai Mäkisara
2025-01-30 18:13   ` John Meneghini
2025-01-20 19:49 ` [PATCH v3 2/4] scsi: scsi_error: Add counters for New Media and Power On/Reset UNIT ATTENTIONs Kai Mäkisara
2025-01-30 18:13   ` John Meneghini
2025-01-20 19:49 ` [PATCH v3 3/4] scsi: st: scsi_device: Modify st.c to use the new scsi_error counters Kai Mäkisara
2025-01-30 18:18   ` John Meneghini
2025-01-20 19:49 ` [PATCH v3 4/4] scsi: st: Add sysfs file reset_blocked Kai Mäkisara
2025-01-30 18:27   ` John Meneghini
2025-01-31 10:49     ` "Kai Mäkisara (Kolumbus)"
2025-01-31 19:48       ` John Meneghini
2025-02-01 15:11   ` [PATCH v3b 4/4] scsi: st: Add sysfs file position_lost_in_reset Kai Mäkisara
2025-02-03 22:53 ` [PATCH v3 0/4] scsi: st: scsi_error: More reset patches Martin K. Petersen
2025-02-10  2:58 ` Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox