From: Matthew Wilcox <matthew@wil.cx>
To: Dave Jones <davej@redhat.com>,
Linux Kernel <linux-kernel@vger.kernel.org>,
linux-scsi@vger.kernel.org
Subject: Re: [PATCH] Don't export scsi kernel variables in userspace headers.
Date: Sun, 26 Jul 2009 16:14:24 -0600 [thread overview]
Message-ID: <20090726221424.GA3711@parisc-linux.org> (raw)
In-Reply-To: <20090725021026.GA6942@redhat.com>
On Fri, Jul 24, 2009 at 10:10:26PM -0400, Dave Jones wrote:
> +++ b/include/scsi/scsi.h
> @@ -156,7 +156,9 @@ scsi_varlen_cdb_length(const void *hdr)
> return ((struct scsi_varlen_cdb_hdr *)hdr)->additional_cdb_length + 8;
> }
>
> +#ifdef __KERNEL__
> extern const unsigned char scsi_command_size_tbl[8];
> +#endif
> #define COMMAND_SIZE(opcode) scsi_command_size_tbl[((opcode) >> 5) & 7]
>
> static inline unsigned
Probably should move that #endif down -- it's not like userspace can
use the COMMAND_SIZE macro (should headers_check also check for this?)
Also scsi_command_size() isn't usable by userspace either, since it uses
COMMAND_SIZE.
--
Matthew Wilcox Intel Open Source Technology Centre
"Bill, look, we understand that you're interested in selling us this
operating system, but compare it to ours. We can't possibly take such
a retrograde step."
next prev parent reply other threads:[~2009-07-26 22:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-07-25 2:10 [PATCH] Don't export scsi kernel variables in userspace headers Dave Jones
2009-07-26 22:14 ` Matthew Wilcox [this message]
2009-07-27 7:44 ` Christoph Hellwig
2009-07-27 8:26 ` Sam Ravnborg
2009-07-27 8:37 ` Boaz Harrosh
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=20090726221424.GA3711@parisc-linux.org \
--to=matthew@wil.cx \
--cc=davej@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.