Search Linux Wireless

[PATCH 23/35] Simplify at76_get_mib_mdomain()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The "error" label is not needed.

Signed-off-by: Pavel Roskin <proski@xxxxxxx>
---

 drivers/net/wireless/at76_usb.c |   10 ++++------
 1 files changed, 4 insertions(+), 6 deletions(-)


diff --git a/drivers/net/wireless/at76_usb.c b/drivers/net/wireless/at76_usb.c
index 4ad3173..0873111 100644
--- a/drivers/net/wireless/at76_usb.c
+++ b/drivers/net/wireless/at76_usb.c
@@ -1277,15 +1277,13 @@ static int at76_get_mib_mdomain(struct at76_priv *priv, struct mib_mdomain *val)
 
 	ret = at76_get_mib(priv->udev, MIB_MDOMAIN, mdomain,
 			   sizeof(struct mib_mdomain));
-	if (ret < 0) {
+	if (ret < 0)
 		err("%s: at76_get_mib failed: %d", priv->netdev->name, ret);
-		goto error;
-	}
-
-	memcpy(val, mdomain, sizeof(*val));
+	else
+		memcpy(val, mdomain, sizeof(*val));
 
-error:
 	kfree(mdomain);
+
 exit:
 	return ret;
 }
-
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux