From: Vlad Zolotarov <vladz@cloudius-systems.com>
To: Greg KH <gregkh@linuxfoundation.org>
Cc: linux-kernel@vger.kernel.org, mst@redhat.com, hjk@hansjkoch.de,
corbet@lwn.net, bruce.richardson@intel.com,
avi@cloudius-systems.com, gleb@cloudius-systems.com,
stephen@networkplumber.org, alexander.duyck@gmail.com
Subject: Re: [PATCH v5 1/4] uio: add ioctl support
Date: Wed, 7 Oct 2015 20:28:10 +0300 [thread overview]
Message-ID: <5615562A.1070105@cloudius-systems.com> (raw)
In-Reply-To: <20151007172112.GC9702@kroah.com>
On 10/07/15 20:21, Greg KH wrote:
> On Wed, Oct 07, 2015 at 11:55:01AM +0300, Vlad Zolotarov wrote:
>>
>> On 10/07/15 11:46, Greg KH wrote:
>>> On Tue, Oct 06, 2015 at 08:17:36PM +0300, Vlad Zolotarov wrote:
>>>> Add the ability for underlying device drivers to register the ioctl
>>>> commands. This is useful when some interaction with the user space
>>>> beyond sysfs capabilities is required, e.g. query the interrupt mode
>>>> or bind eventfd to interrupt notifications (similarly to vfio ioctl
>>>> VFIO_DEVICE_SET_IRQS).
>>>>
>>>> Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com>
>>>> ---
>>>> drivers/uio/uio.c | 15 +++++++++++++++
>>>> include/linux/uio_driver.h | 3 +++
>>>> 2 files changed, 18 insertions(+)
>>>>
>>>> diff --git a/drivers/uio/uio.c b/drivers/uio/uio.c
>>>> index 8196581..714b0e5 100644
>>>> --- a/drivers/uio/uio.c
>>>> +++ b/drivers/uio/uio.c
>>>> @@ -704,6 +704,20 @@ static int uio_mmap(struct file *filep, struct vm_area_struct *vma)
>>>> }
>>>> }
>>>> +static long uio_ioctl(struct file *filep, unsigned int cmd, unsigned long arg)
>>>> +{
>>>> + struct uio_listener *listener = filep->private_data;
>>>> + struct uio_device *idev = listener->dev;
>>>> +
>>>> + if (!idev->info)
>>>> + return -EIO;
>>>> +
>>>> + if (!idev->info->ioctl)
>>>> + return -ENOTTY;
>>>> +
>>>> + return idev->info->ioctl(idev->info, cmd, arg);
>>>> +}
>>> As Stephen said, I will not take this, sorry. It opens up the ability
>>> to add "new system calls" to a huge range of crappy drivers, it's
>>> something that vendors have been trying to push for years and is
>>> something that I will not allow.
>> Ok. Another alternative could be to add new sysfs attributes for the MSI-X
>> functionality similarly to what is done with "maps".
>> Would it be acceptable?
> If you get everyone else here to agree that this is the interface you
> all are going to be using, sure. All I care is that you not add ioctl
> to the UIO interface.
Ok then. Thanks.
>
> greg k-h
next prev parent reply other threads:[~2015-10-07 17:28 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-06 17:17 [PATCH v5 0/4] uio: add MSI/MSI-X support to uio_pci_generic driver Vlad Zolotarov
2015-10-06 17:17 ` [PATCH v5 1/4] uio: add ioctl support Vlad Zolotarov
2015-10-06 21:33 ` Stephen Hemminger
2015-10-07 8:17 ` Vlad Zolotarov
2015-10-07 8:18 ` Vlad Zolotarov
2015-10-07 8:46 ` Greg KH
2015-10-07 8:55 ` Vlad Zolotarov
2015-10-07 17:21 ` Greg KH
2015-10-07 17:28 ` Vlad Zolotarov [this message]
[not found] ` <CAOaVG17hMG7cAnD_DZ9J3pRMpXctx3o_EF8A62vtZx6Mv9c-2g@mail.gmail.com>
2015-10-07 19:00 ` Vlad Zolotarov
[not found] ` <CAOaVG147Fxq0VyohAFBvw4cxtLRw3qd2aNt-e2Vr4_R5EYs7zQ@mail.gmail.com>
2015-10-08 12:41 ` Vlad Zolotarov
2015-10-08 13:03 ` Greg Kroah-Hartman
2015-10-06 17:17 ` [PATCH v5 2/4] uio_pci_generic: properly initialize PCI bars mappings towards UIO Vlad Zolotarov
2015-10-06 17:17 ` [PATCH v5 3/4] uio_pci_generic: add MSI/MSI-X support Vlad Zolotarov
2015-10-06 21:36 ` Stephen Hemminger
2015-10-06 17:17 ` [PATCH v5 4/4] Documentation: update uio-howto Vlad Zolotarov
2015-10-06 18:27 ` [PATCH v5 0/4] uio: add MSI/MSI-X support to uio_pci_generic driver Michael S. Tsirkin
2015-10-06 20:35 ` Vlad Zolotarov
2015-10-06 20:48 ` Vlad Zolotarov
2015-10-06 22:51 ` Michael S. Tsirkin
2015-10-07 8:38 ` Vlad Zolotarov
2015-10-07 10:42 ` Michael S. Tsirkin
2015-10-07 13:44 ` Vlad Zolotarov
2015-10-07 13:55 ` Vlad Zolotarov
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=5615562A.1070105@cloudius-systems.com \
--to=vladz@cloudius-systems.com \
--cc=alexander.duyck@gmail.com \
--cc=avi@cloudius-systems.com \
--cc=bruce.richardson@intel.com \
--cc=corbet@lwn.net \
--cc=gleb@cloudius-systems.com \
--cc=gregkh@linuxfoundation.org \
--cc=hjk@hansjkoch.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mst@redhat.com \
--cc=stephen@networkplumber.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.