Commit f2ea0c35 authored by Simon Horman's avatar Simon Horman Committed by David S. Miller

nfc: nxp-nci: store __be16 value in __be16 variable

Use a __be16 variable to store the big endian value of header in
nxp_nci_i2c_fw_read().

Flagged by Sparse as:

 .../i2c.c:113:22: warning: cast to restricted __be16

No functional changes intended.
Compile tested only.
Signed-off-by: default avatarSimon Horman <horms@kernel.org>
Reviewed-by: default avatarSridhar Samudrala <sridhar.samudrala@intel.com>
Reviewed-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent b803d1fd
...@@ -97,8 +97,8 @@ static int nxp_nci_i2c_fw_read(struct nxp_nci_i2c_phy *phy, ...@@ -97,8 +97,8 @@ static int nxp_nci_i2c_fw_read(struct nxp_nci_i2c_phy *phy,
struct sk_buff **skb) struct sk_buff **skb)
{ {
struct i2c_client *client = phy->i2c_dev; struct i2c_client *client = phy->i2c_dev;
u16 header;
size_t frame_len; size_t frame_len;
__be16 header;
int r; int r;
r = i2c_master_recv(client, (u8 *) &header, NXP_NCI_FW_HDR_LEN); r = i2c_master_recv(client, (u8 *) &header, NXP_NCI_FW_HDR_LEN);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment