Skip to contentSkip to conversation

fix swapped arguments in aic7xxx:ahc_find_pci_device

PATCH Dave Jones 2 participants 2 messages Sep 5, 2013

Subsystems (2)
lore
Share & tools
lore

Dave Jones

author
#0 lore raw

The prototype for ahc_9005_subdevinfo_valid shows that the caller has the arguments in the wrong order.

637 ahc_9005_subdevinfo_valid(uint16_t device, uint16_t vendor,
638 uint16_t subdevice, uint16_t subvendor)

drivers/scsi/aic7xxx/aic7xxx_pci.c +1 -1
index 6917b4f..22d5a94 100644
@@ -692,7 +692,7 @@ ahc_find_pci_device(ahc_dev_softc_t pci)
 	 * ID as valid.
 	 */
 	if (ahc_get_pci_function(pci) > 0
-	 && ahc_9005_subdevinfo_valid(vendor, device, subvendor, subdevice)
+	 && ahc_9005_subdevinfo_valid(device, vendor, subdevice, subvendor)
 	 && SUBID_9005_MFUNCENB(subdevice) == 0)
 		return (NULL);
 
#1 lore raw
Quoted 7 lines · Dave Jones

The prototype for ahc_9005_subdevinfo_valid shows that the caller has the arguments in the wrong order.

637 ahc_9005_subdevinfo_valid(uint16_t device, uint16_t vendor,
638 uint16_t subdevice, uint16_t subvendor)

Quoted 15 lines
drivers/scsi/aic7xxx/aic7xxx_pci.c +1 -2
index 6917b4f..22d5a94 100644
@@ -692,7 +692,7 @@ ahc_find_pci_device(ahc_dev_softc_t pci)
 	 * ID as valid.
 	 */
 	if (ahc_get_pci_function(pci) > 0
-	 && ahc_9005_subdevinfo_valid(vendor, device, subvendor, subdevice)
+	 && ahc_9005_subdevinfo_valid(device, vendor, subdevice, subvendor)
 	 && SUBID_9005_MFUNCENB(subdevice) == 0)
 		return (NULL);
 
--
Quoted 4 lines

To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Cheers,

Hannes

Signature · 8 lines
Dr. Hannes Reinecke		      zSeries & Storage
[email protected]			      +49 911 74053 688
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: J. Hawn, J. Guild, F. Imendörffer, HRB 16746 (AG Nürnberg)
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html