Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2043e1fd authored by Dan Carpenter's avatar Dan Carpenter Committed by Christoph Hellwig
Browse files

bnx2fc: fix an error code in _bnx2fc_create()



We should be returning an error code here instead of success.  Either
-ENODEV or -ENOMEM would work.  There is also a failure message in
printk().

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Acked-by: default avatarChad Dupuis <chad.dupuis@qlogic.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent b6829c72
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -2195,6 +2195,7 @@ static int _bnx2fc_create(struct net_device *netdev,
	interface = bnx2fc_interface_create(hba, netdev, fip_mode);
	if (!interface) {
		printk(KERN_ERR PFX "bnx2fc_interface_create failed\n");
		rc = -ENOMEM;
		goto ifput_err;
	}