aboutsummaryrefslogtreecommitdiffstats
path: root/net/nfc/hci
diff options
context:
space:
mode:
authorArron Wang <arron.wang@intel.com>2012-09-27 05:32:55 -0400
committerSamuel Ortiz <sameo@linux.intel.com>2012-10-26 12:26:45 -0400
commitf7a5f6c532f33ba66a7ca19e81ed447a83dab2db (patch)
tree6ac75749971e6870a0a8fbbf059fcca2af9ee55b /net/nfc/hci
parent7e2afc9d072b9f84b314b208a125c2b1ce36b685 (diff)
NFC: Pass hardware specific HCI event to driver
Signed-off-by: Arron Wang <arron.wang@intel.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'net/nfc/hci')
-rw-r--r--net/nfc/hci/core.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/net/nfc/hci/core.c b/net/nfc/hci/core.c
index 5fbb6e40793e..8a9a811b558a 100644
--- a/net/nfc/hci/core.c
+++ b/net/nfc/hci/core.c
@@ -182,7 +182,7 @@ static u32 nfc_hci_sak_to_protocol(u8 sak)
182 } 182 }
183} 183}
184 184
185static int nfc_hci_target_discovered(struct nfc_hci_dev *hdev, u8 gate) 185int nfc_hci_target_discovered(struct nfc_hci_dev *hdev, u8 gate)
186{ 186{
187 struct nfc_target *targets; 187 struct nfc_target *targets;
188 struct sk_buff *atqa_skb = NULL; 188 struct sk_buff *atqa_skb = NULL;
@@ -275,6 +275,7 @@ exit:
275 275
276 return r; 276 return r;
277} 277}
278EXPORT_SYMBOL(nfc_hci_target_discovered);
278 279
279void nfc_hci_event_received(struct nfc_hci_dev *hdev, u8 pipe, u8 event, 280void nfc_hci_event_received(struct nfc_hci_dev *hdev, u8 pipe, u8 event,
280 struct sk_buff *skb) 281 struct sk_buff *skb)
@@ -307,8 +308,13 @@ void nfc_hci_event_received(struct nfc_hci_dev *hdev, u8 pipe, u8 event,
307 nfc_hci_pipe2gate(hdev, pipe)); 308 nfc_hci_pipe2gate(hdev, pipe));
308 break; 309 break;
309 default: 310 default:
310 /* TODO: Unknown events are hardware specific 311 if (hdev->ops->event_received) {
311 * pass them to the driver (needs a new hci_ops) */ 312 hdev->ops->event_received(hdev,
313 nfc_hci_pipe2gate(hdev, pipe),
314 event, skb);
315 return;
316 }
317
312 break; 318 break;
313 } 319 }
314 320