Skip to content

PCI/VPD: pci_vpd_size() cleanups

Bjorn Helgaas linux-pci 2 versions – Applied

Status from this message: I applied this to pci/vpd for v5.15.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest6 patches 6 repliesApplied
  2. v15 patches 11 repliesSuperseded

Changes in v2 from the cover letter

- Incorporate Heiner's patch to reject VPD if first byte is 0x00 or 0xff

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/6PCI/VPD: Correct diagnostic for VPD read failuredrivers/pci/vpd.c+2 -20 replies
2/6PCI/VPD: Check Resource Item Names against those valid for typedrivers/pci/vpd.c+6 -120 replies
3/6PCI/VPD: Treat initial 0xff as missing EEPROMdrivers/pci/vpd.c+8 -41 reply
4/6PCI/VPD: Reject resource tags with invalid sizedrivers/pci/vpd.c+11 -44 replies
5/6PCI/VPD: Don't check Large Resource Item Names for validitydrivers/pci/vpd.c+4 -190 replies
6/6PCI/VPD: Allow access to valid parts of VPD if some is invaliddrivers/pci/vpd.c+7 -20 replies

Reviews trailers per patch

All 6 patches have a Reviewed-by or Acked-by.

PatchHannes Reinecke
1/6R-b
2/6R-b
3/6R-b
4/6R-b
5/6R-b
6/6R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/6] PCI/VPD: pci_vpd_size() cleanups

From: Bjorn Helgaas <[email protected]>

The basic idea is to validate VPD resource *size* without validating the actual content, since the kernel really doesn't care about the content.

Thanks very much for the feedback on v1, and I'd be glad for any additional feedback.

Follow-up to:
https://lore.kernel.org/r/[email protected]

Changes since v1:
- Incorporate Heiner's patch to reject VPD if first byte is 0x00 or 0xff

    (https://lore.kernel.org/r/[email protected]/)

- Update size checks to reject resources that would extend past the maximum VPD size

Bjorn Helgaas (5):
PCI/VPD: Correct diagnostic for VPD read failure PCI/VPD: Check Resource Item Names against those valid for type PCI/VPD: Reject resource tags with invalid size PCI/VPD: Don't check Large Resource Item Names for validity PCI/VPD: Allow access to valid parts of VPD if some is invalid

Heiner Kallweit (1):
PCI/VPD: Treat initial 0xff as missing EEPROM

 drivers/pci/vpd.c | 55 +++++++++++++++++++++--------------------------
 1 file changed, 25 insertions(+), 30 deletions(-)
Signature · 1 line
2.25.1