mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "tip-bot2 for Ingo Molnar" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: kernel test robot <lkp@intel.com>, Ingo Molnar <mingo@kernel.org>,
	Johannes Berg <johannes.berg@intel.com>,
	Ofir Bitton <obitton@habana.ai>, Oded Gabbay <ogabbay@kernel.org>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: x86/msr] accel/habanalabs: Add explicit include of <asm/tsc.h> to pick up the rdtsc() definition
Date: Wed, 07 May 2025 18:40:44 -0000	[thread overview]
Message-ID: <174664324501.406.12440553986097050520.tip-bot2@tip-bot2> (raw)
In-Reply-To: <202505080003.0t7ewxGp-lkp@intel.com>

The following commit has been merged into the x86/msr branch of tip:

Commit-ID:     b1d1720321a0fb90c918fcbb3aa15649c116130a
Gitweb:        https://git.kernel.org/tip/b1d1720321a0fb90c918fcbb3aa15649c116130a
Author:        Ingo Molnar <mingo@kernel.org>
AuthorDate:    Wed, 07 May 2025 20:25:59 +02:00
Committer:     Ingo Molnar <mingo@kernel.org>
CommitterDate: Wed, 07 May 2025 20:30:53 +02:00

accel/habanalabs: Add explicit include of <asm/tsc.h> to pick up the rdtsc() definition

The following commit:

  288a4ff0ad29 ("x86/msr: Move rdtsc{,_ordered}() to <asm/tsc.h>")

removed the <asm/msr.h> include from the accel/habanalabs driver, which broke
the build on UML:

   drivers/accel/habanalabs/common/habanalabs_ioctl.c:326:23: error: call to undeclared function 'rdtsc'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]

Add an explicit <asm/tsc.h> include, now that it works on UML too.

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: Johannes Berg <johannes.berg@intel.com>
Cc: Ofir Bitton <obitton@habana.ai>
Cc: Oded Gabbay <ogabbay@kernel.org>
Link: https://lore.kernel.org/r/202505080003.0t7ewxGp-lkp@intel.com
---
 drivers/accel/habanalabs/common/habanalabs_ioctl.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/accel/habanalabs/common/habanalabs_ioctl.c b/drivers/accel/habanalabs/common/habanalabs_ioctl.c
index dc80ca9..af23001 100644
--- a/drivers/accel/habanalabs/common/habanalabs_ioctl.c
+++ b/drivers/accel/habanalabs/common/habanalabs_ioctl.c
@@ -17,6 +17,8 @@
 #include <linux/uaccess.h>
 #include <linux/vmalloc.h>
 
+#include <asm/tsc.h>
+
 /* make sure there is space for all the signed info */
 static_assert(sizeof(struct cpucp_info) <= SEC_DEV_INFO_BUF_SZ);
 

  reply	other threads:[~2025-05-07 18:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-07 16:41 [tip:x86/msr 5/19] drivers/accel/habanalabs/common/habanalabs_ioctl.c:326:23: error: call to undeclared function 'rdtsc'; ISO C99 and later do not support implicit function declarations kernel test robot
2025-05-07 18:40 ` tip-bot2 for Ingo Molnar [this message]
2025-05-07 18:40 ` [tip: x86/msr] um: Add UML version of <asm/tsc.h> to define rdtsc() tip-bot2 for Ingo Molnar
2025-05-07 18:47   ` Ingo Molnar
2025-05-07 20:36   ` Johannes Berg
2025-05-08  8:57     ` [PATCH -v2] accel/habanalabs: Don't build the driver on UML Ingo Molnar
2025-05-08  9:02       ` Johannes Berg
2025-05-08  9:03         ` Ingo Molnar
2025-05-08  9:09 ` [tip: x86/msr] " tip-bot2 for Ingo Molnar

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=174664324501.406.12440553986097050520.tip-bot2@tip-bot2 \
    --to=tip-bot2@linutronix.de \
    --cc=johannes.berg@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=mingo@kernel.org \
    --cc=obitton@habana.ai \
    --cc=ogabbay@kernel.org \
    --cc=x86@kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®