public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: Hans Verkuil <hverkuil@xs4all.nl>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
	Sakari Ailus <sakari.ailus@iki.fi>
Cc: linux-media@vger.kernel.org,
	Gjorgji Rosikopulos <grosikopulos@mm-sol.com>,
	Tiffany Lin <tiffany.lin@mediatek.com>
Subject: Re: [PATCH] v4l: Fix dma buf single plane compat handling
Date: Mon, 18 Jan 2016 12:21:38 +0100	[thread overview]
Message-ID: <569CCAC2.5010001@xs4all.nl> (raw)
In-Reply-To: <1530239.WI7pDY4BZt@avalon>

Hi all,

While going through patchwork I found this patch that does the same as this
one from Tiffany:

https://patchwork.linuxtv.org/patch/32631/

I haven't seen a second version of this patch from Laurent with the requested
changes fixed, so unless Laurent says otherwise I'd like to merge Tiffany's
version.

Laurent, is that OK for you?

Regards,

	Hans

On 12/13/2015 09:40 PM, Laurent Pinchart wrote:
> Hi Sakari,
> 
> On Wednesday 09 December 2015 13:07:40 Sakari Ailus wrote:
>> On Wed, Dec 09, 2015 at 01:11:12AM +0200, Laurent Pinchart wrote:
>>> On Tuesday 08 December 2015 17:29:16 Sakari Ailus wrote:
>>>> On Mon, Dec 07, 2015 at 10:45:39AM +0200, Laurent Pinchart wrote:
>>>>> From: Gjorgji Rosikopulos <grosikopulos@mm-sol.com>
>>>>>
>>>>> Buffer length is needed for single plane as well, otherwise
>>>>> is uninitialized and behaviour is undetermined.
>>>>
>>>> How about:
>>>>
>>>> The v4l2_buffer length field must be passed as well from user to kernel
>>>> and back, otherwise uninitialised values will be used.
>>>>
>>>>> Signed-off-by: Gjorgji Rosikopulos <grosikopulos@mm-sol.com>
>>>>> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
>>>>
>>>> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
>>>>
>>>> Shouldn't this be submitted to stable as well?
>>>
>>> I'll CC stable.
>>>
>>>>> ---
>>>>>
>>>>>  drivers/media/v4l2-core/v4l2-compat-ioctl32.c | 7 +++++--
>>>>>  1 file changed, 5 insertions(+), 2 deletions(-)
>>>>>
>>>>> diff --git a/drivers/media/v4l2-core/v4l2-compat-ioctl32.c
>>>>> b/drivers/media/v4l2-core/v4l2-compat-ioctl32.c index
>>>>> 8fd84a67478a..b0faa1f7e3a9 100644
>>>>> --- a/drivers/media/v4l2-core/v4l2-compat-ioctl32.c
>>>>> +++ b/drivers/media/v4l2-core/v4l2-compat-ioctl32.c
>>>>> @@ -482,8 +482,10 @@ static int get_v4l2_buffer32(struct v4l2_buffer
>>>>> *kp, struct v4l2_buffer32 __user
>>>>>  				return -EFAULT;
>>>>>  			break;
>>>>>  		
>>>>>  		case V4L2_MEMORY_DMABUF:
>>>>> -			if (get_user(kp->m.fd, &up->m.fd))
>>>>> +			if (get_user(kp->m.fd, &up->m.fd) ||
>>>>> +			    get_user(kp->length, &up->length))
>>>>>  				return -EFAULT;
>>>>> +
>>
>> Without the extra newline, please?
> 
> Sure, I'll fix that in the pull request.
> 


  reply	other threads:[~2016-01-18 11:21 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-07  8:45 [PATCH] v4l: Fix dma buf single plane compat handling Laurent Pinchart
2015-12-08 15:29 ` Sakari Ailus
2015-12-08 19:31   ` grosikopulos
2015-12-08 23:11   ` Laurent Pinchart
2015-12-09 11:07     ` Sakari Ailus
2015-12-13 20:40       ` Laurent Pinchart
2016-01-18 11:21         ` Hans Verkuil [this message]
2016-01-18 22:41           ` Laurent Pinchart

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=569CCAC2.5010001@xs4all.nl \
    --to=hverkuil@xs4all.nl \
    --cc=grosikopulos@mm-sol.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-media@vger.kernel.org \
    --cc=sakari.ailus@iki.fi \
    --cc=tiffany.lin@mediatek.com \
    /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