netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch -next] ixgbe: potential null dereference
@ 2010-07-27 10:05 Dan Carpenter
  2010-07-28  0:10 ` Jeff Kirsher
  0 siblings, 1 reply; 3+ messages in thread
From: Dan Carpenter @ 2010-07-27 10:05 UTC (permalink / raw)
  To: Jeff Kirsher
  Cc: Jesse Brandeburg, Bruce Allan, Alex Duyck, PJ Waskiewicz,
	John Ronciak, David S. Miller, Don Skidmore,
	Mallikarjuna R Chilakala, e1000-devel, netdev, kernel-janitors

The e_dev_err() macro dereferences "adapter" which is NULL here.

Signed-off-by: Dan Carpenter <error27@gmail.com>

diff --git a/drivers/net/ixgbe/ixgbe_main.c b/drivers/net/ixgbe/ixgbe_main.c
index 9203759..0360260 100644
--- a/drivers/net/ixgbe/ixgbe_main.c
+++ b/drivers/net/ixgbe/ixgbe_main.c
@@ -6549,8 +6549,8 @@ static int __devinit ixgbe_probe(struct pci_dev *pdev,
 			err = dma_set_coherent_mask(&pdev->dev,
 						    DMA_BIT_MASK(32));
 			if (err) {
-				e_dev_err("No usable DMA configuration, "
-					  "aborting\n");
+				dev_err(&pdev->dev,
+					"No usable DMA configuration, aborting\n");
 				goto err_dma;
 			}
 		}
@@ -6560,7 +6560,8 @@ static int __devinit ixgbe_probe(struct pci_dev *pdev,
 	err = pci_request_selected_regions(pdev, pci_select_bars(pdev,
 	                                   IORESOURCE_MEM), ixgbe_driver_name);
 	if (err) {
-		e_dev_err("pci_request_selected_regions failed 0x%x\n", err);
+		dev_err(&pdev->dev,
+			"pci_request_selected_regions failed 0x%x\n", err);
 		goto err_pci_reg;
 	}
 

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

end of thread, other threads:[~2010-07-28  3:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-27 10:05 [patch -next] ixgbe: potential null dereference Dan Carpenter
2010-07-28  0:10 ` Jeff Kirsher
2010-07-28  3:48   ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).