public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* qla_wxyz pci_set_mwi question
@ 2007-04-12  5:15 Randy Dunlap
  2007-04-12 17:20 ` Andrew Vasquez
  0 siblings, 1 reply; 9+ messages in thread
From: Randy Dunlap @ 2007-04-12  5:15 UTC (permalink / raw)
  To: scsi, PCI; +Cc: linux-driver, gregkh


Both scsi/qla2xxx/qla_init.c and scsi/qla4xxx/ql4_init.c use pci_set_mwi()
like this:


	mwi = 0;
	if (pci_set_mwi(ha->pdev))
		mwi = PCI_COMMAND_INVALIDATE;

and then go on to set the PCI_COMMAND "word" based on that value.

I don't quite get it.  pci_set_mwi() returns 0 for success or
negative for error... so if pci_set_mwi() fails, the qla init
code still tries to set the PCI_COMMAND_INVALIDATE bit in the
PCI_COMMAND word?  The logic looks inverted to me.  What am I
overlooking?

Thanks.
---
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2007-05-03 17:45 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-04-12  5:15 qla_wxyz pci_set_mwi question Randy Dunlap
2007-04-12 17:20 ` Andrew Vasquez
2007-04-12 18:53   ` Matthew Wilcox
2007-04-12 19:37     ` Andrew Vasquez
2007-04-12 20:04       ` Matthew Wilcox
2007-04-13  2:34         ` Benjamin Herrenschmidt
2007-04-13  2:40           ` Randy Dunlap
2007-04-13  2:43             ` Benjamin Herrenschmidt
2007-05-03 17:44         ` Andrew Vasquez

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox