Re: [PATCH] nommu: remap_pfn_range: fix addr parameter check

2012-09-16 Thread Scott Jiang
>> I was using 3.3 linux kernel. I will again check if videobuf2 in 3.5 has >> already >> fixed this issue. > > [snip..] > > Ok I just checked the vb2_dma_contig allocator and it has no major changes > from my version, > http://lxr.linux.no/linux+v3.5.3/drivers/media/video/videobuf2-dma-contig.c#

RE: [PATCH] nommu: remap_pfn_range: fix addr parameter check

2012-09-14 Thread Bhupesh SHARMA
g; > dhowe...@redhat.com; ge...@linux-m68k.org; g...@uclinux.org; > sta...@kernel.org; gre...@linuxfoundation.org; Hugh Dickins > Subject: RE: [PATCH] nommu: remap_pfn_range: fix addr parameter check > > > -Original Message- > > From: Scott Jiang [mailto:scott.jiang.l

RE: [PATCH] nommu: remap_pfn_range: fix addr parameter check

2012-09-14 Thread Bhupesh SHARMA
inux.org; linux-media@vger.kernel.org; > dhowe...@redhat.com; ge...@linux-m68k.org; g...@uclinux.org; > sta...@kernel.org; gre...@linuxfoundation.org; Hugh Dickins > Subject: Re: [PATCH] nommu: remap_pfn_range: fix addr parameter check > > > Yes, the MMU version of remap_pfn_range() do

Re: [PATCH] nommu: remap_pfn_range: fix addr parameter check

2012-09-14 Thread Scott Jiang
> Yes, the MMU version of remap_pfn_range() does permit non-page-aligned > `addr' (at least, if the userspace maaping is a non-COW one). But I > suspect that was an implementation accident - it is a nonsensical thing > to do, isn't it? The MMU cannot map a bunch of kernel pages onto a > non-page-

Re: [PATCH] nommu: remap_pfn_range: fix addr parameter check

2012-09-13 Thread Andrew Morton
On Thu, 13 Sep 2012 10:40:57 +0800 Bob Liu wrote: > The addr parameter may not page aligned eg. when it's come from > vfb_mmap():vma->vm_start in video driver. > > This patch fix the check in remap_pfn_range() else some driver like v4l2 will > fail in this function while calling mmap() on nommu