Re: [RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-08 Thread Dave Hansen
On Wed, 2007-08-08 at 09:38 +0200, Christian Ehrhardt wrote: > > > ret = -ENOMEM; > > - uaddr = (unsigned long)buf & ~(PAGE_SIZE-1); > > + uaddr = (unsigned long)buf & PAGE_MASK; > > uend = (unsigned long)(buf + count); > > - pagecount = (uend - uaddr + PAGE_SIZE-1) /

Re: [RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-08 Thread Christian Ehrhardt
In linux.kernel, you wrote: > > Use existing macros (PAGE_MASK/PAGE_ALIGN()) instead of > open-coding them. > > Signed-off-by: Dave Hansen <[EMAIL PROTECTED]> > --- > > lxc-dave/fs/proc/task_mmu.c |4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff -puN

Re: [RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-08 Thread Christian Ehrhardt
In linux.kernel, you wrote: Use existing macros (PAGE_MASK/PAGE_ALIGN()) instead of open-coding them. Signed-off-by: Dave Hansen [EMAIL PROTECTED] --- lxc-dave/fs/proc/task_mmu.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff -puN

Re: [RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-08 Thread Dave Hansen
On Wed, 2007-08-08 at 09:38 +0200, Christian Ehrhardt wrote: ret = -ENOMEM; - uaddr = (unsigned long)buf ~(PAGE_SIZE-1); + uaddr = (unsigned long)buf PAGE_MASK; uend = (unsigned long)(buf + count); - pagecount = (uend - uaddr + PAGE_SIZE-1) / PAGE_SIZE; +

Re: [RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-07 Thread Matt Mackall
On Tue, Aug 07, 2007 at 03:33:01PM -0700, Dave Hansen wrote: > > Use existing macros (PAGE_MASK/PAGE_ALIGN()) instead of > open-coding them. Absolutely. Acked-by: Matt Mackall <[EMAIL PROTECTED]> -- Mathematics is the supreme nostalgia of our time. - To unsubscribe from this list: send the

[RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-07 Thread Dave Hansen
Use existing macros (PAGE_MASK/PAGE_ALIGN()) instead of open-coding them. Signed-off-by: Dave Hansen <[EMAIL PROTECTED]> --- lxc-dave/fs/proc/task_mmu.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff -puN fs/proc/task_mmu.c~pagemap-use-PAGE_MASK fs/proc/task_mmu.c ---

[RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-07 Thread Dave Hansen
Use existing macros (PAGE_MASK/PAGE_ALIGN()) instead of open-coding them. Signed-off-by: Dave Hansen [EMAIL PROTECTED] --- lxc-dave/fs/proc/task_mmu.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff -puN fs/proc/task_mmu.c~pagemap-use-PAGE_MASK fs/proc/task_mmu.c ---

Re: [RFC][PATCH 2/5] pagemap: use PAGE_MASK/PAGE_ALIGN()

2007-08-07 Thread Matt Mackall
On Tue, Aug 07, 2007 at 03:33:01PM -0700, Dave Hansen wrote: Use existing macros (PAGE_MASK/PAGE_ALIGN()) instead of open-coding them. Absolutely. Acked-by: Matt Mackall [EMAIL PROTECTED] -- Mathematics is the supreme nostalgia of our time. - To unsubscribe from this list: send the line