Skip to content

Display EVPD pages in sysfs

Hannes Reinecke linux-scsi 6 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v9 Latest6 patches 6 repliesIn review
  2. v85 patches 14 repliesSuperseded
  3. v7 posting 2/23 patches 9 repliesSuperseded
Earlier versions · 3
VersionPostedPatchesRepliesStatus
v7 posting 1/23 patches15 repliesSuperseded
v63 patches0 repliesSuperseded
v52 patches3 repliesSuperseded

Changes to v8 from the cover letter

- Fixed 'vpg' spelling error
- Moved to binary attributes
- Implement VPD page refreshing by either calling 'rescan' or due to a SCSI sense event.

Patches in v9 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6scsi_sysfs: Implement 'is_visible' callbackdrivers/scsi/scsi_sysfs.c+93 -910 replies
2/6scsi: Return VPD page length in scsi_vpd_inquiry()drivers/scsi/scsi.c+10 -71 reply
3/6Add EVPD page 0x83 to sysfsdrivers/scsi/scsi.c drivers/scsi/scsi_scan.c drivers/scsi/scsi_sysfs.c +1 more+98 -10 replies
4/6Add EVPD page 0x80 to sysfsdrivers/scsi/scsi.c drivers/scsi/scsi_sysfs.c include/scsi/scsi_device.h+31 -10 replies
5/6ses: Use vpd information from scsi_devicedrivers/scsi/ses.c+10 -280 replies
6/6Invalidate VPD page datadrivers/scsi/scsi.c drivers/scsi/scsi_error.c drivers/scsi/scsi_scan.c +3 more+82 -275 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v9 yet.

Read the v9 thread

Cover letter [PATCHv9 0/6] Display EVPD pages in sysfs

Here's now v9 of my patch series to display VPD pages in sysfs.
Changes to v8:
- Fixed 'vpg' spelling error
- Moved to binary attributes
- Implement VPD page refreshing by either calling 'rescan' or due to a SCSI sense event.

So with this series all outstanding issues should be resolved. And even Bart should be happy now as the vpd information can be refreshed at any time.

Note, that with the move to binary sysfs attributes we lost the functionality to hide the vpd page attributes if those pages aren't supported.
I deliberately used the grouping functionality for the binary attribute here, otherwise it would introduce a race window during which the uevent was sent but no vpd page attribute was present.
If that turns out to be a problem we should be fixing the sysfs core to allow an 'is_visible' callback for binary attributes, too.

Hannes Reinecke (6):
scsi_sysfs: Implement 'is_visible' callback
scsi: Return VPD page length in scsi_vpd_inquiry() Add EVPD page 0x83 to sysfs
Add EVPD page 0x80 to sysfs
ses: Use vpd information from scsi_device Invalidate VPD page data

 drivers/scsi/scsi.c        | 149 ++++++++++++++++++++++++++++--
 drivers/scsi/scsi_error.c  |   1 +
 drivers/scsi/scsi_scan.c   |  10 ++-
 drivers/scsi/scsi_sysfs.c  | 220 ++++++++++++++++++++++++++-------------------
 drivers/scsi/ses.c         |  38 +++-----
 include/scsi/scsi_device.h |   7 ++
 6 files changed, 297 insertions(+), 128 deletions(-)
Signature · 1 line
1.7.12.4