mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 02:21:52 +09:00
mwifiex: Add missing endian conversion.
commit 83e612f632 upstream.
Both type and pkt_len variables are in host endian and these should be in
Little Endian in the payload.
Signed-off-by: Tomasz Moń <desowin@gmail.com>
Acked-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
5c2c155d70
commit
558c62c2c0
@@ -1441,8 +1441,8 @@ static int mwifiex_sdio_host_to_card(struct mwifiex_adapter *adapter,
|
||||
/* Allocate buffer and copy payload */
|
||||
blk_size = MWIFIEX_SDIO_BLOCK_SIZE;
|
||||
buf_block_len = (pkt_len + blk_size - 1) / blk_size;
|
||||
*(u16 *) &payload[0] = (u16) pkt_len;
|
||||
*(u16 *) &payload[2] = type;
|
||||
*(__le16 *)&payload[0] = cpu_to_le16((u16)pkt_len);
|
||||
*(__le16 *)&payload[2] = cpu_to_le16(type);
|
||||
|
||||
/*
|
||||
* This is SDIO specific header
|
||||
|
||||
Reference in New Issue
Block a user