Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1217875

Re: [RFC PATCH] mmc: block: Add new ioctl to send combo commands

From Grant Grundler <grundler@google.com>
Newsgroups linux.kernel
Subject Re: [RFC PATCH] mmc: block: Add new ioctl to send combo commands
Date 2015-09-03 00:10 +0200
Message-ID <q4ooa-1ad-23@gated-at.bofh.it> (permalink)
References <q4hd1-7Er-43@gated-at.bofh.it> <q4kXg-4BW-7@gated-at.bofh.it> <q4ooa-1ad-25@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[resending text-only]

On Wed, Sep 2, 2015 at 3:07 PM, Grant Grundler <grundler@google.com> wrote:
>
>
> On Wed, Sep 2, 2015 at 11:28 AM, Olof Johansson <olof@lixom.net> wrote:
> ...
>> > +/**
>> > + * struct mmc_ioc_combo_cmd - combo command information
>> > + * @num_of_cmds: number of commands to send
>> > + * @mmc_ioc_cmd_list: pointer to list of commands
>> > + */
>> > +struct mmc_ioc_combo_cmd {
>> > +       uint8_t num_of_cmds;
>> > +       struct mmc_ioc_cmd *mmc_ioc_cmd_list;
>> > +};
>>
>> The size of this struct will depend on the pointer size of userspace.
>>
>> It might be better to use a u64 for the pointer instead. Otherwise
>> you'd need a compat ioctl wrapper to copy a 32-bit pointer over on a
>> 64-bit kernel.
>
> If alignment matters, then maybe swap the fields?
> Or declare num_of_cmds as u64 as well?
>
> grant
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[RFC PATCH] mmc: block: Add new ioctl to send combo commands Jon Hunter <jonathanh@nvidia.com> - 2015-09-02 16:30 +0200
  Re: [RFC PATCH] mmc: block: Add new ioctl to send combo commands Olof Johansson <olof@lixom.net> - 2015-09-02 20:30 +0200
    Re: [RFC PATCH] mmc: block: Add new ioctl to send combo commands Grant Grundler <grundler@google.com> - 2015-09-03 00:10 +0200
      Re: [RFC PATCH] mmc: block: Add new ioctl to send combo commands Jon Hunter <jonathanh@nvidia.com> - 2015-09-03 17:20 +0200
        Re: [RFC PATCH] mmc: block: Add new ioctl to send combo commands Grant Grundler <grundler@chromium.org> - 2015-09-04 03:20 +0200
    Re: [RFC PATCH] mmc: block: Add new ioctl to send combo commands Jon Hunter <jonathanh@nvidia.com> - 2015-09-03 17:10 +0200

csiph-web