1 // SPDX-License-Identifier: ISC
2 /*
3  * Copyright (c) 2012 Broadcom Corporation
4  */
5 
6 #ifndef FWSIGNAL_H_
7 #define FWSIGNAL_H_
8 
9 /**
10  * enum brcmf_fws_fifo - fifo indices used by dongle firmware.
11  *
12  * @BRCMF_FWS_FIFO_FIRST: first fifo, ie. background.
13  * @BRCMF_FWS_FIFO_AC_BK: fifo for background traffic.
14  * @BRCMF_FWS_FIFO_AC_BE: fifo for best-effort traffic.
15  * @BRCMF_FWS_FIFO_AC_VI: fifo for video traffic.
16  * @BRCMF_FWS_FIFO_AC_VO: fifo for voice traffic.
17  * @BRCMF_FWS_FIFO_BCMC: fifo for broadcast/multicast (AP only).
18  * @BRCMF_FWS_FIFO_ATIM: fifo for ATIM (AP only).
19  * @BRCMF_FWS_FIFO_COUNT: number of fifos.
20  */
21 enum brcmf_fws_fifo {
22 	BRCMF_FWS_FIFO_FIRST,
23 	BRCMF_FWS_FIFO_AC_BK = BRCMF_FWS_FIFO_FIRST,
24 	BRCMF_FWS_FIFO_AC_BE,
25 	BRCMF_FWS_FIFO_AC_VI,
26 	BRCMF_FWS_FIFO_AC_VO,
27 	BRCMF_FWS_FIFO_BCMC,
28 	BRCMF_FWS_FIFO_ATIM,
29 	BRCMF_FWS_FIFO_COUNT
30 };
31 
32 struct brcmf_fws_info *brcmf_fws_attach(struct brcmf_pub *drvr);
33 void brcmf_fws_detach(struct brcmf_fws_info *fws);
34 void brcmf_fws_debugfs_create(struct brcmf_pub *drvr);
35 bool brcmf_fws_queue_skbs(struct brcmf_fws_info *fws);
36 bool brcmf_fws_fc_active(struct brcmf_fws_info *fws);
37 void brcmf_fws_hdrpull(struct brcmf_if *ifp, s16 siglen, struct sk_buff *skb);
38 int brcmf_fws_process_skb(struct brcmf_if *ifp, struct sk_buff *skb);
39 
40 void brcmf_fws_reset_interface(struct brcmf_if *ifp);
41 void brcmf_fws_add_interface(struct brcmf_if *ifp);
42 void brcmf_fws_del_interface(struct brcmf_if *ifp);
43 void brcmf_fws_bustxcomplete(struct brcmf_fws_info *fws, struct sk_buff *skb,
44 			     bool success);
45 void brcmf_fws_bus_blocked(struct brcmf_pub *drvr, bool flow_blocked);
46 void brcmf_fws_rxreorder(struct brcmf_if *ifp, struct sk_buff *skb);
47 
48 #endif /* FWSIGNAL_H_ */
49