Re: [PATCHv4 09/10] media-request: EPERM -> EACCES/EBUSY

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Sep 4, 2018 at 4:59 PM Hans Verkuil <hverkuil@xxxxxxxxx> wrote:
>
> From: Hans Verkuil <hans.verkuil@xxxxxxxxx>
>
> If requests are not supported by the driver, then return EACCES, not
> EPERM.
>
> If you attempt to mix queueing buffers directly and using requests,
> then EBUSY is returned instead of EPERM: once a specific queueing mode
> has been chosen the queue is 'busy' if you attempt the other mode
> (i.e. direct queueing vs via a request).
>
> Signed-off-by: Hans Verkuil <hans.verkuil@xxxxxxxxx>
> ---
>  .../uapi/mediactl/media-request-ioc-queue.rst  |  9 ++++-----
>  .../media/uapi/mediactl/request-api.rst        |  4 ++--
>  Documentation/media/uapi/v4l/buffer.rst        |  2 +-
>  .../media/uapi/v4l/vidioc-g-ext-ctrls.rst      |  9 ++++-----
>  Documentation/media/uapi/v4l/vidioc-qbuf.rst   | 18 ++++++++++--------
>  .../media/common/videobuf2/videobuf2-core.c    |  2 +-
>  .../media/common/videobuf2/videobuf2-v4l2.c    |  9 ++++++---
>  drivers/media/media-request.c                  |  4 ++--
>  include/media/media-request.h                  |  6 +++---
>  9 files changed, 33 insertions(+), 30 deletions(-)
[snip]
> diff --git a/include/media/media-request.h b/include/media/media-request.h
> index d8c8db89dbde..0ce75c35131f 100644
> --- a/include/media/media-request.h
> +++ b/include/media/media-request.h
> @@ -198,8 +198,8 @@ void media_request_put(struct media_request *req);
>   * Get the request represented by @request_fd that is owned
>   * by the media device.
>   *
> - * Return a -EPERM error pointer if requests are not supported
> - * by this driver. Return -ENOENT if the request was not found.
> + * Return a -EACCES error pointer if requests are not supported
> + * by this driver. Return -EINVAL if the request was not found.

I think the bottom-most line belongs to patch 1/10. With that fixed
(possibly when applying):

Reviewed-by: Tomasz Figa <tfiga@xxxxxxxxxxxx>

Best regards,
Tomasz



[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux