Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2009-06-18 Thread Sonny Rao
On Mon, Nov 17, 2008 at 01:26:13AM -0600, Sonny Rao wrote: > On Fri, Nov 07, 2008 at 04:28:29PM +1100, Paul Mackerras wrote: > > Sonny Rao writes: > > > > > Fix the BSR driver to allow small BSR devices, which are limited to a > > > single 4k space, on a 64k page kernel. Previously the driver wou

Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2008-11-20 Thread Sonny Rao
On Thu, Nov 20, 2008 at 09:54:21AM +1100, Paul Mackerras wrote: > Sonny Rao writes: > > > On Wed, Nov 19, 2008 at 03:07:04PM +1100, Paul Mackerras wrote: > > > I think we should be checking that dev->bsr_len == 4096 here. > > > > > > Paul. > > > > Well, dev->bsr_len could be 4096 or 8192 > > Is

Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2008-11-19 Thread Paul Mackerras
Sonny Rao writes: > On Wed, Nov 19, 2008 at 03:07:04PM +1100, Paul Mackerras wrote: > > I think we should be checking that dev->bsr_len == 4096 here. > > > > Paul. > > Well, dev->bsr_len could be 4096 or 8192 Isn't the dev->bsr_len == 8192 case the one where we'll only map 4096 bytes and theref

Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2008-11-19 Thread Sonny Rao
On Wed, Nov 19, 2008 at 03:07:04PM +1100, Paul Mackerras wrote: > Sonny Rao writes: > > > - if (io_remap_pfn_range(vma, vma->vm_start, dev->bsr_addr >> PAGE_SHIFT, > > - size, vma->vm_page_prot)) > > + /* check for the case of a small BSR device and map one 4k page for

Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2008-11-18 Thread Paul Mackerras
Sonny Rao writes: > - if (io_remap_pfn_range(vma, vma->vm_start, dev->bsr_addr >> PAGE_SHIFT, > -size, vma->vm_page_prot)) > + /* check for the case of a small BSR device and map one 4k page for it*/ > + if (dev->bsr_len < PAGE_SIZE && size == PAGE_SIZE) > +

Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2008-11-16 Thread Sonny Rao
On Fri, Nov 07, 2008 at 04:28:29PM +1100, Paul Mackerras wrote: > Sonny Rao writes: > > > Fix the BSR driver to allow small BSR devices, which are limited to a > > single 4k space, on a 64k page kernel. Previously the driver would > > reject the mmap since the size was smaller than PAGESIZE (or b

Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2008-11-07 Thread Sonny Rao
On Fri, Nov 07, 2008 at 04:28:29PM +1100, Paul Mackerras wrote: > Sonny Rao writes: > > > Fix the BSR driver to allow small BSR devices, which are limited to a > > single 4k space, on a 64k page kernel. Previously the driver would > > reject the mmap since the size was smaller than PAGESIZE (or b

Re: [PATCH] Fix BSR to allow mmap of small BSR on 64k kernel

2008-11-06 Thread Paul Mackerras
Sonny Rao writes: > Fix the BSR driver to allow small BSR devices, which are limited to a > single 4k space, on a 64k page kernel. Previously the driver would > reject the mmap since the size was smaller than PAGESIZE (or because > the size was greater than the size of the device). Now, we check