From: WANG Cong <xiyou.wangcong@gmail.com>
To: LKML <linux-kernel@vger.kernel.org>
Cc: Jeff Dike <jdike@addtoit.com>,
user-mode-linux-devel@lists.sourceforge.net
Subject: [Patch] arch/um/include/init.h: Fix missing macro definitions
Date: Thu, 31 Jan 2008 23:06:34 +0800 [thread overview]
Message-ID: <20080131150634.GC2471@hacking> (raw)
This patch fixed the following build error in current -git tree.
arch/um/kernel/config.c:10: error: expected declaration specifiers or '...' before '.' token
...
Cc: Jeff Dike <jdike@addtoit.com>
Signed-off-by: WANG Cong <xiyou.wangcong@gmail.com>
---
diff --git a/arch/um/include/init.h b/arch/um/include/init.h
index cebc6ca..70982e1 100644
--- a/arch/um/include/init.h
+++ b/arch/um/include/init.h
@@ -40,6 +40,18 @@
typedef int (*initcall_t)(void);
typedef void (*exitcall_t)(void);
+#ifndef __section
+# define __section(S) __attribute__ ((__section__(#S)))
+#endif
+
+#ifndef __used
+#if __GNUC__ == 3 && __GNUC_MINOR__ == 2
+# define __used __attribute__((__unused__))
+#else
+# define __used __attribute__((__used__))
+#endif
+#endif
+
/* These are for everybody (although not all archs will actually
discard it in modules) */
#define __init __section(.init.text)
next reply other threads:[~2008-01-31 15:09 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-31 15:06 WANG Cong [this message]
2008-02-01 17:29 ` [Patch] arch/um/include/init.h: Fix missing macro definitions Jeff Dike
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=20080131150634.GC2471@hacking \
--to=xiyou.wangcong@gmail.com \
--cc=jdike@addtoit.com \
--cc=linux-kernel@vger.kernel.org \
--cc=user-mode-linux-devel@lists.sourceforge.net \
/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