bluetooth.h (69ae5065061c53ded4f49e821646b9bc60ab302a) | bluetooth.h (3f19ffb2f924db5b0925c77818d18ac1f6f08a44) |
---|---|
1/* 2 BlueZ - Bluetooth protocol stack for Linux 3 Copyright (C) 2000-2001 Qualcomm Incorporated 4 Copyright 2023 NXP 5 6 Written 2000,2001 by Maxim Krasnyansky <maxk@qualcomm.com> 7 8 This program is free software; you can redistribute it and/or modify --- 372 unchanged lines hidden (view full) --- 381 unsigned long flags; 382 void (*skb_msg_name)(struct sk_buff *, void *, int *); 383 void (*skb_put_cmsg)(struct sk_buff *, struct msghdr *, struct sock *); 384}; 385 386enum { 387 BT_SK_DEFER_SETUP, 388 BT_SK_SUSPEND, | 1/* 2 BlueZ - Bluetooth protocol stack for Linux 3 Copyright (C) 2000-2001 Qualcomm Incorporated 4 Copyright 2023 NXP 5 6 Written 2000,2001 by Maxim Krasnyansky <maxk@qualcomm.com> 7 8 This program is free software; you can redistribute it and/or modify --- 372 unchanged lines hidden (view full) --- 381 unsigned long flags; 382 void (*skb_msg_name)(struct sk_buff *, void *, int *); 383 void (*skb_put_cmsg)(struct sk_buff *, struct msghdr *, struct sock *); 384}; 385 386enum { 387 BT_SK_DEFER_SETUP, 388 BT_SK_SUSPEND, |
389 BT_SK_PKT_STATUS |
|
389}; 390 391struct bt_sock_list { 392 struct hlist_head head; 393 rwlock_t lock; 394#ifdef CONFIG_PROC_FS 395 int (* custom_seq_show)(struct seq_file *, void *); 396#endif --- 30 unchanged lines hidden (view full) --- 427 u16 reqseq; 428 u16 txseq; 429 u8 retries; 430 __le16 psm; 431 bdaddr_t bdaddr; 432 struct l2cap_chan *chan; 433}; 434 | 390}; 391 392struct bt_sock_list { 393 struct hlist_head head; 394 rwlock_t lock; 395#ifdef CONFIG_PROC_FS 396 int (* custom_seq_show)(struct seq_file *, void *); 397#endif --- 30 unchanged lines hidden (view full) --- 428 u16 reqseq; 429 u16 txseq; 430 u8 retries; 431 __le16 psm; 432 bdaddr_t bdaddr; 433 struct l2cap_chan *chan; 434}; 435 |
435struct sco_ctrl { 436 u8 pkt_status; 437}; 438 | |
439struct hci_dev; 440 441typedef void (*hci_req_complete_t)(struct hci_dev *hdev, u8 status, u16 opcode); 442typedef void (*hci_req_complete_skb_t)(struct hci_dev *hdev, u8 status, 443 u16 opcode, struct sk_buff *skb); 444 445#define HCI_REQ_START BIT(0) 446#define HCI_REQ_SKB BIT(1) --- 14 unchanged lines hidden (view full) --- 461 u16 opcode; 462}; 463 464struct bt_skb_cb { 465 u8 pkt_type; 466 u8 force_active; 467 u16 expect; 468 u8 incoming:1; | 436struct hci_dev; 437 438typedef void (*hci_req_complete_t)(struct hci_dev *hdev, u8 status, u16 opcode); 439typedef void (*hci_req_complete_skb_t)(struct hci_dev *hdev, u8 status, 440 u16 opcode, struct sk_buff *skb); 441 442#define HCI_REQ_START BIT(0) 443#define HCI_REQ_SKB BIT(1) --- 14 unchanged lines hidden (view full) --- 458 u16 opcode; 459}; 460 461struct bt_skb_cb { 462 u8 pkt_type; 463 u8 force_active; 464 u16 expect; 465 u8 incoming:1; |
466 u8 pkt_status:2; |
|
469 union { 470 struct l2cap_ctrl l2cap; | 467 union { 468 struct l2cap_ctrl l2cap; |
471 struct sco_ctrl sco; | |
472 struct hci_ctrl hci; 473 struct mgmt_ctrl mgmt; 474 struct scm_creds creds; 475 }; 476}; 477#define bt_cb(skb) ((struct bt_skb_cb *)((skb)->cb)) 478 479#define hci_skb_pkt_type(skb) bt_cb((skb))->pkt_type | 469 struct hci_ctrl hci; 470 struct mgmt_ctrl mgmt; 471 struct scm_creds creds; 472 }; 473}; 474#define bt_cb(skb) ((struct bt_skb_cb *)((skb)->cb)) 475 476#define hci_skb_pkt_type(skb) bt_cb((skb))->pkt_type |
477#define hci_skb_pkt_status(skb) bt_cb((skb))->pkt_status |
|
480#define hci_skb_expect(skb) bt_cb((skb))->expect 481#define hci_skb_opcode(skb) bt_cb((skb))->hci.opcode 482#define hci_skb_event(skb) bt_cb((skb))->hci.req_event 483#define hci_skb_sk(skb) bt_cb((skb))->hci.sk 484 485static inline struct sk_buff *bt_skb_alloc(unsigned int len, gfp_t how) 486{ 487 struct sk_buff *skb; --- 167 unchanged lines hidden --- | 478#define hci_skb_expect(skb) bt_cb((skb))->expect 479#define hci_skb_opcode(skb) bt_cb((skb))->hci.opcode 480#define hci_skb_event(skb) bt_cb((skb))->hci.req_event 481#define hci_skb_sk(skb) bt_cb((skb))->hci.sk 482 483static inline struct sk_buff *bt_skb_alloc(unsigned int len, gfp_t how) 484{ 485 struct sk_buff *skb; --- 167 unchanged lines hidden --- |