]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
OMAP2/3 clock: convert mask_to_shift() to __ffs()
authorPaul Walmsley <paul@pwsan.com>
Fri, 28 Mar 2008 06:26:12 +0000 (00:26 -0600)
committerTony Lindgren <tony@atomide.com>
Fri, 28 Mar 2008 09:35:16 +0000 (11:35 +0200)
commitf417e171cd2d2bd0302c8f420ee97295a165a39c
tree51732d686af65ede6658fd0de163e01f32bfca07
parentf2be22c05dd385c3f1a3189bbc7d30206ee9ab0a
OMAP2/3 clock: convert mask_to_shift() to __ffs()

In OMAP2/3 clock code, we've used mask_to_shift() to convert bitmasks
into shift values, via "ffs(mask) - 1".  It turns out that there is
already a Linux idiom for this in asm/bitops.h: __ffs().  (Not to be
confused with ffs(), of course.  You wouldn't do that, would you?)
When in Rome, do as the Romans.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/clock.c
arch/arm/mach-omap2/clock.h
arch/arm/mach-omap2/clock24xx.c
arch/arm/mach-omap2/clock34xx.c