Re: [RFC][PATCH] mfd: mc13xxx-core: put mutex lock down tomc13xxx_reg_rmw function
From: Axel Lin
Date: Thu May 05 2011 - 11:27:26 EST
> I havn't looked deeply, but I guess this can have unwanted side effects
> here. Before you had:
>
> lock()
> do(something)
> do(something, else, that, needs, rmw)
> unlock()
>
> and you introduced an unlock()/lock() between these two do()s.
>
Indeed, you are right. I cannot change it this way.
> I'm not convinced this change is good, though I agree that
>
> lock()
> rmw(...)
> unlock()
>
> looks ugly, but imho this can better be fixed by adding a wrapper for
> that sequence if you really want.
>
> Best regards
> Uwe
>
> --
> Pengutronix e.K. | Uwe Kleine-König |
> Industrial Linux Solutions | http://www.pengutronix.de/ |
>
--
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/