+ fix2-gregkh-driver-modules-state.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     fix gregkh-driver-modules-state
has been added to the -mm tree.  Its filename is
     fix2-gregkh-driver-modules-state.patch

See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this

------------------------------------------------------
Subject: fix gregkh-driver-modules-state
From: Kay Sievers <kay.sievers@xxxxxxxx>

When CONFIG_MODULE_UNLOAD is not set then this happens:

  CC      kernel/module.o
kernel/module.c:852: error: `initstate' undeclared here (not in a function)
kernel/module.c:852: error: initializer element is not constant
kernel/module.c:852: error: (near initialization for `modinfo_attrs[2]')
make[1]: *** [kernel/module.o] Error 1
make: *** [kernel] Error 2

Reference to 'initstate' should stay under #ifdef CONFIG_MODULE_UNLOAD
as its definition I guess.

Cc: Mariusz Kozlowski <m.kozlowski@xxxxxxxxxx>
Cc: Greg KH <greg@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 kernel/module.c |   42 +++++++++++++++++++++---------------------
 1 files changed, 21 insertions(+), 21 deletions(-)

diff -puN kernel/module.c~fix2-gregkh-driver-modules-state kernel/module.c
--- a/kernel/module.c~fix2-gregkh-driver-modules-state
+++ a/kernel/module.c
@@ -790,6 +790,27 @@ static struct module_attribute refcnt = 
 	.show = show_refcnt,
 };
 
+#else /* !CONFIG_MODULE_UNLOAD */
+static void print_unload_info(struct seq_file *m, struct module *mod)
+{
+	/* We don't know the usage count, or what modules are using. */
+	seq_printf(m, " - -");
+}
+
+static inline void module_unload_free(struct module *mod)
+{
+}
+
+static inline int use_module(struct module *a, struct module *b)
+{
+	return strong_try_module_get(b);
+}
+
+static inline void module_unload_init(struct module *mod)
+{
+}
+#endif /* CONFIG_MODULE_UNLOAD */
+
 static ssize_t show_initstate(struct module_attribute *mattr,
 			   struct module *mod, char *buffer)
 {
@@ -814,27 +835,6 @@ static struct module_attribute initstate
 	.show = show_initstate,
 };
 
-#else /* !CONFIG_MODULE_UNLOAD */
-static void print_unload_info(struct seq_file *m, struct module *mod)
-{
-	/* We don't know the usage count, or what modules are using. */
-	seq_printf(m, " - -");
-}
-
-static inline void module_unload_free(struct module *mod)
-{
-}
-
-static inline int use_module(struct module *a, struct module *b)
-{
-	return strong_try_module_get(b);
-}
-
-static inline void module_unload_init(struct module *mod)
-{
-}
-#endif /* CONFIG_MODULE_UNLOAD */
-
 static struct module_attribute *modinfo_attrs[] = {
 	&modinfo_version,
 	&modinfo_srcversion,
_

Patches currently in -mm which might be from kay.sievers@xxxxxxxx are

fix2-gregkh-driver-modules-state.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux