Home
last modified time | relevance | path

Searched refs:ndev (Results 1 – 21 of 21) sorted by relevance

/net/nfc/nci/
Dcore.c54 struct nci_conn_info *nci_get_conn_info_by_conn_id(struct nci_dev *ndev, in nci_get_conn_info_by_conn_id() argument
59 list_for_each_entry(conn_info, &ndev->conn_info_list, list) { in nci_get_conn_info_by_conn_id()
67 int nci_get_conn_info_by_dest_type_params(struct nci_dev *ndev, u8 dest_type, in nci_get_conn_info_by_dest_type_params() argument
72 list_for_each_entry(conn_info, &ndev->conn_info_list, list) { in nci_get_conn_info_by_dest_type_params()
90 void nci_req_complete(struct nci_dev *ndev, int result) in nci_req_complete() argument
92 if (ndev->req_status == NCI_REQ_PEND) { in nci_req_complete()
93 ndev->req_result = result; in nci_req_complete()
94 ndev->req_status = NCI_REQ_DONE; in nci_req_complete()
95 complete(&ndev->req_completion); in nci_req_complete()
100 static void nci_req_cancel(struct nci_dev *ndev, int err) in nci_req_cancel() argument
[all …]
Drsp.c40 static void nci_core_reset_rsp_packet(struct nci_dev *ndev, struct sk_buff *skb) in nci_core_reset_rsp_packet() argument
47 ndev->nci_ver = rsp->nci_ver; in nci_core_reset_rsp_packet()
52 nci_req_complete(ndev, rsp->status); in nci_core_reset_rsp_packet()
55 static void nci_core_init_rsp_packet(struct nci_dev *ndev, struct sk_buff *skb) in nci_core_init_rsp_packet() argument
65 ndev->nfcc_features = __le32_to_cpu(rsp_1->nfcc_features); in nci_core_init_rsp_packet()
66 ndev->num_supported_rf_interfaces = rsp_1->num_supported_rf_interfaces; in nci_core_init_rsp_packet()
68 if (ndev->num_supported_rf_interfaces > in nci_core_init_rsp_packet()
70 ndev->num_supported_rf_interfaces = in nci_core_init_rsp_packet()
74 memcpy(ndev->supported_rf_interfaces, in nci_core_init_rsp_packet()
76 ndev->num_supported_rf_interfaces); in nci_core_init_rsp_packet()
[all …]
Dntf.c42 static void nci_core_conn_credits_ntf_packet(struct nci_dev *ndev, in nci_core_conn_credits_ntf_packet() argument
63 conn_info = nci_get_conn_info_by_conn_id(ndev, in nci_core_conn_credits_ntf_packet()
73 if (!skb_queue_empty(&ndev->tx_q)) in nci_core_conn_credits_ntf_packet()
74 queue_work(ndev->tx_wq, &ndev->tx_work); in nci_core_conn_credits_ntf_packet()
77 static void nci_core_generic_error_ntf_packet(struct nci_dev *ndev, in nci_core_generic_error_ntf_packet() argument
84 if (atomic_read(&ndev->state) == NCI_W4_HOST_SELECT) { in nci_core_generic_error_ntf_packet()
87 nci_req_complete(ndev, status); in nci_core_generic_error_ntf_packet()
91 static void nci_core_conn_intf_error_ntf_packet(struct nci_dev *ndev, in nci_core_conn_intf_error_ntf_packet() argument
101 if (test_bit(NCI_DATA_EXCHANGE, &ndev->flags)) in nci_core_conn_intf_error_ntf_packet()
102 nci_data_exchange_complete(ndev, NULL, ntf->conn_id, -EIO); in nci_core_conn_intf_error_ntf_packet()
[all …]
Dhci.c133 static void nci_hci_reset_pipes_per_host(struct nci_dev *ndev, u8 host) in nci_hci_reset_pipes_per_host() argument
138 if (ndev->hci_dev->pipes[i].host == host) { in nci_hci_reset_pipes_per_host()
139 ndev->hci_dev->pipes[i].gate = NCI_HCI_INVALID_GATE; in nci_hci_reset_pipes_per_host()
140 ndev->hci_dev->pipes[i].host = NCI_HCI_INVALID_HOST; in nci_hci_reset_pipes_per_host()
153 static int nci_hci_send_data(struct nci_dev *ndev, u8 pipe, in nci_hci_send_data() argument
162 conn_info = ndev->hci_dev->conn_info; in nci_hci_send_data()
167 skb = nci_skb_alloc(ndev, conn_info->max_pkt_payload_len + in nci_hci_send_data()
192 r = nci_send_data(ndev, conn_info->conn_id, skb); in nci_hci_send_data()
199 skb = nci_skb_alloc(ndev, in nci_hci_send_data()
212 static void nci_hci_send_data_req(struct nci_dev *ndev, unsigned long opt) in nci_hci_send_data_req() argument
[all …]
Ddata.c38 void nci_data_exchange_complete(struct nci_dev *ndev, struct sk_buff *skb, in nci_data_exchange_complete() argument
45 conn_info = nci_get_conn_info_by_conn_id(ndev, conn_id); in nci_data_exchange_complete()
57 del_timer_sync(&ndev->data_timer); in nci_data_exchange_complete()
58 clear_bit(NCI_DATA_EXCHANGE_TO, &ndev->flags); in nci_data_exchange_complete()
71 clear_bit(NCI_DATA_EXCHANGE, &ndev->flags); in nci_data_exchange_complete()
76 static inline void nci_push_data_hdr(struct nci_dev *ndev, in nci_push_data_hdr() argument
93 int nci_conn_max_data_pkt_payload_size(struct nci_dev *ndev, __u8 conn_id) in nci_conn_max_data_pkt_payload_size() argument
97 conn_info = nci_get_conn_info_by_conn_id(ndev, conn_id); in nci_conn_max_data_pkt_payload_size()
105 static int nci_queue_tx_data_frags(struct nci_dev *ndev, in nci_queue_tx_data_frags() argument
119 conn_info = nci_get_conn_info_by_conn_id(ndev, conn_id); in nci_queue_tx_data_frags()
[all …]
Dspi.c138 struct nci_dev *ndev) in nci_spi_allocate_spi() argument
151 nspi->ndev = ndev; in nci_spi_allocate_spi()
165 skb = nci_skb_alloc(nspi->ndev, 0, GFP_KERNEL); in send_acknowledge()
222 skb = nci_skb_alloc(nspi->ndev, rx_len, GFP_KERNEL); in __nci_spi_read()
Duart.c336 if (!nu->ndev) { in nci_uart_default_recv_buf()
349 nu->rx_skb = nci_skb_alloc(nu->ndev, in nci_uart_default_recv_buf()
394 return nci_recv_frame(nu->ndev, skb); in nci_uart_default_recv()
/net/core/
Dnetpoll.c606 int __netpoll_setup(struct netpoll *np, struct net_device *ndev) in __netpoll_setup() argument
612 np->dev = ndev; in __netpoll_setup()
613 strlcpy(np->dev_name, ndev->name, IFNAMSIZ); in __netpoll_setup()
616 if ((ndev->priv_flags & IFF_DISABLE_NETPOLL) || in __netpoll_setup()
617 !ndev->netdev_ops->ndo_poll_controller) { in __netpoll_setup()
624 if (!ndev->npinfo) { in __netpoll_setup()
639 err = ops->ndo_netpoll_setup(ndev, npinfo); in __netpoll_setup()
644 npinfo = rtnl_dereference(ndev->npinfo); in __netpoll_setup()
651 rcu_assign_pointer(ndev->npinfo, npinfo); in __netpoll_setup()
664 struct net_device *ndev = NULL; in netpoll_setup() local
[all …]
Dnet-sysfs.c47 struct net_device *ndev = to_net_dev(dev); in netdev_show() local
51 if (dev_isalive(ndev)) in netdev_show()
52 ret = (*format)(ndev, buf); in netdev_show()
118 struct net_device *ndev = to_net_dev(dev); in iflink_show() local
120 return sprintf(buf, fmt_dec, dev_get_iflink(ndev)); in iflink_show()
133 struct net_device *ndev = to_net_dev(dev); in name_assign_type_show() local
136 if (ndev->name_assign_type != NET_NAME_UNKNOWN) in name_assign_type_show()
147 struct net_device *ndev = to_net_dev(dev); in address_show() local
151 if (dev_isalive(ndev)) in address_show()
152 ret = sysfs_format_mac(buf, ndev->dev_addr, ndev->addr_len); in address_show()
[all …]
/net/mac802154/
Diface.c627 struct net_device *ndev = NULL; in ieee802154_if_add() local
633 ndev = alloc_netdev(sizeof(*sdata), name, in ieee802154_if_add()
635 if (!ndev) in ieee802154_if_add()
638 ndev->needed_headroom = local->hw.extra_tx_headroom + in ieee802154_if_add()
641 ret = dev_alloc_name(ndev, ndev->name); in ieee802154_if_add()
645 ieee802154_le64_to_be64(ndev->perm_addr, in ieee802154_if_add()
649 ndev->type = ARPHRD_IEEE802154; in ieee802154_if_add()
651 ieee802154_le64_to_be64(ndev->dev_addr, &extended_addr); in ieee802154_if_add()
653 memcpy(ndev->dev_addr, ndev->perm_addr, in ieee802154_if_add()
657 ndev->type = ARPHRD_IEEE802154_MONITOR; in ieee802154_if_add()
[all …]
/net/nfc/hci/
Dhcp.c39 struct nfc_dev *ndev = hdev->ndev; in nfc_hci_hcp_message_tx() local
69 skb_len = ndev->tx_headroom + NFC_HCI_HCP_PACKET_HEADER_LEN + in nfc_hci_hcp_message_tx()
70 data_link_len + ndev->tx_tailroom; in nfc_hci_hcp_message_tx()
78 skb_reserve(skb, ndev->tx_headroom); in nfc_hci_hcp_message_tx()
Dcore.c374 r = nfc_targets_found(hdev->ndev, targets, 1); in nfc_hci_target_discovered()
838 nfc_driver_failure(hdev->ndev, err); in nfc_hci_failure()
978 hdev->ndev = nfc_allocate_device(&hci_nfc_ops, protocols, in nfc_hci_allocate_device()
981 if (!hdev->ndev) { in nfc_hci_allocate_device()
991 nfc_set_drvdata(hdev->ndev, hdev); in nfc_hci_allocate_device()
1003 nfc_free_device(hdev->ndev); in nfc_hci_free_device()
1027 return nfc_register_device(hdev->ndev); in nfc_hci_register_device()
1055 nfc_unregister_device(hdev->ndev); in nfc_hci_unregister_device()
/net/mac80211/
Diface.c1775 struct net_device *ndev = NULL; in ieee80211_if_add() local
1814 ndev = alloc_netdev_mqs(size + txq_size, in ieee80211_if_add()
1817 if (!ndev) in ieee80211_if_add()
1819 dev_net_set(ndev, wiphy_net(local->hw.wiphy)); in ieee80211_if_add()
1821 ndev->tstats = netdev_alloc_pcpu_stats(struct pcpu_sw_netstats); in ieee80211_if_add()
1822 if (!ndev->tstats) { in ieee80211_if_add()
1823 free_netdev(ndev); in ieee80211_if_add()
1827 ndev->needed_headroom = local->tx_headroom + in ieee80211_if_add()
1834 ndev->needed_tailroom = IEEE80211_ENCRYPT_TAILROOM; in ieee80211_if_add()
1836 ret = dev_alloc_name(ndev, ndev->name); in ieee80211_if_add()
[all …]
Dmain.c302 struct net_device *ndev = ifa->ifa_dev->dev; in ieee80211_ifa_changed() local
303 struct wireless_dev *wdev = ndev->ieee80211_ptr; in ieee80211_ifa_changed()
317 sdata = IEEE80211_DEV_TO_SUB_IF(ndev); in ieee80211_ifa_changed()
359 struct net_device *ndev = ifa->idev->dev; in ieee80211_ifa6_changed() local
362 struct wireless_dev *wdev = ndev->ieee80211_ptr; in ieee80211_ifa6_changed()
369 sdata = IEEE80211_DEV_TO_SUB_IF(ndev); in ieee80211_ifa6_changed()
/net/ncsi/
Dncsi-manage.c132 struct ncsi_dev *nd = &ndp->ndev; in ncsi_report_link()
202 netdev_err(ndp->ndev.dev, "Error %d sending GLS\n", in ncsi_channel_monitor()
499 if (ndp->ndev.dev == dev) in ncsi_find_dev()
500 return &ndp->ndev; in ncsi_find_dev()
529 struct ncsi_dev *nd = &ndp->ndev; in ncsi_suspend_channel()
644 struct ncsi_dev *nd = &ndp->ndev; in ncsi_configure_channel()
891 struct ncsi_dev *nd = &ndp->ndev; in ncsi_probe_channel()
1057 struct ncsi_dev *nd = &ndp->ndev; in ncsi_dev_work()
1102 ndp->ndev.state = ncsi_dev_state_config; in ncsi_process_next_channel()
1106 ndp->ndev.state = ncsi_dev_state_suspend; in ncsi_process_next_channel()
[all …]
Dinternal.h257 struct ncsi_dev ndev; /* Associated NCSI device */ member
300 container_of(nd, struct ncsi_dev_priv, ndev)
Dncsi-cmd.c267 struct ncsi_dev *nd = &ndp->ndev; in ncsi_alloc_command()
326 netdev_err(nca->ndp->ndev.dev, in ncsi_xmit_cmd()
Dncsi-aen.c209 netdev_warn(ndp->ndev.dev, "Invalid AEN (0x%x) received\n", in ncsi_aen_handler()
/net/ieee802154/6lowpan/
Dcore.c207 struct net_device *ndev = netdev_notifier_info_to_dev(ptr); in lowpan_device_event() local
210 if (ndev->type != ARPHRD_IEEE802154) in lowpan_device_event()
212 wpan_dev = ndev->ieee802154_ptr; in lowpan_device_event()
/net/ipv6/
Daddrconf.c363 struct inet6_dev *ndev; in ipv6_add_dev() local
371 ndev = kzalloc(sizeof(struct inet6_dev), GFP_KERNEL); in ipv6_add_dev()
372 if (!ndev) in ipv6_add_dev()
375 rwlock_init(&ndev->lock); in ipv6_add_dev()
376 ndev->dev = dev; in ipv6_add_dev()
377 INIT_LIST_HEAD(&ndev->addr_list); in ipv6_add_dev()
378 setup_timer(&ndev->rs_timer, addrconf_rs_timer, in ipv6_add_dev()
379 (unsigned long)ndev); in ipv6_add_dev()
380 memcpy(&ndev->cnf, dev_net(dev)->ipv6.devconf_dflt, sizeof(ndev->cnf)); in ipv6_add_dev()
382 if (ndev->cnf.stable_secret.initialized) in ipv6_add_dev()
[all …]
/net/nfc/
Dllcp_core.c1564 int nfc_llcp_register_device(struct nfc_dev *ndev) in nfc_llcp_register_device() argument
1572 local->dev = ndev; in nfc_llcp_register_device()