linux-modules.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@kernel.org>
To: Luis Chamberlain <mcgrof@kernel.org>
Cc: Arnd Bergmann <arnd@arndb.de>,
	linux-modules@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 1/2] module: stats: include uapi/linux/module.h
Date: Tue, 18 Apr 2023 00:02:46 +0200	[thread overview]
Message-ID: <20230417220254.3215576-1-arnd@kernel.org> (raw)

From: Arnd Bergmann <arnd@arndb.de>

MODULE_INIT_COMPRESSED_FILE is defined in the uapi header, which
is not included indirectly from the normal linux/module.h, but
has to be pulled in explicitly:

kernel/module/stats.c: In function 'mod_stat_bump_invalid':
kernel/module/stats.c:227:14: error: 'MODULE_INIT_COMPRESSED_FILE' undeclared (first use in this function)
  227 |  if (flags & MODULE_INIT_COMPRESSED_FILE)
      |              ^~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 kernel/module/stats.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/kernel/module/stats.c b/kernel/module/stats.c
index d9b9bccf4256..bbf90190a3fe 100644
--- a/kernel/module/stats.c
+++ b/kernel/module/stats.c
@@ -6,6 +6,7 @@
  */
 
 #include <linux/module.h>
+#include <uapi/linux/module.h>
 #include <linux/string.h>
 #include <linux/printk.h>
 #include <linux/slab.h>
-- 
2.39.2


             reply	other threads:[~2023-04-17 22:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-17 22:02 Arnd Bergmann [this message]
2023-04-17 22:02 ` [PATCH 2/2] module: fix building stats for 32-bit targets Arnd Bergmann
2023-04-17 22:15   ` Luis Chamberlain
2023-04-17 22:49     ` Arnd Bergmann
2023-04-17 23:28       ` Luis Chamberlain
2023-04-17 23:31 ` [PATCH 1/2] module: stats: include uapi/linux/module.h Luis Chamberlain

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=20230417220254.3215576-1-arnd@kernel.org \
    --to=arnd@kernel.org \
    --cc=arnd@arndb.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-modules@vger.kernel.org \
    --cc=mcgrof@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;
as well as URLs for NNTP newsgroup(s).