summaryrefslogtreecommitdiff
path: root/drivers/nfc/microread/i2c.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/nfc/microread/i2c.c')
-rw-r--r--drivers/nfc/microread/i2c.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/nfc/microread/i2c.c b/drivers/nfc/microread/i2c.c
index 386cc61d95b9..b668b7b9a61e 100644
--- a/drivers/nfc/microread/i2c.c
+++ b/drivers/nfc/microread/i2c.c
@@ -75,7 +75,7 @@ static void microread_i2c_add_len_crc(struct sk_buff *skb)
for (i = 0; i < skb->len; i++)
crc = crc ^ skb->data[i];
- *(u8 *)skb_put(skb, 1) = crc;
+ skb_put_u8(skb, crc);
}
static void microread_i2c_remove_len_crc(struct sk_buff *skb)
@@ -173,7 +173,7 @@ static int microread_i2c_read(struct microread_i2c_phy *phy,
goto flush;
}
- *(u8 *)skb_put(*skb, 1) = len;
+ skb_put_u8(*skb, len);
r = i2c_master_recv(client, skb_put(*skb, len), len);
if (r != len) {