OSDN Git Service

PCI/PTM: Preserve RsvdP bits in PTM Control register
authorBjorn Helgaas <bhelgaas@google.com>
Fri, 9 Sep 2022 20:25:02 +0000 (15:25 -0500)
committerBjorn Helgaas <bhelgaas@google.com>
Mon, 12 Sep 2022 20:29:47 +0000 (15:29 -0500)
commit2b89c22f2434b931b3cf22298ac5f5ec089e9ad1
treed6254a0d9d3baeecf68e21441ec5b06eb44ad6dc
parent91b12b2a100e977274d3c277a4ff2df0b7439e7d
PCI/PTM: Preserve RsvdP bits in PTM Control register

Even though only the low 16 bits of PTM Control are currently defined, the
register is 32 bits wide and the unused bits are RsvdP ("Reserved and
Preserved"), so software must preserve the values of those bits when
writing the register.

Update PTM Control reads and writes to use 32-bit accesses and preserve the
reserved bits on writes.

Link: https://lore.kernel.org/r/20220909202505.314195-7-helgaas@kernel.org
Tested-by: Rajvi Jingar <rajvi.jingar@linux.intel.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com>
drivers/pci/pcie/ptm.c