Skip to content

Commit

Permalink
libertas: Byteswap cmdptr->size in lbs_cmd()
Browse files Browse the repository at this point in the history
Bad Holger. Always test on big-endian machines, if it's little-endian
you need to be swapping to/from.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
David Woodhouse authored and David S. Miller committed Jan 28, 2008
1 parent ad9de29 commit 6228c0a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/wireless/libertas/cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -2072,7 +2072,7 @@ int lbs_cmd(struct lbs_private *priv,
/* Set sequence number, clean result, move to buffer */
adapter->seqnum++;
cmdptr->command = cpu_to_le16(command);
cmdptr->size = cmd_size + S_DS_GEN;
cmdptr->size = cpu_to_le16(cmd_size + S_DS_GEN);
cmdptr->seqnum = cpu_to_le16(adapter->seqnum);
cmdptr->result = 0;
memcpy(cmdptr->cmdresp, cmd, cmd_size);
Expand Down

0 comments on commit 6228c0a

Please sign in to comment.