Skip to content

Commit

Permalink
wl1251: use skb_trim to make skb shorter
Browse files Browse the repository at this point in the history
the current code is directly setting skb->len, which is not correct and
brings problems with HAVE_EFFICIENT_UNALIGNED_ACCESS enabled in config

Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Ivaylo Dimitrov authored and John W. Linville committed Mar 3, 2014
1 parent 4c59ff2 commit 7661e97
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/wireless/ti/wl1251/rx.c
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ static void wl1251_rx_body(struct wl1251 *wl,
wl1251_mem_read(wl, rx_packet_ring_addr, rx_buffer, length);

/* The actual length doesn't include the target's alignment */
skb->len = desc->length - PLCP_HEADER_LENGTH;
skb_trim(skb, desc->length - PLCP_HEADER_LENGTH);

fc = (u16 *)skb->data;

Expand Down

0 comments on commit 7661e97

Please sign in to comment.