Re: INIT_MMAP on sparc64

Benjamin LaHaise (bcrl@redhat.com)
Mon, 22 Oct 2001 11:14:16 -0400


On Sun, Oct 21, 2001 at 06:15:23PM -0700, David S. Miller wrote:
>
> DRI works perfectly fine in my current sources, patches below.

On a side note of coding style, the following:

> +#ifdef __sparc__
> + if (io_remap_page_range(vma->vm_start,
> + VM_OFFSET(vma) + offset,
> + vma->vm_end - vma->vm_start,
> + vma->vm_page_prot, 0))
> +#else
> if (remap_page_range(vma->vm_start,
> VM_OFFSET(vma) + offset,
> vma->vm_end - vma->vm_start,
> vma->vm_page_prot))
> +#endif

should really be turned into io_remap_page_range(...) unconditionally
and add a #define for io_remap_page_range in the arch specific code.
Having #ifdef's all over generic code is just ugly.

-ben
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/