3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-12-22 21:22:37 +01:00

device: Allow switching mode even if station is busy

Since device will no longer be aware of what is happening on the station
interface, we should allow switching modes in any situation
This commit is contained in:
Denis Kenzior 2018-09-04 23:52:12 -05:00
parent 25f36f5644
commit f61747f011

View File

@ -61,15 +61,6 @@ struct device {
static uint32_t netdev_watch; static uint32_t netdev_watch;
/* TODO: Remove when Station/Device is split */
static bool device_is_busy(struct device *device)
{
if (!device->powered || !device->station)
return false;
return station_is_busy(device->station);
}
static void device_ap_roam_frame_event(struct netdev *netdev, static void device_ap_roam_frame_event(struct netdev *netdev,
const struct mmpdu_header *hdr, const struct mmpdu_header *hdr,
const void *body, size_t body_len, const void *body, size_t body_len,
@ -448,10 +439,6 @@ static struct l_dbus_message *device_property_set_mode(struct l_dbus *dbus,
return NULL; return NULL;
} }
/* TODO: Special case, remove when Device/Station split is made */
if (iftype != NETDEV_IFTYPE_STATION && device_is_busy(device))
return dbus_error_busy(message);
cb_data = l_new(struct set_generic_cb_data, 1); cb_data = l_new(struct set_generic_cb_data, 1);
cb_data->device = device; cb_data->device = device;
cb_data->dbus = dbus; cb_data->dbus = dbus;