From: Arnd Bergmann <arnd@arndb.de>
To: Kevin Cernekee <kpc.mtd@gmail.com>, linux-kernel@vger.kernel.org
Cc: linux-mtd@lists.infradead.org, dwmw2@infradead.org
Subject: Re: [PATCHv4] MTD: New ioctl calls for >4GiB device support
Date: Tue, 31 Mar 2009 12:51:03 +0200 [thread overview]
Message-ID: <200903311251.04746.arnd@arndb.de> (raw)
In-Reply-To: <a95a62fe0903301814k75ce56f5xef0a04c5c188012@mail.gmail.com>
On Tuesday 31 March 2009, Kevin Cernekee wrote:
> +struct mtd_oob_buf64 {
> + uint64_t start;
> + uint32_t res0;
> + uint32_t length;
> + unsigned char __user *ptr;
> + uint32_t res1[8];
> +};
Does this have to use an indirect pointer? We normally try to avoid
ioctl interfaces like this, because they are hard to trace and you
need a compat wrapper. You might be able to at least avoid the wrapper
by defining the data structure with a __u64 to take the pointer.
If you leave the data structure the way it is, you should at least
move the compat_ioctl handling into mtdchar.c from compat_ioctl.c.
It will simplify your code and help reduce the size of the common
ioctl handling.
Arnd <><
next prev parent reply other threads:[~2009-03-31 10:51 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-31 1:14 [PATCHv4] MTD: New ioctl calls for >4GiB device support Kevin Cernekee
2009-03-31 6:31 ` Artem Bityutskiy
2009-03-31 10:51 ` Arnd Bergmann [this message]
2009-03-31 18:29 ` Kevin Cernekee
2009-04-01 14:50 ` Arnd Bergmann
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=200903311251.04746.arnd@arndb.de \
--to=arnd@arndb.de \
--cc=dwmw2@infradead.org \
--cc=kpc.mtd@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.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).