diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/bcma/bcma.h | 23 | ||||
| -rw-r--r-- | include/linux/platform_data/st21nfcb.h | 32 | ||||
| -rw-r--r-- | include/net/6lowpan.h | 50 | ||||
| -rw-r--r-- | include/net/bluetooth/hci.h | 6 | ||||
| -rw-r--r-- | include/net/bluetooth/hci_core.h | 3 | ||||
| -rw-r--r-- | include/net/bluetooth/mgmt.h | 4 | ||||
| -rw-r--r-- | include/net/nfc/digital.h | 13 | ||||
| -rw-r--r-- | include/net/nfc/hci.h | 1 |
8 files changed, 68 insertions, 64 deletions
diff --git a/include/linux/bcma/bcma.h b/include/linux/bcma/bcma.h index 969af0f2bdf9..0272e49135d0 100644 --- a/include/linux/bcma/bcma.h +++ b/include/linux/bcma/bcma.h | |||
| @@ -73,17 +73,17 @@ struct bcma_host_ops { | |||
| 73 | /* Core-ID values. */ | 73 | /* Core-ID values. */ |
| 74 | #define BCMA_CORE_OOB_ROUTER 0x367 /* Out of band */ | 74 | #define BCMA_CORE_OOB_ROUTER 0x367 /* Out of band */ |
| 75 | #define BCMA_CORE_4706_CHIPCOMMON 0x500 | 75 | #define BCMA_CORE_4706_CHIPCOMMON 0x500 |
| 76 | #define BCMA_CORE_PCIEG2 0x501 | 76 | #define BCMA_CORE_NS_PCIEG2 0x501 |
| 77 | #define BCMA_CORE_DMA 0x502 | 77 | #define BCMA_CORE_NS_DMA 0x502 |
| 78 | #define BCMA_CORE_SDIO3 0x503 | 78 | #define BCMA_CORE_NS_SDIO3 0x503 |
| 79 | #define BCMA_CORE_USB20 0x504 | 79 | #define BCMA_CORE_NS_USB20 0x504 |
| 80 | #define BCMA_CORE_USB30 0x505 | 80 | #define BCMA_CORE_NS_USB30 0x505 |
| 81 | #define BCMA_CORE_A9JTAG 0x506 | 81 | #define BCMA_CORE_NS_A9JTAG 0x506 |
| 82 | #define BCMA_CORE_DDR23 0x507 | 82 | #define BCMA_CORE_NS_DDR23 0x507 |
| 83 | #define BCMA_CORE_ROM 0x508 | 83 | #define BCMA_CORE_NS_ROM 0x508 |
| 84 | #define BCMA_CORE_NAND 0x509 | 84 | #define BCMA_CORE_NS_NAND 0x509 |
| 85 | #define BCMA_CORE_QSPI 0x50A | 85 | #define BCMA_CORE_NS_QSPI 0x50A |
| 86 | #define BCMA_CORE_CHIPCOMMON_B 0x50B | 86 | #define BCMA_CORE_NS_CHIPCOMMON_B 0x50B |
| 87 | #define BCMA_CORE_4706_SOC_RAM 0x50E | 87 | #define BCMA_CORE_4706_SOC_RAM 0x50E |
| 88 | #define BCMA_CORE_ARMCA9 0x510 | 88 | #define BCMA_CORE_ARMCA9 0x510 |
| 89 | #define BCMA_CORE_4706_MAC_GBIT 0x52D | 89 | #define BCMA_CORE_4706_MAC_GBIT 0x52D |
| @@ -158,6 +158,7 @@ struct bcma_host_ops { | |||
| 158 | /* Chip IDs of PCIe devices */ | 158 | /* Chip IDs of PCIe devices */ |
| 159 | #define BCMA_CHIP_ID_BCM4313 0x4313 | 159 | #define BCMA_CHIP_ID_BCM4313 0x4313 |
| 160 | #define BCMA_CHIP_ID_BCM43142 43142 | 160 | #define BCMA_CHIP_ID_BCM43142 43142 |
| 161 | #define BCMA_CHIP_ID_BCM43131 43131 | ||
| 161 | #define BCMA_CHIP_ID_BCM43217 43217 | 162 | #define BCMA_CHIP_ID_BCM43217 43217 |
| 162 | #define BCMA_CHIP_ID_BCM43222 43222 | 163 | #define BCMA_CHIP_ID_BCM43222 43222 |
| 163 | #define BCMA_CHIP_ID_BCM43224 43224 | 164 | #define BCMA_CHIP_ID_BCM43224 43224 |
diff --git a/include/linux/platform_data/st21nfcb.h b/include/linux/platform_data/st21nfcb.h new file mode 100644 index 000000000000..2d11f1f5efab --- /dev/null +++ b/include/linux/platform_data/st21nfcb.h | |||
| @@ -0,0 +1,32 @@ | |||
| 1 | /* | ||
| 2 | * Driver include for the ST21NFCB NFC chip. | ||
| 3 | * | ||
| 4 | * Copyright (C) 2014 STMicroelectronics SAS. All rights reserved. | ||
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify it | ||
| 7 | * under the terms and conditions of the GNU General Public License, | ||
| 8 | * version 2, as published by the Free Software Foundation. | ||
| 9 | * | ||
| 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. | ||
| 14 | * | ||
| 15 | * You should have received a copy of the GNU General Public License | ||
| 16 | * along with this program; if not, see <http://www.gnu.org/licenses/>. | ||
| 17 | */ | ||
| 18 | |||
| 19 | #ifndef _ST21NFCB_NCI_H_ | ||
| 20 | #define _ST21NFCB_NCI_H_ | ||
| 21 | |||
| 22 | #include <linux/i2c.h> | ||
| 23 | |||
| 24 | #define ST21NFCB_NCI_DRIVER_NAME "st21nfcb_nci" | ||
| 25 | |||
| 26 | struct st21nfcb_nfc_platform_data { | ||
| 27 | unsigned int gpio_irq; | ||
| 28 | unsigned int gpio_reset; | ||
| 29 | unsigned int irq_polarity; | ||
| 30 | }; | ||
| 31 | |||
| 32 | #endif /* _ST21NFCA_HCI_H_ */ | ||
diff --git a/include/net/6lowpan.h b/include/net/6lowpan.h index 79b530fb2c4d..d184df1d0d41 100644 --- a/include/net/6lowpan.h +++ b/include/net/6lowpan.h | |||
| @@ -75,20 +75,6 @@ | |||
| 75 | (((a)->s6_addr[14]) == (m)[6]) && \ | 75 | (((a)->s6_addr[14]) == (m)[6]) && \ |
| 76 | (((a)->s6_addr[15]) == (m)[7])) | 76 | (((a)->s6_addr[15]) == (m)[7])) |
| 77 | 77 | ||
| 78 | /* ipv6 address is unspecified */ | ||
| 79 | #define is_addr_unspecified(a) \ | ||
| 80 | ((((a)->s6_addr32[0]) == 0) && \ | ||
| 81 | (((a)->s6_addr32[1]) == 0) && \ | ||
| 82 | (((a)->s6_addr32[2]) == 0) && \ | ||
| 83 | (((a)->s6_addr32[3]) == 0)) | ||
| 84 | |||
| 85 | /* compare ipv6 addresses prefixes */ | ||
| 86 | #define ipaddr_prefixcmp(addr1, addr2, length) \ | ||
| 87 | (memcmp(addr1, addr2, length >> 3) == 0) | ||
| 88 | |||
| 89 | /* local link, i.e. FE80::/10 */ | ||
| 90 | #define is_addr_link_local(a) (((a)->s6_addr16[0]) == htons(0xFE80)) | ||
| 91 | |||
| 92 | /* | 78 | /* |
| 93 | * check whether we can compress the IID to 16 bits, | 79 | * check whether we can compress the IID to 16 bits, |
| 94 | * it's possible for unicast adresses with first 49 bits are zero only. | 80 | * it's possible for unicast adresses with first 49 bits are zero only. |
| @@ -100,22 +86,8 @@ | |||
| 100 | (((a)->s6_addr[12]) == 0xfe) && \ | 86 | (((a)->s6_addr[12]) == 0xfe) && \ |
| 101 | (((a)->s6_addr[13]) == 0)) | 87 | (((a)->s6_addr[13]) == 0)) |
| 102 | 88 | ||
| 103 | /* multicast address */ | ||
| 104 | #define is_addr_mcast(a) (((a)->s6_addr[0]) == 0xFF) | ||
| 105 | |||
| 106 | /* check whether the 112-bit gid of the multicast address is mappable to: */ | 89 | /* check whether the 112-bit gid of the multicast address is mappable to: */ |
| 107 | 90 | ||
| 108 | /* 9 bits, for FF02::1 (all nodes) and FF02::2 (all routers) addresses only. */ | ||
| 109 | #define lowpan_is_mcast_addr_compressable(a) \ | ||
| 110 | ((((a)->s6_addr16[1]) == 0) && \ | ||
| 111 | (((a)->s6_addr16[2]) == 0) && \ | ||
| 112 | (((a)->s6_addr16[3]) == 0) && \ | ||
| 113 | (((a)->s6_addr16[4]) == 0) && \ | ||
| 114 | (((a)->s6_addr16[5]) == 0) && \ | ||
| 115 | (((a)->s6_addr16[6]) == 0) && \ | ||
| 116 | (((a)->s6_addr[14]) == 0) && \ | ||
| 117 | ((((a)->s6_addr[15]) == 1) || (((a)->s6_addr[15]) == 2))) | ||
| 118 | |||
| 119 | /* 48 bits, FFXX::00XX:XXXX:XXXX */ | 91 | /* 48 bits, FFXX::00XX:XXXX:XXXX */ |
| 120 | #define lowpan_is_mcast_addr_compressable48(a) \ | 92 | #define lowpan_is_mcast_addr_compressable48(a) \ |
| 121 | ((((a)->s6_addr16[1]) == 0) && \ | 93 | ((((a)->s6_addr16[1]) == 0) && \ |
| @@ -168,17 +140,6 @@ | |||
| 168 | #define LOWPAN_FRAGN_HEAD_SIZE 0x5 | 140 | #define LOWPAN_FRAGN_HEAD_SIZE 0x5 |
| 169 | 141 | ||
| 170 | /* | 142 | /* |
| 171 | * According IEEE802.15.4 standard: | ||
| 172 | * - MTU is 127 octets | ||
| 173 | * - maximum MHR size is 37 octets | ||
| 174 | * - MFR size is 2 octets | ||
| 175 | * | ||
| 176 | * so minimal payload size that we may guarantee is: | ||
| 177 | * MTU - MHR - MFR = 88 octets | ||
| 178 | */ | ||
| 179 | #define LOWPAN_FRAG_SIZE 88 | ||
| 180 | |||
| 181 | /* | ||
| 182 | * Values of fields within the IPHC encoding first byte | 143 | * Values of fields within the IPHC encoding first byte |
| 183 | * (C stands for compressed and I for inline) | 144 | * (C stands for compressed and I for inline) |
| 184 | */ | 145 | */ |
| @@ -279,17 +240,6 @@ static inline int lowpan_fetch_skb_u8(struct sk_buff *skb, u8 *val) | |||
| 279 | return 0; | 240 | return 0; |
| 280 | } | 241 | } |
| 281 | 242 | ||
| 282 | static inline int lowpan_fetch_skb_u16(struct sk_buff *skb, u16 *val) | ||
| 283 | { | ||
| 284 | if (unlikely(!pskb_may_pull(skb, 2))) | ||
| 285 | return -EINVAL; | ||
| 286 | |||
| 287 | *val = (skb->data[0] << 8) | skb->data[1]; | ||
| 288 | skb_pull(skb, 2); | ||
| 289 | |||
| 290 | return 0; | ||
| 291 | } | ||
| 292 | |||
| 293 | static inline bool lowpan_fetch_skb(struct sk_buff *skb, | 243 | static inline bool lowpan_fetch_skb(struct sk_buff *skb, |
| 294 | void *data, const unsigned int len) | 244 | void *data, const unsigned int len) |
| 295 | { | 245 | { |
diff --git a/include/net/bluetooth/hci.h b/include/net/bluetooth/hci.h index f0a3d8890760..3f8547f1c6f8 100644 --- a/include/net/bluetooth/hci.h +++ b/include/net/bluetooth/hci.h | |||
| @@ -167,7 +167,7 @@ enum { | |||
| 167 | HCI_AUTO_OFF, | 167 | HCI_AUTO_OFF, |
| 168 | HCI_RFKILLED, | 168 | HCI_RFKILLED, |
| 169 | HCI_MGMT, | 169 | HCI_MGMT, |
| 170 | HCI_PAIRABLE, | 170 | HCI_BONDABLE, |
| 171 | HCI_SERVICE_CACHE, | 171 | HCI_SERVICE_CACHE, |
| 172 | HCI_KEEP_DEBUG_KEYS, | 172 | HCI_KEEP_DEBUG_KEYS, |
| 173 | HCI_USE_DEBUG_KEYS, | 173 | HCI_USE_DEBUG_KEYS, |
| @@ -1074,6 +1074,8 @@ struct hci_rp_read_data_block_size { | |||
| 1074 | __le16 num_blocks; | 1074 | __le16 num_blocks; |
| 1075 | } __packed; | 1075 | } __packed; |
| 1076 | 1076 | ||
| 1077 | #define HCI_OP_READ_LOCAL_CODECS 0x100b | ||
| 1078 | |||
| 1077 | #define HCI_OP_READ_PAGE_SCAN_ACTIVITY 0x0c1b | 1079 | #define HCI_OP_READ_PAGE_SCAN_ACTIVITY 0x0c1b |
| 1078 | struct hci_rp_read_page_scan_activity { | 1080 | struct hci_rp_read_page_scan_activity { |
| 1079 | __u8 status; | 1081 | __u8 status; |
| @@ -1170,6 +1172,8 @@ struct hci_rp_write_remote_amp_assoc { | |||
| 1170 | __u8 phy_handle; | 1172 | __u8 phy_handle; |
| 1171 | } __packed; | 1173 | } __packed; |
| 1172 | 1174 | ||
| 1175 | #define HCI_OP_GET_MWS_TRANSPORT_CONFIG 0x140c | ||
| 1176 | |||
| 1173 | #define HCI_OP_ENABLE_DUT_MODE 0x1803 | 1177 | #define HCI_OP_ENABLE_DUT_MODE 0x1803 |
| 1174 | 1178 | ||
| 1175 | #define HCI_OP_WRITE_SSP_DEBUG_MODE 0x1804 | 1179 | #define HCI_OP_WRITE_SSP_DEBUG_MODE 0x1804 |
diff --git a/include/net/bluetooth/hci_core.h b/include/net/bluetooth/hci_core.h index 996ed065b6c2..b5d5af3aa469 100644 --- a/include/net/bluetooth/hci_core.h +++ b/include/net/bluetooth/hci_core.h | |||
| @@ -203,6 +203,8 @@ struct hci_dev { | |||
| 203 | __u16 page_scan_window; | 203 | __u16 page_scan_window; |
| 204 | __u8 page_scan_type; | 204 | __u8 page_scan_type; |
| 205 | __u8 le_adv_channel_map; | 205 | __u8 le_adv_channel_map; |
| 206 | __u16 le_adv_min_interval; | ||
| 207 | __u16 le_adv_max_interval; | ||
| 206 | __u8 le_scan_type; | 208 | __u8 le_scan_type; |
| 207 | __u16 le_scan_interval; | 209 | __u16 le_scan_interval; |
| 208 | __u16 le_scan_window; | 210 | __u16 le_scan_window; |
| @@ -458,6 +460,7 @@ struct hci_conn_params { | |||
| 458 | enum { | 460 | enum { |
| 459 | HCI_AUTO_CONN_DISABLED, | 461 | HCI_AUTO_CONN_DISABLED, |
| 460 | HCI_AUTO_CONN_REPORT, | 462 | HCI_AUTO_CONN_REPORT, |
| 463 | HCI_AUTO_CONN_DIRECT, | ||
| 461 | HCI_AUTO_CONN_ALWAYS, | 464 | HCI_AUTO_CONN_ALWAYS, |
| 462 | HCI_AUTO_CONN_LINK_LOSS, | 465 | HCI_AUTO_CONN_LINK_LOSS, |
| 463 | } auto_connect; | 466 | } auto_connect; |
diff --git a/include/net/bluetooth/mgmt.h b/include/net/bluetooth/mgmt.h index 623d5203c592..414cd2f9a437 100644 --- a/include/net/bluetooth/mgmt.h +++ b/include/net/bluetooth/mgmt.h | |||
| @@ -87,7 +87,7 @@ struct mgmt_rp_read_index_list { | |||
| 87 | #define MGMT_SETTING_CONNECTABLE 0x00000002 | 87 | #define MGMT_SETTING_CONNECTABLE 0x00000002 |
| 88 | #define MGMT_SETTING_FAST_CONNECTABLE 0x00000004 | 88 | #define MGMT_SETTING_FAST_CONNECTABLE 0x00000004 |
| 89 | #define MGMT_SETTING_DISCOVERABLE 0x00000008 | 89 | #define MGMT_SETTING_DISCOVERABLE 0x00000008 |
| 90 | #define MGMT_SETTING_PAIRABLE 0x00000010 | 90 | #define MGMT_SETTING_BONDABLE 0x00000010 |
| 91 | #define MGMT_SETTING_LINK_SECURITY 0x00000020 | 91 | #define MGMT_SETTING_LINK_SECURITY 0x00000020 |
| 92 | #define MGMT_SETTING_SSP 0x00000040 | 92 | #define MGMT_SETTING_SSP 0x00000040 |
| 93 | #define MGMT_SETTING_BREDR 0x00000080 | 93 | #define MGMT_SETTING_BREDR 0x00000080 |
| @@ -131,7 +131,7 @@ struct mgmt_cp_set_discoverable { | |||
| 131 | 131 | ||
| 132 | #define MGMT_OP_SET_FAST_CONNECTABLE 0x0008 | 132 | #define MGMT_OP_SET_FAST_CONNECTABLE 0x0008 |
| 133 | 133 | ||
| 134 | #define MGMT_OP_SET_PAIRABLE 0x0009 | 134 | #define MGMT_OP_SET_BONDABLE 0x0009 |
| 135 | 135 | ||
| 136 | #define MGMT_OP_SET_LINK_SECURITY 0x000A | 136 | #define MGMT_OP_SET_LINK_SECURITY 0x000A |
| 137 | 137 | ||
diff --git a/include/net/nfc/digital.h b/include/net/nfc/digital.h index bdf55c3b7a19..d9a5cf7ac1c4 100644 --- a/include/net/nfc/digital.h +++ b/include/net/nfc/digital.h | |||
| @@ -49,6 +49,7 @@ enum { | |||
| 49 | NFC_DIGITAL_FRAMING_NFCA_SHORT = 0, | 49 | NFC_DIGITAL_FRAMING_NFCA_SHORT = 0, |
| 50 | NFC_DIGITAL_FRAMING_NFCA_STANDARD, | 50 | NFC_DIGITAL_FRAMING_NFCA_STANDARD, |
| 51 | NFC_DIGITAL_FRAMING_NFCA_STANDARD_WITH_CRC_A, | 51 | NFC_DIGITAL_FRAMING_NFCA_STANDARD_WITH_CRC_A, |
| 52 | NFC_DIGITAL_FRAMING_NFCA_ANTICOL_COMPLETE, | ||
| 52 | 53 | ||
| 53 | NFC_DIGITAL_FRAMING_NFCA_T1T, | 54 | NFC_DIGITAL_FRAMING_NFCA_T1T, |
| 54 | NFC_DIGITAL_FRAMING_NFCA_T2T, | 55 | NFC_DIGITAL_FRAMING_NFCA_T2T, |
| @@ -126,6 +127,15 @@ typedef void (*nfc_digital_cmd_complete_t)(struct nfc_digital_dev *ddev, | |||
| 126 | * the NFC-DEP ATR_REQ command through cb. The digital stack deducts the RF | 127 | * the NFC-DEP ATR_REQ command through cb. The digital stack deducts the RF |
| 127 | * tech by analyzing the SoD of the frame containing the ATR_REQ command. | 128 | * tech by analyzing the SoD of the frame containing the ATR_REQ command. |
| 128 | * This is an asynchronous function. | 129 | * This is an asynchronous function. |
| 130 | * @tg_listen_md: If supported, put the device in automatic listen mode with | ||
| 131 | * mode detection but without automatic anti-collision. In this mode, the | ||
| 132 | * device automatically detects the RF technology. What the actual | ||
| 133 | * RF technology is can be retrieved by calling @tg_get_rf_tech. | ||
| 134 | * The digital stack will then perform the appropriate anti-collision | ||
| 135 | * sequence. This is an asynchronous function. | ||
| 136 | * @tg_get_rf_tech: Required when @tg_listen_md is supported, unused otherwise. | ||
| 137 | * Return the RF Technology that was detected by the @tg_listen_md call. | ||
| 138 | * This is a synchronous function. | ||
| 129 | * | 139 | * |
| 130 | * @switch_rf: Turns device radio on or off. The stack does not call explicitly | 140 | * @switch_rf: Turns device radio on or off. The stack does not call explicitly |
| 131 | * switch_rf to turn the radio on. A call to in|tg_configure_hw must turn | 141 | * switch_rf to turn the radio on. A call to in|tg_configure_hw must turn |
| @@ -160,6 +170,9 @@ struct nfc_digital_ops { | |||
| 160 | struct digital_tg_mdaa_params *mdaa_params, | 170 | struct digital_tg_mdaa_params *mdaa_params, |
| 161 | u16 timeout, nfc_digital_cmd_complete_t cb, | 171 | u16 timeout, nfc_digital_cmd_complete_t cb, |
| 162 | void *arg); | 172 | void *arg); |
| 173 | int (*tg_listen_md)(struct nfc_digital_dev *ddev, u16 timeout, | ||
| 174 | nfc_digital_cmd_complete_t cb, void *arg); | ||
| 175 | int (*tg_get_rf_tech)(struct nfc_digital_dev *ddev, u8 *rf_tech); | ||
| 163 | 176 | ||
| 164 | int (*switch_rf)(struct nfc_digital_dev *ddev, bool on); | 177 | int (*switch_rf)(struct nfc_digital_dev *ddev, bool on); |
| 165 | void (*abort_cmd)(struct nfc_digital_dev *ddev); | 178 | void (*abort_cmd)(struct nfc_digital_dev *ddev); |
diff --git a/include/net/nfc/hci.h b/include/net/nfc/hci.h index 61286db54388..7ee8f4cc610b 100644 --- a/include/net/nfc/hci.h +++ b/include/net/nfc/hci.h | |||
| @@ -37,6 +37,7 @@ struct nfc_hci_ops { | |||
| 37 | int (*xmit) (struct nfc_hci_dev *hdev, struct sk_buff *skb); | 37 | int (*xmit) (struct nfc_hci_dev *hdev, struct sk_buff *skb); |
| 38 | int (*start_poll) (struct nfc_hci_dev *hdev, | 38 | int (*start_poll) (struct nfc_hci_dev *hdev, |
| 39 | u32 im_protocols, u32 tm_protocols); | 39 | u32 im_protocols, u32 tm_protocols); |
| 40 | void (*stop_poll) (struct nfc_hci_dev *hdev); | ||
| 40 | int (*dep_link_up)(struct nfc_hci_dev *hdev, struct nfc_target *target, | 41 | int (*dep_link_up)(struct nfc_hci_dev *hdev, struct nfc_target *target, |
| 41 | u8 comm_mode, u8 *gb, size_t gb_len); | 42 | u8 comm_mode, u8 *gb, size_t gb_len); |
| 42 | int (*dep_link_down)(struct nfc_hci_dev *hdev); | 43 | int (*dep_link_down)(struct nfc_hci_dev *hdev); |
