Re: [PATCHv2] backing-dev: fix wakeup timer races with bdi_unregister()

From: Namjae Jeon
Date: Thu Jan 19 2012 - 18:46:56 EST


> Â Â Â Â Â Â Â Âbdi_debug_unregister(bdi);
> - Â Â Â Â Â Â Â device_unregister(bdi->dev);
> +
> + Â Â Â Â Â Â Â spin_lock_bh(&bdi->wb_lock);
> Â Â Â Â Â Â Â Âbdi->dev = NULL;
> + Â Â Â Â Â Â Â spin_unlock_bh(&bdi->wb_lock);
Hi.
Would you explain me why you add spinlock in here ?
Thanks.
> +
> + Â Â Â Â Â Â Â device_unregister(dev);
> Â Â Â Â}
> Â}
> ÂEXPORT_SYMBOL(bdi_unregister);
> --
> 1.7.7.3
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at Âhttp://vger.kernel.org/majordomo-info.html
> Please read the FAQ at Âhttp://www.tux.org/lkml/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/