Lines Matching refs:ntf
33 struct nci_core_conn_credit_ntf *ntf = (void *) skb->data;
37 pr_debug("num_entries %d\n", ntf->num_entries);
39 if (ntf->num_entries > NCI_MAX_NUM_CONN)
40 ntf->num_entries = NCI_MAX_NUM_CONN;
43 for (i = 0; i < ntf->num_entries; i++) {
44 ntf->conn_entries[i].conn_id =
45 nci_conn_id(&ntf->conn_entries[i].conn_id);
48 i, ntf->conn_entries[i].conn_id,
49 ntf->conn_entries[i].credits);
52 ntf->conn_entries[i].conn_id);
56 atomic_add(ntf->conn_entries[i].credits,
82 struct nci_core_intf_error_ntf *ntf = (void *) skb->data;
84 ntf->conn_id = nci_conn_id(&ntf->conn_id);
86 pr_debug("status 0x%x, conn_id %d\n", ntf->status, ntf->conn_id);
90 nci_data_exchange_complete(ndev, NULL, ntf->conn_id, -EIO);
266 struct nci_rf_discover_ntf *ntf)
273 if (target->logical_idx == ntf->rf_discovery_id) {
275 nci_add_new_protocol(ndev, target, ntf->rf_protocol,
276 ntf->rf_tech_and_mode,
277 &ntf->rf_tech_specific_params);
290 rc = nci_add_new_protocol(ndev, target, ntf->rf_protocol,
291 ntf->rf_tech_and_mode,
292 &ntf->rf_tech_specific_params);
294 target->logical_idx = ntf->rf_discovery_id;
313 struct nci_rf_discover_ntf ntf;
317 ntf.rf_discovery_id = *data++;
318 ntf.rf_protocol = *data++;
319 ntf.rf_tech_and_mode = *data++;
320 ntf.rf_tech_specific_params_len = *data++;
322 pr_debug("rf_discovery_id %d\n", ntf.rf_discovery_id);
323 pr_debug("rf_protocol 0x%x\n", ntf.rf_protocol);
324 pr_debug("rf_tech_and_mode 0x%x\n", ntf.rf_tech_and_mode);
326 ntf.rf_tech_specific_params_len);
328 if (ntf.rf_tech_specific_params_len > 0) {
329 switch (ntf.rf_tech_and_mode) {
332 &(ntf.rf_tech_specific_params.nfca_poll), data);
337 &(ntf.rf_tech_specific_params.nfcb_poll), data);
342 &(ntf.rf_tech_specific_params.nfcf_poll), data);
347 &(ntf.rf_tech_specific_params.nfcv_poll), data);
352 ntf.rf_tech_and_mode);
353 data += ntf.rf_tech_specific_params_len;
358 ntf.ntf_type = *data++;
359 pr_debug("ntf_type %d\n", ntf.ntf_type);
362 nci_add_new_target(ndev, &ntf);
364 if (ntf.ntf_type == NCI_DISCOVER_NTF_TYPE_MORE) {
374 struct nci_rf_intf_activated_ntf *ntf, __u8 *data)
379 switch (ntf->activation_rf_tech_and_mode) {
381 nfca_poll = &ntf->activation_params.nfca_poll_iso_dep;
391 nfcb_poll = &ntf->activation_params.nfcb_poll_iso_dep;
402 ntf->activation_rf_tech_and_mode);
410 struct nci_rf_intf_activated_ntf *ntf, __u8 *data)
415 switch (ntf->activation_rf_tech_and_mode) {
418 poll = &ntf->activation_params.poll_nfc_dep;
428 listen = &ntf->activation_params.listen_nfc_dep;
438 ntf->activation_rf_tech_and_mode);
446 struct nci_rf_intf_activated_ntf *ntf)
453 rc = nci_add_new_protocol(ndev, target, ntf->rf_protocol,
454 ntf->activation_rf_tech_and_mode,
455 &ntf->rf_tech_specific_params);
459 target->logical_idx = ntf->rf_discovery_id;
469 struct nci_rf_intf_activated_ntf *ntf)
473 if (ntf->activation_params_len <= 0)
476 switch (ntf->activation_rf_tech_and_mode) {
480 (ntf->activation_params.poll_nfc_dep.atr_res_len
484 (ntf->activation_params.poll_nfc_dep.atr_res
492 (ntf->activation_params.listen_nfc_dep.atr_req_len
496 (ntf->activation_params.listen_nfc_dep.atr_req
503 ntf->activation_rf_tech_and_mode);
514 struct nci_rf_intf_activated_ntf ntf;
518 ntf.rf_discovery_id = *data++;
519 ntf.rf_interface = *data++;
520 ntf.rf_protocol = *data++;
521 ntf.activation_rf_tech_and_mode = *data++;
522 ntf.max_data_pkt_payload_size = *data++;
523 ntf.initial_num_credits = *data++;
524 ntf.rf_tech_specific_params_len = *data++;
526 pr_debug("rf_discovery_id %d\n", ntf.rf_discovery_id);
527 pr_debug("rf_interface 0x%x\n", ntf.rf_interface);
528 pr_debug("rf_protocol 0x%x\n", ntf.rf_protocol);
530 ntf.activation_rf_tech_and_mode);
532 ntf.max_data_pkt_payload_size);
534 ntf.initial_num_credits);
536 ntf.rf_tech_specific_params_len);
542 if (ntf.rf_interface == NCI_RF_INTERFACE_NFCEE_DIRECT)
545 if (ntf.rf_tech_specific_params_len > 0) {
546 switch (ntf.activation_rf_tech_and_mode) {
549 &(ntf.rf_tech_specific_params.nfca_poll), data);
554 &(ntf.rf_tech_specific_params.nfcb_poll), data);
559 &(ntf.rf_tech_specific_params.nfcf_poll), data);
564 &(ntf.rf_tech_specific_params.nfcv_poll), data);
573 &(ntf.rf_tech_specific_params.nfcf_listen),
579 ntf.activation_rf_tech_and_mode);
585 ntf.data_exch_rf_tech_and_mode = *data++;
586 ntf.data_exch_tx_bit_rate = *data++;
587 ntf.data_exch_rx_bit_rate = *data++;
588 ntf.activation_params_len = *data++;
591 ntf.data_exch_rf_tech_and_mode);
592 pr_debug("data_exch_tx_bit_rate 0x%x\n", ntf.data_exch_tx_bit_rate);
593 pr_debug("data_exch_rx_bit_rate 0x%x\n", ntf.data_exch_rx_bit_rate);
594 pr_debug("activation_params_len %d\n", ntf.activation_params_len);
596 if (ntf.activation_params_len > 0) {
597 switch (ntf.rf_interface) {
600 &ntf, data);
605 &ntf, data);
614 ntf.rf_interface);
626 conn_info->max_pkt_payload_len = ntf.max_data_pkt_payload_size;
627 conn_info->initial_num_credits = ntf.initial_num_credits;
634 if (ntf.rf_interface == NCI_RF_INTERFACE_NFC_DEP) {
635 err = nci_store_general_bytes_nfc_dep(ndev, &ntf);
641 if (!(ntf.activation_rf_tech_and_mode & NCI_RF_TECH_MODE_LISTEN_MASK)) {
648 nci_target_auto_activated(ndev, &ntf);
660 ntf.rf_protocol == NCI_RF_PROTOCOL_NFC_DEP) {
676 struct nci_rf_deactivate_ntf *ntf = (void *) skb->data;
678 pr_debug("entry, type 0x%x, reason 0x%x\n", ntf->type, ntf->reason);
698 switch (ntf->type) {
746 pr_debug("NCI RX: MT=ntf, PBF=%d, GID=0x%x, OID=0x%x, plen=%d\n",
757 pr_err("unsupported ntf opcode 0x%x\n",
798 pr_err("unknown ntf opcode 0x%x\n", ntf_opcode);