drbd: Fix clearing of MDF_AL_DISABLED
authorPhilipp Reisner <philipp.reisner@linbit.com>
Mon, 1 Oct 2012 16:04:12 +0000 (18:04 +0200)
committerPhilipp Reisner <philipp.reisner@linbit.com>
Fri, 9 Nov 2012 13:11:42 +0000 (14:11 +0100)
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
drivers/block/drbd/drbd_nl.c

index 52258867222a37b3c518fd3726a1268c997fd0e8..298dd3e35e02dde563119bfb33b9e547e95caa5f 100644 (file)
@@ -1226,7 +1226,7 @@ int drbd_adm_disk_opts(struct sk_buff *skb, struct genl_info *info)
        mutex_unlock(&mdev->tconn->conf_update);
 
        if (new_disk_conf->al_updates)
-               mdev->ldev->md.flags &= MDF_AL_DISABLED;
+               mdev->ldev->md.flags &= ~MDF_AL_DISABLED;
        else
                mdev->ldev->md.flags |= MDF_AL_DISABLED;
 
@@ -1615,7 +1615,7 @@ int drbd_adm_attach(struct sk_buff *skb, struct genl_info *info)
           flags. */
 
        if (rcu_dereference(mdev->ldev->disk_conf)->al_updates)
-               mdev->ldev->md.flags &= MDF_AL_DISABLED;
+               mdev->ldev->md.flags &= ~MDF_AL_DISABLED;
        else
                mdev->ldev->md.flags |= MDF_AL_DISABLED;