summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2020-02-04 09:37:15 +1100
committerStephen Rothwell <sfr@canb.auug.org.au>2020-02-04 09:37:15 +1100
commit58b8e933830cadd8b0ec3b50fcd14a2b172a8252 (patch)
tree570d35c2fe375b34ee565b207bc9369519120030 /net
parent5b2c977c5b1f68696b957089853db5c5a0e4dd21 (diff)
parent1f008cfec5d529b30ca8da1a1f5fbbd457c10382 (diff)
downloadlinux-next-58b8e933830cadd8b0ec3b50fcd14a2b172a8252.tar.gz
Merge remote-tracking branch 'nfc-next/master'
# Conflicts: # drivers/nfc/st21nfca/se.c
Diffstat (limited to 'net')
-rw-r--r--net/nfc/netlink.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/nfc/netlink.c b/net/nfc/netlink.c
index eee0dddb7749..fd01a049708e 100644
--- a/net/nfc/netlink.c
+++ b/net/nfc/netlink.c
@@ -1213,7 +1213,8 @@ static int nfc_genl_fw_download(struct sk_buff *skb, struct genl_info *info)
u32 idx;
char firmware_name[NFC_FIRMWARE_NAME_MAXSIZE + 1];
- if (!info->attrs[NFC_ATTR_DEVICE_INDEX])
+ if (!info->attrs[NFC_ATTR_DEVICE_INDEX] ||
+ !info->attrs[NFC_ATTR_FIRMWARE_NAME])
return -EINVAL;
idx = nla_get_u32(info->attrs[NFC_ATTR_DEVICE_INDEX]);