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

Commit 180be755 authored by David Woodhouse's avatar David Woodhouse Committed by David S. Miller
Browse files

libertas: remove unreachable code from process_rxed_802_11_packet()



The function is only ever called if we're in rtap mode. So the bit in it
which is conditional on rtap mode seems a little superfluous.

Signed-off-by: default avatarDavid Woodhouse <dwmw2@infradead.org>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 2eb188a1
Loading
Loading
Loading
Loading
+32 −43
Original line number Diff line number Diff line
@@ -355,13 +355,7 @@ static int process_rxed_802_11_packet(struct lbs_private *priv,
	       skb->len, sizeof(struct rxpd), skb->len - sizeof(struct rxpd));

	/* create the exported radio header */
	if (priv->monitormode == LBS_MONITOR_OFF) {
		/* no radio header */
		/* chop the rxpd */
		skb_pull(skb, sizeof(struct rxpd));
	}

	else {
	/* radiotap header */
	radiotap_hdr.hdr.it_version = 0;
	/* XXX must check this value for pad */
@@ -393,13 +387,8 @@ static int process_rxed_802_11_packet(struct lbs_private *priv,
			     __func__);
	}

		pradiotap_hdr =
		    (struct rx_radiotap_hdr *)skb_push(skb,
						     sizeof(struct
							    rx_radiotap_hdr));
		memcpy(pradiotap_hdr, &radiotap_hdr,
		       sizeof(struct rx_radiotap_hdr));
	}
	pradiotap_hdr = (void *)skb_push(skb, sizeof(struct rx_radiotap_hdr));
	memcpy(pradiotap_hdr, &radiotap_hdr, sizeof(struct rx_radiotap_hdr));

	/* Take the data rate from the rxpd structure
	 * only if the rate is auto