File tree Expand file tree Collapse file tree 3 files changed +8
-7
lines changed
drivers/net/wireless/mediatek/mt76/mt7921 Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -108,7 +108,7 @@ mt7921_mac_init_band(struct mt7921_dev *dev, u8 band)
108108 mt76_clear (dev , MT_DMA_DCR0 (band ), MT_DMA_DCR0_RXD_G5_EN );
109109}
110110
111- void mt7921_mac_init (struct mt7921_dev * dev )
111+ int mt7921_mac_init (struct mt7921_dev * dev )
112112{
113113 int i ;
114114
@@ -124,7 +124,7 @@ void mt7921_mac_init(struct mt7921_dev *dev)
124124 for (i = 0 ; i < 2 ; i ++ )
125125 mt7921_mac_init_band (dev , i );
126126
127- mt76_connac_mcu_set_rts_thresh (& dev -> mt76 , 0x92b , 0 );
127+ return mt76_connac_mcu_set_rts_thresh (& dev -> mt76 , 0x92b , 0 );
128128}
129129
130130static int mt7921_init_hardware (struct mt7921_dev * dev )
@@ -164,9 +164,7 @@ static int mt7921_init_hardware(struct mt7921_dev *dev)
164164 dev -> mt76 .global_wcid .tx_info |= MT_WCID_TX_INFO_SET ;
165165 rcu_assign_pointer (dev -> mt76 .wcid [idx ], & dev -> mt76 .global_wcid );
166166
167- mt7921_mac_init (dev );
168-
169- return 0 ;
167+ return mt7921_mac_init (dev );
170168}
171169
172170int mt7921_register_device (struct mt7921_dev * dev )
Original file line number Diff line number Diff line change @@ -1298,7 +1298,10 @@ mt7921_mac_reset(struct mt7921_dev *dev)
12981298 if (err )
12991299 return err ;
13001300
1301- mt7921_mac_init (dev );
1301+ err = mt7921_mac_init (dev );
1302+ if (err )
1303+ return err ;
1304+
13021305 return __mt7921_start (& dev -> phy );
13031306}
13041307
Original file line number Diff line number Diff line change @@ -319,7 +319,7 @@ static inline bool mt7921_dma_need_reinit(struct mt7921_dev *dev)
319319 return !mt76_get_field (dev , MT_WFDMA_DUMMY_CR , MT_WFDMA_NEED_REINIT );
320320}
321321
322- void mt7921_mac_init (struct mt7921_dev * dev );
322+ int mt7921_mac_init (struct mt7921_dev * dev );
323323bool mt7921_mac_wtbl_update (struct mt7921_dev * dev , int idx , u32 mask );
324324void mt7921_mac_reset_counters (struct mt7921_phy * phy );
325325void mt7921_mac_write_txwi (struct mt7921_dev * dev , __le32 * txwi ,
You can’t perform that action at this time.
0 commit comments