0a4a8ba0e1a511eceef19165b02ec506dcc1ed7d
[openwrt/staging/981213.git] /
1 From: Lorenzo Bianconi <lorenzo@kernel.org>
2 Date: Mon, 18 Sep 2023 12:29:07 +0200
3 Subject: [PATCH] net: ethernet: mtk_wed: rename mtk_rxbm_desc in
4 mtk_wed_bm_desc
5
6 Rename mtk_rxbm_desc structure in mtk_wed_bm_desc since it will be used
7 even on tx side by MT7988 SoC.
8
9 Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
10 Signed-off-by: Paolo Abeni <pabeni@redhat.com>
11 ---
12
13 --- a/drivers/net/ethernet/mediatek/mtk_wed.c
14 +++ b/drivers/net/ethernet/mediatek/mtk_wed.c
15 @@ -599,7 +599,7 @@ mtk_wed_free_tx_buffer(struct mtk_wed_device
16 static int
17 mtk_wed_rx_buffer_alloc(struct mtk_wed_device *dev)
18 {
19 - struct mtk_rxbm_desc *desc;
20 + struct mtk_wed_bm_desc *desc;
21 dma_addr_t desc_phys;
22
23 dev->rx_buf_ring.size = dev->wlan.rx_nbuf;
24 @@ -619,7 +619,7 @@ mtk_wed_rx_buffer_alloc(struct mtk_wed_d
25 static void
26 mtk_wed_free_rx_buffer(struct mtk_wed_device *dev)
27 {
28 - struct mtk_rxbm_desc *desc = dev->rx_buf_ring.desc;
29 + struct mtk_wed_bm_desc *desc = dev->rx_buf_ring.desc;
30
31 if (!desc)
32 return;
33 --- a/include/linux/soc/mediatek/mtk_wed.h
34 +++ b/include/linux/soc/mediatek/mtk_wed.h
35 @@ -45,7 +45,7 @@ enum mtk_wed_wo_cmd {
36 MTK_WED_WO_CMD_WED_END
37 };
38
39 -struct mtk_rxbm_desc {
40 +struct mtk_wed_bm_desc {
41 __le32 buf0;
42 __le32 token;
43 } __packed __aligned(4);
44 @@ -109,7 +109,7 @@ struct mtk_wed_device {
45
46 struct {
47 int size;
48 - struct mtk_rxbm_desc *desc;
49 + struct mtk_wed_bm_desc *desc;
50 dma_addr_t desc_phys;
51 } rx_buf_ring;
52