Skip to contentSkip to conversation

scsi: vmw_pvscsi: Use str_enabled_disabled() helper in pvscsi_probe()

PATCH RESEND Superseded Thorsten Blum 1 participant 1 message Mar 11, 2025

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 scsi: vmw_pvscsi: Use str_enabled_disabled() helper in pvscsi_probe()

Remove hard-coded strings by using the str_enabled_disabled() helper function.

Use pr_debug() instead of printk(KERN_DEBUG) to silence a checkpatch warning.

---
 drivers/scsi/vmw_pvscsi.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/scsi/vmw_pvscsi.c +3 -2
index 32242d86cf5b..4927c6a33bd8 100644
@@ -25,6 +25,7 @@
 #include <linux/slab.h>
 #include <linux/workqueue.h>
 #include <linux/pci.h>
+#include <linux/string_choices.h>
 
 #include <scsi/scsi.h>
 #include <scsi/scsi_host.h>
@@ -1508,8 +1509,8 @@ static int pvscsi_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 		goto out_reset_adapter;
 
 	adapter->use_req_threshold = pvscsi_setup_req_threshold(adapter, true);
-	printk(KERN_DEBUG "vmw_pvscsi: driver-based request coalescing %sabled\n",
-	       adapter->use_req_threshold ? "en" : "dis");
+	pr_debug("vmw_pvscsi: driver-based request coalescing %s\n",
+		 str_enabled_disabled(adapter->use_req_threshold));
 
 	if (adapter->dev->msix_enabled || adapter->dev->msi_enabled) {
 		printk(KERN_INFO "vmw_pvscsi: using MSI%s\n",
Signature · 1 line
2.48.1