* [PATCH] bitops: fls64: add missing include
@ 2016-04-13 14:18 Raphael Poggi
2016-04-14 7:58 ` Sascha Hauer
0 siblings, 1 reply; 3+ messages in thread
From: Raphael Poggi @ 2016-04-13 14:18 UTC (permalink / raw)
To: barebox; +Cc: Raphael Poggi
Signed-off-by: Raphael Poggi <poggi.raph@gmail.com>
---
include/asm-generic/bitops/fls64.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/asm-generic/bitops/fls64.h b/include/asm-generic/bitops/fls64.h
index 86d403f..e8eff76 100644
--- a/include/asm-generic/bitops/fls64.h
+++ b/include/asm-generic/bitops/fls64.h
@@ -2,6 +2,7 @@
#define _ASM_GENERIC_BITOPS_FLS64_H_
#include <asm/types.h>
+#include <asm-generic/bitops/__fls.h>
/**
* fls64 - find last set bit in a 64-bit word
--
2.1.0
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] bitops: fls64: add missing include
2016-04-13 14:18 [PATCH] bitops: fls64: add missing include Raphael Poggi
@ 2016-04-14 7:58 ` Sascha Hauer
2016-04-15 7:14 ` Raphaël Poggi
0 siblings, 1 reply; 3+ messages in thread
From: Sascha Hauer @ 2016-04-14 7:58 UTC (permalink / raw)
To: Raphael Poggi; +Cc: barebox
On Wed, Apr 13, 2016 at 04:18:58PM +0200, Raphael Poggi wrote:
> Signed-off-by: Raphael Poggi <poggi.raph@gmail.com>
> ---
> include/asm-generic/bitops/fls64.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/include/asm-generic/bitops/fls64.h b/include/asm-generic/bitops/fls64.h
> index 86d403f..e8eff76 100644
> --- a/include/asm-generic/bitops/fls64.h
> +++ b/include/asm-generic/bitops/fls64.h
> @@ -2,6 +2,7 @@
> #define _ASM_GENERIC_BITOPS_FLS64_H_
>
> #include <asm/types.h>
> +#include <asm-generic/bitops/__fls.h>
This is wrong. This include must not be here to give the architecture
the chance to provide an optimized version of __fls(), but the generic
version of fls64(). This may not be clear in barebox context since all
users use the generic version, but in the kernel there are some
architectures implementing their own version of __fls() while others use
the generic variant:
arch/mips/include/asm/bitops.h:480:static inline unsigned long __fls(unsigned long word)
...
#include <asm-generic/bitops/fls64.h>
arch/metag/include/asm/bitops.h:118:#include <asm-generic/bitops/__fls.h>
...
#include <asm-generic/bitops/fls64.h>
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] bitops: fls64: add missing include
2016-04-14 7:58 ` Sascha Hauer
@ 2016-04-15 7:14 ` Raphaël Poggi
0 siblings, 0 replies; 3+ messages in thread
From: Raphaël Poggi @ 2016-04-15 7:14 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
2016-04-14 9:58 GMT+02:00 Sascha Hauer <s.hauer@pengutronix.de>:
> On Wed, Apr 13, 2016 at 04:18:58PM +0200, Raphael Poggi wrote:
>> Signed-off-by: Raphael Poggi <poggi.raph@gmail.com>
>> ---
>> include/asm-generic/bitops/fls64.h | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/include/asm-generic/bitops/fls64.h b/include/asm-generic/bitops/fls64.h
>> index 86d403f..e8eff76 100644
>> --- a/include/asm-generic/bitops/fls64.h
>> +++ b/include/asm-generic/bitops/fls64.h
>> @@ -2,6 +2,7 @@
>> #define _ASM_GENERIC_BITOPS_FLS64_H_
>>
>> #include <asm/types.h>
>> +#include <asm-generic/bitops/__fls.h>
>
> This is wrong. This include must not be here to give the architecture
> the chance to provide an optimized version of __fls(), but the generic
> version of fls64(). This may not be clear in barebox context since all
> users use the generic version, but in the kernel there are some
> architectures implementing their own version of __fls() while others use
> the generic variant:
>
> arch/mips/include/asm/bitops.h:480:static inline unsigned long __fls(unsigned long word)
> ...
> #include <asm-generic/bitops/fls64.h>
>
> arch/metag/include/asm/bitops.h:118:#include <asm-generic/bitops/__fls.h>
> ...
> #include <asm-generic/bitops/fls64.h>
>
> Sascha
>
>
>
> --
> Pengutronix e.K. | |
> Industrial Linux Solutions | http://www.pengutronix.de/ |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
> Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
Ok, I understand how it works now,
Thank you,
Raphaël
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-04-15 7:15 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-13 14:18 [PATCH] bitops: fls64: add missing include Raphael Poggi
2016-04-14 7:58 ` Sascha Hauer
2016-04-15 7:14 ` Raphaël Poggi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox