Messages in this thread | | | Date | Sat, 14 Aug 2010 15:44:55 +0200 | From | Borislav Petkov <> | Subject | Re: [GIT PULL] core/hweight changes for v2.6.35 |
| |
From: "H. Peter Anvin" <hpa@zytor.com> Date: Fri, Aug 13, 2010 at 05:11:14PM -0700
> On 08/13/2010 02:59 PM, Mike Frysinger wrote: > > > > but those targets still define CONFIG_GENERIC_HWEIGHT right ? so at > > the least, we should be wrapping the prototypes in linux/bitops.h with > > that ... > > > > Yes, I guess they do.
Actually, Mike's issue is valid, if I understand it correctly. From looking at <arch/blackfin/include/asm/bitops.h>, Blackfin doesn't need the generic software variants __sw_hweightXX at all, right?
In that case, <include/linux/bitops.h> is pulling in needlessly unresolved symbols for arches which have their hw versions of hweight and don't need sw variants. However, if you want to include <asm-generic/bitops/hweight.h> and benefit from the compile-time evaluation of the const hweight args, you're going to need to rename the hweightXX() functions in <arch/blackfin/include/asm/bitops.h> to __arch_hweightXX but that shouldn't be a problem I guess :).
Let me give your patch from couple of mails ago a quick spin...
-- Regards/Gruss, Boris.
| |