All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vincent Donnefort <vdonnefort@google.com>
To: Mostafa Saleh <smostafa@google.com>
Cc: linux-kernel@vger.kernel.org, kvmarm@lists.linux.dev,
	linux-arm-kernel@lists.infradead.org, maz@kernel.org,
	oupton@kernel.org, seiden@linux.ibm.com, joey.gouly@arm.com,
	suzuki.poulose@arm.com, yuzenghui@huawei.com,
	catalin.marinas@arm.com, will@kernel.org, tabba@google.com
Subject: Re: [PATCH] KVM: arm64: Avoid naming collision in tracing
Date: Mon, 13 Jul 2026 09:05:55 +0100	[thread overview]
Message-ID: <alScY4MJFILO9-xO@google.com> (raw)
In-Reply-To: <alSbqDyV3Koez--u@google.com>

On Mon, Jul 13, 2026 at 09:02:48AM +0100, Vincent Donnefort wrote:
> On Sun, Jul 12, 2026 at 03:38:35PM +0000, Mostafa Saleh wrote:
> > When the hypervisor tracing (CONFIG_NVHE_EL2_TRACING) is disabled, it
> > defines a static inline stub for trace_clock().
> > 
> > However, trace_clock() is already declared as an extern function in
> > linux/trace_clock.h which is pulled in EL2 compilation.
> 
> I am completely unable to reproduce that. CONFIG_NVHE_EL2_TRACING, isn't a
> selectable option, it depends on NVHE_EL2_DEBUG.
> 
> How does your .config look like?
> 
> > 
> > If the file <nvhe/clock.h> is included when CONFIG_NVHE_EL2_TRACING
> > is disabled (by including it manually in setup.c) it will cause:
> > In file included from arch/arm64/kvm/hyp/nvhe/setup.c:22:
> 
> nvhe/clock.h seems already included in setup.c

Ha no appologies, I was looking at the wrong branch.

However I am still enable to reproduce this issue. So I am still interested in
knowing your .defconfig

> 
> > 
> > ./arch/arm64/kvm/hyp/include/nvhe/clock.h:14:19: error: static declaration of ‘trace_clock’ follows non-static declaration
> > 
> >    14 | static inline u64 trace_clock(void) { return 0; }
> > 
> >       |                   ^~~~~~~~~~~
> > 
> > on GCC and a linker error on LLVM (it seems to change the linkage to
> > global)
> > 
> > Although that is not a problem at the moment, as no other files
> > include <nvhe/clock.h>. That does not seem to be the intent of
> > this code and that will cause issues with more users as the SMMUv3
> > driver.
> > 
> > Signed-off-by: Mostafa Saleh <smostafa@google.com>
> > 
> > --

[...]

  reply	other threads:[~2026-07-13  8:06 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-12 15:38 [PATCH] KVM: arm64: Avoid naming collision in tracing Mostafa Saleh
2026-07-12 16:19 ` Fuad Tabba
2026-07-12 19:19   ` Mostafa Saleh
2026-07-12 19:30     ` Fuad Tabba
2026-07-13  8:11       ` Vincent Donnefort
2026-07-13  8:26         ` Mostafa Saleh
2026-07-13  8:34           ` Vincent Donnefort
2026-07-13  8:40             ` Mostafa Saleh
2026-07-13  8:55               ` Vincent Donnefort
2026-07-13  8:02 ` Vincent Donnefort
2026-07-13  8:05   ` Vincent Donnefort [this message]
2026-07-13  8:19     ` Mostafa Saleh

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alScY4MJFILO9-xO@google.com \
    --to=vdonnefort@google.com \
    --cc=catalin.marinas@arm.com \
    --cc=joey.gouly@arm.com \
    --cc=kvmarm@lists.linux.dev \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maz@kernel.org \
    --cc=oupton@kernel.org \
    --cc=seiden@linux.ibm.com \
    --cc=smostafa@google.com \
    --cc=suzuki.poulose@arm.com \
    --cc=tabba@google.com \
    --cc=will@kernel.org \
    --cc=yuzenghui@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.