Skip to contentSkip to conversation

using ieee80211_restart_hw()

DISCUSSION Arend van Spriel 2 participants 2 messages Jun 3, 2013

lore
Share & tools
lore
#0 lore raw

Hi Johannes,

In brcmsmac a fatal error in the device results in calling ieee80211_restart_hw(). This was done under the assumption that mac80211 would reconfigure everything doing .start(), .add_interface() etc, but looking at a log in redhat bugzilla makes me suspicious about that.

The only reason I could find in ieee80211_reconfig is that local->open_count would be zero, right?

At the time of the fatal error AMPDU packets were being transmitted so I assume local->open_count would *not* be zero as it seems to match the state of the netdev interface.

Regards,
Arend

---8<--------------------------------------------------------------

	/* everything else happens only if HW was up & running */
	if (!local->open_count)
		goto wake_up;

	/*
	 * Upon resume hardware can sometimes be goofy due to
	 * various platform / driver / bus issues, so restarting
	 * the device may at times not work immediately. Propagate
	 * the error.
	 */
	res = drv_start(local);
#1 lore raw

Hi,

Quoted 11 lines

In brcmsmac a fatal error in the device results in calling ieee80211_restart_hw(). This was done under the assumption that mac80211 would reconfigure everything doing .start(), .add_interface() etc, but looking at a log in redhat bugzilla makes me suspicious about that.

The only reason I could find in ieee80211_reconfig is that local->open_count would be zero, right?

At the time of the fatal error AMPDU packets were being transmitted so I assume local->open_count would *not* be zero as it seems to match the state of the netdev interface.

Not sure what you're asking ... restart_hw() should reconfigure everything just like you said, but maybe your driver is not cleaning up properly before the restart so something in there fails? restart_hw() expects to only do start/add_interface etc, not remove_interface/stop etc.

johannes