Skip to contentSkip to conversation

nvme-pci: remove two deallocate zeroes quirks

PATCH In review Keith Busch 3 participants 3 messages Dec 2, 2024 – Dec 3, 2024 NVMe

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nvme-pci: remove two deallocate zeroes quirks

From: Keith Busch <[email protected]>

The quirk was initially used as a signal to set the discard_zeroes_data queue limit because there were some use cases that relied on that behavior. The queue limit no longer exists as every user of it has been converted to use the write zeroes operation instead.

The quirk now means to use a discard command as an alias to a write zeroes request. Two of the devices previously using the quirk support the write zeroes command directly, so these don't need or want to use discard when the desired operation is to write zeroes.

---
 drivers/nvme/host/pci.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/nvme/host/pci.c +1 -3
index 4c644bb7f0692..9535e35ef18a5 100644
@@ -3588,12 +3588,10 @@ static const struct pci_device_id nvme_id_table[] = {
 				NVME_QUIRK_DEALLOCATE_ZEROES, },
 	{ PCI_VDEVICE(INTEL, 0x0a54),	/* Intel P4500/P4600 */
 		.driver_data = NVME_QUIRK_STRIPE_SIZE |
-				NVME_QUIRK_DEALLOCATE_ZEROES |
 				NVME_QUIRK_IGNORE_DEV_SUBNQN |
 				NVME_QUIRK_BOGUS_NID, },
 	{ PCI_VDEVICE(INTEL, 0x0a55),	/* Dell Express Flash P4600 */
-		.driver_data = NVME_QUIRK_STRIPE_SIZE |
-				NVME_QUIRK_DEALLOCATE_ZEROES, },
+		.driver_data = NVME_QUIRK_STRIPE_SIZE, },
 	{ PCI_VDEVICE(INTEL, 0xf1a5),	/* Intel 600P/P3100 */
 		.driver_data = NVME_QUIRK_NO_DEEPEST_PS |
 				NVME_QUIRK_MEDIUM_PRIO_SQ |
Signature · 1 line
2.43.5
maintainer
#2 lore raw
Quoted 2 lines · Christoph Hellwig

I guess we actually do need it for the other two can can't remove it entirely?

Right, the other two are 1.0 spec devices that don't support the write zeroes commmand, so leveraging dataset management to get the same outcome is still desirable there.