diff options
author | Felix Fietkau <nbd@openwrt.org> | 2011-10-05 16:10:21 +0200 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2011-10-05 16:10:21 +0200 |
commit | 69485f59ad87c5f3a706248b62c4205e9e659d8b (patch) | |
tree | 0454262c46856a1e49b34615c24a4518322b816d /device.c | |
parent | 5bf6467af8d59d0b0794413204ad385367221e22 (diff) |
use device_(add|remove)_user when replacing devices
Diffstat (limited to 'device.c')
-rw-r--r-- | device.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -337,8 +337,8 @@ device_replace(struct device *dev, struct device *odev) device_set_present(odev, false); list_for_each_entry_safe(dep, tmp, &odev->users, list) { - list_move_tail(&dep->list, &dev->users); - dep->dev = dev; + device_remove_user(dep); + device_add_user(dep, dev); } device_free(odev); |