From: Josh Triplett <josh@kernel.org>
To: linux-kernel@vger.kernel.org
Cc: Andrew Morton <akpm@osdl.org>
Subject: [PATCH] cdev.h needs struct inode; add forward declaration
Date: Mon, 29 Jan 2007 12:01:27 -0800 [thread overview]
Message-ID: <45BE5297.4070608@kernel.org> (raw)
include/linux/cdev.h defines cd_forget to take a struct inode *, but does not
pull in any definition or declaration for struct inode. This generates a
compiler warning if a source file pulls in cdev.h without first pulling in
fs.h. Add a forward declaration of struct inode to cdev.h, to eliminate the
compiler warning and preserve the ability to include headers in any arbitrary
order.
Signed-off-by: Josh Triplett <josh@kernel.org>
---
include/linux/cdev.h | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/include/linux/cdev.h b/include/linux/cdev.h
index f309b00..4281e80 100644
--- a/include/linux/cdev.h
+++ b/include/linux/cdev.h
@@ -6,6 +6,8 @@
#include <linux/kdev_t.h>
#include <linux/list.h>
+struct inode;
+
struct cdev {
struct kobject kobj;
struct module *owner;
next reply other threads:[~2007-01-29 20:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-29 20:01 Josh Triplett [this message]
2007-01-30 10:48 ` [PATCH] cdev.h needs struct inode; add forward declaration Jan Engelhardt
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=45BE5297.4070608@kernel.org \
--to=josh@kernel.org \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.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