On Tue, 29 Mar 2011 10:47:04 +0800 Lei Wen <adrian.w...@gmail.com> wrote:
> Hi Scott, > > On Tue, Mar 29, 2011 at 12:05 AM, Scott Wood <scottw...@freescale.com> wrote: > > What does this do that setbits*/clrbits* don't? > > Those and*/or* include the dmb() operation included in the read*/write*, which > is not included in the __raw_read*/__raw_write* that setbits*/clrbits* refer > to. > I think it's better to keep another instance to set the bit, since > there is read* and __raw_read* > exist and have difference. But why are setbits/clrbits using raw accesses? That's not how they're defined on powerpc, which is where these accessors originated. I suspect they were defined that way out of laziness from before ARM made a distinction between raw and non-raw accessors, and it is now a bug in setbits/clrbits (and out_be*, in_le*, etc) which should be fixed rather than introducing an alternative. And then if you want a raw version of these functions, introduce raw_setbits_le32, raw_in_le16, etc. -Scott _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot