x86/amd-iommu: Add per IOMMU reference counting
[linux/fpc-iii.git] / include / net / nl802154.h
blob99d2ba1c7e03f76d7a92e95691fb002535de52eb
1 /*
2 * nl802154.h
4 * Copyright (C) 2007, 2008, 2009 Siemens AG
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2
8 * as published by the Free Software Foundation.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21 #ifndef IEEE802154_NL_H
22 #define IEEE802154_NL_H
24 struct net_device;
25 struct ieee802154_addr;
27 /**
28 * ieee802154_nl_assoc_indic - Notify userland of an association request.
29 * @dev: The network device on which this association request was
30 * received.
31 * @addr: The address of the device requesting association.
32 * @cap: The capability information field from the device.
34 * This informs a userland coordinator of a device requesting to
35 * associate with the PAN controlled by the coordinator.
37 * Note: This is in section 7.3.1 of the IEEE 802.15.4-2006 document.
39 int ieee802154_nl_assoc_indic(struct net_device *dev,
40 struct ieee802154_addr *addr, u8 cap);
42 /**
43 * ieee802154_nl_assoc_confirm - Notify userland of association.
44 * @dev: The device which has completed association.
45 * @short_addr: The short address assigned to the device.
46 * @status: The status of the association.
48 * Inform userland of the result of an association request. If the
49 * association request included asking the coordinator to allocate
50 * a short address then it is returned in @short_addr.
52 * Note: This is in section 7.3.2 of the IEEE 802.15.4 document.
54 int ieee802154_nl_assoc_confirm(struct net_device *dev,
55 u16 short_addr, u8 status);
57 /**
58 * ieee802154_nl_disassoc_indic - Notify userland of disassociation.
59 * @dev: The device on which disassociation was indicated.
60 * @addr: The device which is disassociating.
61 * @reason: The reason for the disassociation.
63 * Inform userland that a device has disassociated from the network.
65 * Note: This is in section 7.3.3 of the IEEE 802.15.4 document.
67 int ieee802154_nl_disassoc_indic(struct net_device *dev,
68 struct ieee802154_addr *addr, u8 reason);
70 /**
71 * ieee802154_nl_disassoc_confirm - Notify userland of disassociation
72 * completion.
73 * @dev: The device on which disassociation was ordered.
74 * @status: The result of the disassociation.
76 * Inform userland of the result of requesting that a device
77 * disassociate, or the result of requesting that we disassociate from
78 * a PAN managed by another coordinator.
80 * Note: This is in section 7.1.4.3 of the IEEE 802.15.4 document.
82 int ieee802154_nl_disassoc_confirm(struct net_device *dev,
83 u8 status);
85 /**
86 * ieee802154_nl_scan_confirm - Notify userland of completion of scan.
87 * @dev: The device which was instructed to scan.
88 * @status: The status of the scan operation.
89 * @scan_type: What type of scan was performed.
90 * @unscanned: Any channels that the device was unable to scan.
91 * @edl: The energy levels (if a passive scan).
94 * Note: This is in section 7.1.11 of the IEEE 802.15.4 document.
95 * Note: This API does not permit the return of an active scan result.
97 int ieee802154_nl_scan_confirm(struct net_device *dev,
98 u8 status, u8 scan_type, u32 unscanned, u8 page,
99 u8 *edl/*, struct list_head *pan_desc_list */);
102 * ieee802154_nl_beacon_indic - Notify userland of a received beacon.
103 * @dev: The device on which a beacon was received.
104 * @panid: The PAN of the coordinator.
105 * @coord_addr: The short address of the coordinator on that PAN.
107 * Note: This is in section 7.1.5 of the IEEE 802.15.4 document.
108 * Note: This API does not provide extended information such as what
109 * channel the PAN is on or what the LQI of the beacon frame was on
110 * receipt.
111 * Note: This API cannot indicate a beacon frame for a coordinator
112 * operating in long addressing mode.
114 int ieee802154_nl_beacon_indic(struct net_device *dev, u16 panid,
115 u16 coord_addr);
118 * ieee802154_nl_start_confirm - Notify userland of completion of start.
119 * @dev: The device which was instructed to scan.
120 * @status: The status of the scan operation.
122 * Note: This is in section 7.1.14 of the IEEE 802.15.4 document.
124 int ieee802154_nl_start_confirm(struct net_device *dev, u8 status);
126 #endif