diff options
author | Samuel Ortiz <sameo@linux.intel.com> | 2012-04-10 17:43:09 (GMT) |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-04-12 19:10:37 (GMT) |
commit | c4fbb6515a4dcec83d340247639b5644c4745528 (patch) | |
tree | 9123c1e0b56ea1f9910ce4db1e9046bd5a8a29c4 /include/net | |
parent | 0efbf7fb308d0c6f8419922850a2d0b45d4d4401 (diff) | |
download | linux-fsl-qoriq-c4fbb6515a4dcec83d340247639b5644c4745528.tar.xz |
NFC: The core part should generate the target index
The target index can be used by userspace to uniquely identify a target
and thus should be kept unique, per NFC adapter. Moreover, some protocols
do not provide a logical index when discovering new targets, so we have to
generate one for them.
For NCI or pn533 to fetch their logical index, we added a logical_idx field
to the target structure.
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/nfc/nfc.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/net/nfc/nfc.h b/include/net/nfc/nfc.h index 431a6c5..45f0563 100644 --- a/include/net/nfc/nfc.h +++ b/include/net/nfc/nfc.h @@ -79,6 +79,7 @@ struct nfc_target { u8 sensf_res_len; u8 sensf_res[NFC_SENSF_RES_MAXSIZE]; u8 hci_reader_gate; + u8 logical_idx; }; struct nfc_genl_data { @@ -88,6 +89,7 @@ struct nfc_genl_data { struct nfc_dev { unsigned idx; + unsigned target_idx; struct nfc_target *targets; int n_targets; int targets_generation; |