* [PATCH] tools: hv: remove unused rte_smp_mb()
@ 2026-10-11 22:33 Sasha Levin
2026-10-12 17:51 ` Hamza Mahfooz
2026-10-13 5:08 ` Saurabh Singh Sengar
0 siblings, 2 replies; 3+ messages in thread
From: Sasha Levin @ 2026-10-11 22:33 UTC (permalink / raw)
To: K. Y. Srinivasan, Haiyang Zhang, Wei Liu, Dexuan Cui, Long Li,
Nathan Chancellor, Nick Desaulniers, Bill Wendling, Justin Stitt,
Mary Hardy, Saurabh Sengar, Greg Kroah-Hartman
Cc: Sasha Levin, linux-hyperv, linux-kernel, llvm
rte_smp_mb() has never been used, and its "static inline __always_inline"
declares inline twice, so clang warns:
vmbus_bufring.c:61:15: warning: duplicate 'inline' declaration specifier [-Wduplicate-decl-specifier]
vmbus_bufring.c:62:1: warning: unused function 'rte_smp_mb' [-Wunused-function]
Remove it.
Fixes: 45bab4d746510 ("tools: hv: Add vmbus_bufring")
Assisted-by: LLM
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
tools/hv/vmbus_bufring.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/tools/hv/vmbus_bufring.c b/tools/hv/vmbus_bufring.c
index bac32c1109df8..23542e59a2ee9 100644
--- a/tools/hv/vmbus_bufring.c
+++ b/tools/hv/vmbus_bufring.c
@@ -58,12 +58,6 @@ void vmbus_br_setup(struct vmbus_br *br, void *buf, unsigned int blen)
br->dsize = blen - sizeof(struct vmbus_bufring);
}
-static inline __always_inline void
-rte_smp_mb(void)
-{
- asm volatile("lock addl $0, -128(%%rsp); " ::: "memory");
-}
-
static inline int
rte_atomic32_cmpset(volatile uint32_t *dst, uint32_t exp, uint32_t src)
{
--
2.53.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] tools: hv: remove unused rte_smp_mb()
2026-10-11 22:33 [PATCH] tools: hv: remove unused rte_smp_mb() Sasha Levin
@ 2026-10-12 17:51 ` Hamza Mahfooz
2026-10-13 5:08 ` Saurabh Singh Sengar
1 sibling, 0 replies; 3+ messages in thread
From: Hamza Mahfooz @ 2026-10-12 17:51 UTC (permalink / raw)
To: Sasha Levin
Cc: K. Y. Srinivasan, Haiyang Zhang, Wei Liu, Dexuan Cui, Long Li,
Nathan Chancellor, Nick Desaulniers, Bill Wendling, Justin Stitt,
Mary Hardy, Saurabh Sengar, Greg Kroah-Hartman, linux-hyperv,
linux-kernel, llvm
On Sun, Oct 11, 2026 at 06:33:40PM -0400, Sasha Levin wrote:
> rte_smp_mb() has never been used, and its "static inline __always_inline"
> declares inline twice, so clang warns:
>
> vmbus_bufring.c:61:15: warning: duplicate 'inline' declaration specifier [-Wduplicate-decl-specifier]
> vmbus_bufring.c:62:1: warning: unused function 'rte_smp_mb' [-Wunused-function]
>
> Remove it.
>
> Fixes: 45bab4d746510 ("tools: hv: Add vmbus_bufring")
> Assisted-by: LLM
> Signed-off-by: Sasha Levin <sashal@kernel.org>
Reviewed-by: Hamza Mahfooz <hamzamahfooz@linux.microsoft.com>
> ---
> tools/hv/vmbus_bufring.c | 6 ------
> 1 file changed, 6 deletions(-)
>
> diff --git a/tools/hv/vmbus_bufring.c b/tools/hv/vmbus_bufring.c
> index bac32c1109df8..23542e59a2ee9 100644
> --- a/tools/hv/vmbus_bufring.c
> +++ b/tools/hv/vmbus_bufring.c
> @@ -58,12 +58,6 @@ void vmbus_br_setup(struct vmbus_br *br, void *buf, unsigned int blen)
> br->dsize = blen - sizeof(struct vmbus_bufring);
> }
>
> -static inline __always_inline void
> -rte_smp_mb(void)
> -{
> - asm volatile("lock addl $0, -128(%%rsp); " ::: "memory");
> -}
> -
> static inline int
> rte_atomic32_cmpset(volatile uint32_t *dst, uint32_t exp, uint32_t src)
> {
> --
> 2.53.0
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] tools: hv: remove unused rte_smp_mb()
2026-10-11 22:33 [PATCH] tools: hv: remove unused rte_smp_mb() Sasha Levin
2026-10-12 17:51 ` Hamza Mahfooz
@ 2026-10-13 5:08 ` Saurabh Singh Sengar
1 sibling, 0 replies; 3+ messages in thread
From: Saurabh Singh Sengar @ 2026-10-13 5:08 UTC (permalink / raw)
To: Sasha Levin
Cc: K. Y. Srinivasan, Haiyang Zhang, Wei Liu, Dexuan Cui, Long Li,
Nathan Chancellor, Nick Desaulniers, Bill Wendling, Justin Stitt,
Mary Hardy, Greg Kroah-Hartman, linux-hyperv, linux-kernel, llvm
On Sun, Oct 11, 2026 at 06:33:40PM -0400, Sasha Levin wrote:
> rte_smp_mb() has never been used, and its "static inline __always_inline"
> declares inline twice, so clang warns:
>
> vmbus_bufring.c:61:15: warning: duplicate 'inline' declaration specifier [-Wduplicate-decl-specifier]
> vmbus_bufring.c:62:1: warning: unused function 'rte_smp_mb' [-Wunused-function]
>
> Remove it.
>
> Fixes: 45bab4d746510 ("tools: hv: Add vmbus_bufring")
> Assisted-by: LLM
> Signed-off-by: Sasha Levin <sashal@kernel.org>
> ---
> tools/hv/vmbus_bufring.c | 6 ------
> 1 file changed, 6 deletions(-)
>
> diff --git a/tools/hv/vmbus_bufring.c b/tools/hv/vmbus_bufring.c
> index bac32c1109df8..23542e59a2ee9 100644
> --- a/tools/hv/vmbus_bufring.c
> +++ b/tools/hv/vmbus_bufring.c
> @@ -58,12 +58,6 @@ void vmbus_br_setup(struct vmbus_br *br, void *buf, unsigned int blen)
> br->dsize = blen - sizeof(struct vmbus_bufring);
> }
>
> -static inline __always_inline void
> -rte_smp_mb(void)
> -{
> - asm volatile("lock addl $0, -128(%%rsp); " ::: "memory");
> -}
> -
> static inline int
> rte_atomic32_cmpset(volatile uint32_t *dst, uint32_t exp, uint32_t src)
> {
> --
> 2.53.0
Acked-by: Saurabh Sengar <ssengar@linux.microsoft.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-10-13 5:08 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-11 22:33 [PATCH] tools: hv: remove unused rte_smp_mb() Sasha Levin
2026-10-12 17:51 ` Hamza Mahfooz
2026-10-13 5:08 ` Saurabh Singh Sengar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox