Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1655493

[PATCH 3.16 003/212] adm80211: return an error if adm8211_alloc_rings() fails

From Ben Hutchings <ben@decadent.org.uk>
Newsgroups linux.kernel
Subject [PATCH 3.16 003/212] adm80211: return an error if adm8211_alloc_rings() fails
Date 2017-06-01 18:50 +0200
Message-ID <tNBsm-53m-33@gated-at.bofh.it> (permalink)
References <tNAwh-4oP-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


3.16.44-rc1 review patch.  If anyone has any objections, please let me know.

------------------

From: Dan Carpenter <dan.carpenter@oracle.com>

commit c705a6b3aa7804d7bc6660183f51e510c61dc807 upstream.

We accidentally return success when adm8211_alloc_rings() fails but we
should preserve the error code.

Fixes: cc0b88cf5ecf ("[PATCH] Add adm8211 802.11b wireless driver")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
[bwh: Backported to 3.16: adjust filename]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 drivers/net/wireless/adm8211.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- a/drivers/net/wireless/adm8211.c
+++ b/drivers/net/wireless/adm8211.c
@@ -1843,7 +1843,8 @@ static int adm8211_probe(struct pci_dev
 	priv->rx_ring_size = rx_ring_size;
 	priv->tx_ring_size = tx_ring_size;
 
-	if (adm8211_alloc_rings(dev)) {
+	err = adm8211_alloc_rings(dev);
+	if (err) {
 		printk(KERN_ERR "%s (adm8211): Cannot allocate TX/RX ring\n",
 		       pci_name(pdev));
 		goto err_iounmap;

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 3.16 000/212] 3.16.44-rc1 review Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 003/212] adm80211: return an error if adm8211_alloc_rings()  fails Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 006/212] MIPS: Clear ISA bit correctly in  get_frame_info() Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 023/212] Drivers: hv: vmbus: Raise retry/wait limits  in vmbus_post_msg() Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 008/212] MIPS: Fix get_frame_info() handling of  microMIPS function size Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 011/212] MIPS: Handle microMIPS jumps in the same way  as MIPS32/MIPS64 jumps Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 031/212] ASoC: rt5640: use msleep() for long delays Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 027/212] ext4: avoid deadlock when expanding inode size Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 004/212] iio: st_pressure: Fix data sign Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  [PATCH 3.16 001/212] mm/huge_memory.c: fix up "mm/huge_memory.c:  respect FOLL_FORCE/FOLL_COW for thp" backport Ben Hutchings <ben@decadent.org.uk> - 2017-06-01 18:50 +0200
  Re: [PATCH 3.16 000/212] 3.16.44-rc1 review Guenter Roeck <linux@roeck-us.net> - 2017-06-01 23:20 +0200

csiph-web