From 351d690f1a09e062ef951ac406ee571e1f1fe3e6 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Wed, 18 Nov 2020 13:38:17 +0100 Subject: wireless: fix passing bridge name for vlan hotplug pass-through When preparing the interface for hotplug add, pass the bridge device back to the caller, since it may not match the original device Signed-off-by: Felix Fietkau --- vlandev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'vlandev.c') diff --git a/vlandev.c b/vlandev.c index 7efb5f4..0c0caab 100644 --- a/vlandev.c +++ b/vlandev.c @@ -89,7 +89,7 @@ vlandev_hotplug_del(struct device *dev, struct device *member) } static int -vlandev_hotplug_prepare(struct device *dev) +vlandev_hotplug_prepare(struct device *dev, struct device **bridge_dev) { struct vlandev_device *mvdev = container_of(dev, struct vlandev_device, dev); @@ -97,7 +97,7 @@ vlandev_hotplug_prepare(struct device *dev) if (!dev || !dev->hotplug_ops) return UBUS_STATUS_NOT_SUPPORTED; - return dev->hotplug_ops->prepare(dev); + return dev->hotplug_ops->prepare(dev, bridge_dev); } static void vlandev_hotplug_check(struct vlandev_device *mvdev) -- cgit v1.2.1