nfc: constify several pointers to u8, char and sk_buff
Several functions receive pointers to u8, char or sk_buff but do not modify the contents so make them const. This allows doing the same for local variables and in total makes the code a little bit safer. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
4932c37878
commit
3df40eb3a2
@@ -266,7 +266,7 @@ struct sk_buff *nfc_alloc_send_skb(struct nfc_dev *dev, struct sock *sk,
|
||||
struct sk_buff *nfc_alloc_recv_skb(unsigned int size, gfp_t gfp);
|
||||
|
||||
int nfc_set_remote_general_bytes(struct nfc_dev *dev,
|
||||
u8 *gt, u8 gt_len);
|
||||
const u8 *gt, u8 gt_len);
|
||||
u8 *nfc_get_local_general_bytes(struct nfc_dev *dev, size_t *gb_len);
|
||||
|
||||
int nfc_fw_download_done(struct nfc_dev *dev, const char *firmware_name,
|
||||
@@ -280,7 +280,7 @@ int nfc_dep_link_is_up(struct nfc_dev *dev, u32 target_idx,
|
||||
u8 comm_mode, u8 rf_mode);
|
||||
|
||||
int nfc_tm_activated(struct nfc_dev *dev, u32 protocol, u8 comm_mode,
|
||||
u8 *gb, size_t gb_len);
|
||||
const u8 *gb, size_t gb_len);
|
||||
int nfc_tm_deactivated(struct nfc_dev *dev);
|
||||
int nfc_tm_data_received(struct nfc_dev *dev, struct sk_buff *skb);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user