aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2014-07-10 23:36:39 -0400
committerJohan Hedberg <johan.hedberg@intel.com>2014-07-11 06:54:17 -0400
commit3ad254f7f6fd3b66ce47a156cbb92cb02002103e (patch)
treed20981eab1de9d1add4037cc33e5537b90189600
parentf49daa8190ebf25eae907048266b590a9cdccb95 (diff)
Bluetooth: Move struct hci_sec_filter next to its user
There is only single location using struct hci_sec_filter and with that there is no point in putting this declaration into a global header file. So move it right next to its user and make the code a lot more simpler. Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
-rw-r--r--include/net/bluetooth/hci_core.h9
-rw-r--r--net/bluetooth/hci_sock.c8
2 files changed, 8 insertions, 9 deletions
diff --git a/include/net/bluetooth/hci_core.h b/include/net/bluetooth/hci_core.h
index 5c52a17d6326..e1930749fac7 100644
--- a/include/net/bluetooth/hci_core.h
+++ b/include/net/bluetooth/hci_core.h
@@ -1360,15 +1360,6 @@ struct hci_pinfo {
1360 unsigned short channel; 1360 unsigned short channel;
1361}; 1361};
1362 1362
1363/* HCI security filter */
1364#define HCI_SFLT_MAX_OGF 5
1365
1366struct hci_sec_filter {
1367 __u32 type_mask;
1368 __u32 event_mask[2];
1369 __u32 ocf_mask[HCI_SFLT_MAX_OGF + 1][4];
1370};
1371
1372/* ----- HCI requests ----- */ 1363/* ----- HCI requests ----- */
1373#define HCI_REQ_DONE 0 1364#define HCI_REQ_DONE 0
1374#define HCI_REQ_PEND 1 1365#define HCI_REQ_PEND 1
diff --git a/net/bluetooth/hci_sock.c b/net/bluetooth/hci_sock.c
index c64728d571ae..7805fd1b4a78 100644
--- a/net/bluetooth/hci_sock.c
+++ b/net/bluetooth/hci_sock.c
@@ -41,6 +41,14 @@ static inline int hci_test_bit(int nr, void *addr)
41} 41}
42 42
43/* Security filter */ 43/* Security filter */
44#define HCI_SFLT_MAX_OGF 5
45
46struct hci_sec_filter {
47 __u32 type_mask;
48 __u32 event_mask[2];
49 __u32 ocf_mask[HCI_SFLT_MAX_OGF + 1][4];
50};
51
44static struct hci_sec_filter hci_sec_filter = { 52static struct hci_sec_filter hci_sec_filter = {
45 /* Packet types */ 53 /* Packet types */
46 0x10, 54 0x10,