mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-20 08:22:39 +00:00
NFC: 3.17 fixes
We have 3 NFC fixes for 3.17: - 2 potential build failures for ST21NFCA and ST21NFCB, triggered by a depmod dependenyc cycle. - One potential buffer overflow in the microread driver. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAABAgAGBQJUIHuZAAoJEIqAPN1PVmxKv+0P/2Cuc0b9JgYt0L8y2MmHH/Ej tuNz9K/vhOu39cKDKte6Yi5FADJAYnV1ZXviyqB2Uabjp7rgELEewl69c4ZfYdBy dkR1/rxQ5clwh7DF9/WRIz3j8LVsv8Vl7RiMEEBlNDdNlnZ05WgLVQibUJ7ymkoj eVBQM4tKY/CAYm88VAo+otPC4L/3NS6Zxaa+U5cxgy7ZhPRlYRDi65qf3U3Tdsyd mijy3nSO5IvBELrzFmUz2lC9mvKUNW1bFm4yz0eZfo+yxRJ+iGlAgO1QuI+tNXZA ODbf7lOTeHsr/YoFiQa503USEf9hLgjx7LOn0jJMkokQcmB8Ac6nQeB97e1Slpte LnNhF65Muh3eF3Le7vdeMMuZrbYldWlEWm8WAqLLWIG0v3Xi5qoVkqaW/S/VC/DH JPadQgL2jqx8CNXH6TBIIm3wXZzDFXruKGaufrrHLKJg9zIQcmaHcdnlI9dJ2/Yf Sc0dJNF55pFzIShI+VegOaxaDqDFhLhv0erIK6pjw6ilPo8uXP7BaSiukebSfFYA u7NBWkQB8coPXGz7BYY8FnSp455fP0HBuaWMSDLhKAe/Yg9RzT++cRE7lKuQ/Fkb aAyDzTyMoRj209HRvRKbzGqNlFx1CFznt17ZuQL1pCLpZaWc8/6VZw9Drf3gAWFx QGCJGej9PRBm/G3doOuK =ZLhy -----END PGP SIGNATURE----- Merge tag 'nfc-fixes-3.17-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/nfc-fixes Samuel Ortiz <sameo@linux.intel.com> says: "NFC: 3.17 fixes We have 3 NFC fixes for 3.17: - 2 potential build failures for ST21NFCA and ST21NFCB, triggered by a depmod dependenyc cycle. - One potential buffer overflow in the microread driver." Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
commit
5c244fa2c9
@ -501,9 +501,13 @@ static void microread_target_discovered(struct nfc_hci_dev *hdev, u8 gate,
|
||||
targets->sens_res =
|
||||
be16_to_cpu(*(u16 *)&skb->data[MICROREAD_EMCF_A_ATQA]);
|
||||
targets->sel_res = skb->data[MICROREAD_EMCF_A_SAK];
|
||||
memcpy(targets->nfcid1, &skb->data[MICROREAD_EMCF_A_UID],
|
||||
skb->data[MICROREAD_EMCF_A_LEN]);
|
||||
targets->nfcid1_len = skb->data[MICROREAD_EMCF_A_LEN];
|
||||
if (targets->nfcid1_len > sizeof(targets->nfcid1)) {
|
||||
r = -EINVAL;
|
||||
goto exit_free;
|
||||
}
|
||||
memcpy(targets->nfcid1, &skb->data[MICROREAD_EMCF_A_UID],
|
||||
targets->nfcid1_len);
|
||||
break;
|
||||
case MICROREAD_GATE_ID_MREAD_ISO_A_3:
|
||||
targets->supported_protocols =
|
||||
@ -511,9 +515,13 @@ static void microread_target_discovered(struct nfc_hci_dev *hdev, u8 gate,
|
||||
targets->sens_res =
|
||||
be16_to_cpu(*(u16 *)&skb->data[MICROREAD_EMCF_A3_ATQA]);
|
||||
targets->sel_res = skb->data[MICROREAD_EMCF_A3_SAK];
|
||||
memcpy(targets->nfcid1, &skb->data[MICROREAD_EMCF_A3_UID],
|
||||
skb->data[MICROREAD_EMCF_A3_LEN]);
|
||||
targets->nfcid1_len = skb->data[MICROREAD_EMCF_A3_LEN];
|
||||
if (targets->nfcid1_len > sizeof(targets->nfcid1)) {
|
||||
r = -EINVAL;
|
||||
goto exit_free;
|
||||
}
|
||||
memcpy(targets->nfcid1, &skb->data[MICROREAD_EMCF_A3_UID],
|
||||
targets->nfcid1_len);
|
||||
break;
|
||||
case MICROREAD_GATE_ID_MREAD_ISO_B:
|
||||
targets->supported_protocols = NFC_PROTO_ISO14443_B_MASK;
|
||||
|
@ -2,7 +2,8 @@
|
||||
# Makefile for ST21NFCA HCI based NFC driver
|
||||
#
|
||||
|
||||
st21nfca_i2c-objs = i2c.o
|
||||
st21nfca_hci-objs = st21nfca.o st21nfca_dep.o
|
||||
obj-$(CONFIG_NFC_ST21NFCA) += st21nfca_hci.o
|
||||
|
||||
obj-$(CONFIG_NFC_ST21NFCA) += st21nfca.o st21nfca_dep.o
|
||||
st21nfca_i2c-objs = i2c.o
|
||||
obj-$(CONFIG_NFC_ST21NFCA_I2C) += st21nfca_i2c.o
|
||||
|
@ -2,7 +2,8 @@
|
||||
# Makefile for ST21NFCB NCI based NFC driver
|
||||
#
|
||||
|
||||
st21nfcb_i2c-objs = i2c.o
|
||||
st21nfcb_nci-objs = ndlc.o st21nfcb.o
|
||||
obj-$(CONFIG_NFC_ST21NFCB) += st21nfcb_nci.o
|
||||
|
||||
obj-$(CONFIG_NFC_ST21NFCB) += st21nfcb.o ndlc.o
|
||||
st21nfcb_i2c-objs = i2c.o
|
||||
obj-$(CONFIG_NFC_ST21NFCB_I2C) += st21nfcb_i2c.o
|
||||
|
Loading…
Reference in New Issue
Block a user