linux-hyperv.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] hypverv/vmbus: include linux/bitops.h
@ 2021-10-18 13:19 Arnd Bergmann
  2021-10-19 13:46 ` Wei Liu
  0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2021-10-18 13:19 UTC (permalink / raw)
  To: K. Y. Srinivasan, Haiyang Zhang, Stephen Hemminger, Wei Liu, Dexuan Cui
  Cc: Arnd Bergmann, Andres Beltran, linux-hyperv, linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

On arm64 randconfig builds, hyperv sometimes fails with this
error:

In file included from drivers/hv/hv_trace.c:3:
In file included from drivers/hv/hyperv_vmbus.h:16:
In file included from arch/arm64/include/asm/sync_bitops.h:5:
arch/arm64/include/asm/bitops.h:11:2: error: only <linux/bitops.h> can be included directly
In file included from include/asm-generic/bitops/hweight.h:5:
include/asm-generic/bitops/arch_hweight.h:9:9: error: implicit declaration of function '__sw_hweight32' [-Werror,-Wimplicit-function-declaration]
include/asm-generic/bitops/atomic.h:17:7: error: implicit declaration of function 'BIT_WORD' [-Werror,-Wimplicit-function-declaration]

Include the correct header first.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
Not sure what started this, I first saw it on linux-next-20211015
---
 drivers/hv/hyperv_vmbus.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/hv/hyperv_vmbus.h b/drivers/hv/hyperv_vmbus.h
index 42f3d9d123a1..d030577ad6a2 100644
--- a/drivers/hv/hyperv_vmbus.h
+++ b/drivers/hv/hyperv_vmbus.h
@@ -13,6 +13,7 @@
 #define _HYPERV_VMBUS_H
 
 #include <linux/list.h>
+#include <linux/bitops.h>
 #include <asm/sync_bitops.h>
 #include <asm/hyperv-tlfs.h>
 #include <linux/atomic.h>
-- 
2.29.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] hypverv/vmbus: include linux/bitops.h
  2021-10-18 13:19 [PATCH] hypverv/vmbus: include linux/bitops.h Arnd Bergmann
@ 2021-10-19 13:46 ` Wei Liu
  0 siblings, 0 replies; 2+ messages in thread
From: Wei Liu @ 2021-10-19 13:46 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: K. Y. Srinivasan, Haiyang Zhang, Stephen Hemminger, Wei Liu,
	Dexuan Cui, Arnd Bergmann, Andres Beltran, linux-hyperv,
	linux-kernel

On Mon, Oct 18, 2021 at 03:19:08PM +0200, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> On arm64 randconfig builds, hyperv sometimes fails with this
> error:
> 
> In file included from drivers/hv/hv_trace.c:3:
> In file included from drivers/hv/hyperv_vmbus.h:16:
> In file included from arch/arm64/include/asm/sync_bitops.h:5:
> arch/arm64/include/asm/bitops.h:11:2: error: only <linux/bitops.h> can be included directly
> In file included from include/asm-generic/bitops/hweight.h:5:
> include/asm-generic/bitops/arch_hweight.h:9:9: error: implicit declaration of function '__sw_hweight32' [-Werror,-Wimplicit-function-declaration]
> include/asm-generic/bitops/atomic.h:17:7: error: implicit declaration of function 'BIT_WORD' [-Werror,-Wimplicit-function-declaration]
> 
> Include the correct header first.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Applied to hyperv-fixes. Thanks.

> ---
> Not sure what started this, I first saw it on linux-next-20211015
> ---
>  drivers/hv/hyperv_vmbus.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/hv/hyperv_vmbus.h b/drivers/hv/hyperv_vmbus.h
> index 42f3d9d123a1..d030577ad6a2 100644
> --- a/drivers/hv/hyperv_vmbus.h
> +++ b/drivers/hv/hyperv_vmbus.h
> @@ -13,6 +13,7 @@
>  #define _HYPERV_VMBUS_H
>  
>  #include <linux/list.h>
> +#include <linux/bitops.h>
>  #include <asm/sync_bitops.h>
>  #include <asm/hyperv-tlfs.h>
>  #include <linux/atomic.h>
> -- 
> 2.29.2
> 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-10-19 13:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-18 13:19 [PATCH] hypverv/vmbus: include linux/bitops.h Arnd Bergmann
2021-10-19 13:46 ` Wei Liu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).