On ma, 2016-08-15 at 12:53 +0100, Chris Wilson wrote:
> +int remap_io_mapping(struct vm_area_struct *vma,
> +                  unsigned long addr, unsigned long pfn, unsigned long size,
> +                  struct io_mapping *iomap)
> +{
> +     struct remap_pfn r;
> +     int err;
> +
> +#define MUST_SET (VM_IO | VM_PFNMAP | VM_DONTEXPAND | VM_DONTDUMP)
> +     if (WARN_ON((vma->vm_flags & MUST_SET) != MUST_SET))
> +             return -EINVAL;
> +#undef MUST_SET

#define is bit overkill...

Other than that, should do the job.

Reviewed-by: Joonas Lahtinen <joonas.lahti...@linux.intel.com>

Regards, Joonas
-- 
Joonas Lahtinen
Open Source Technology Center
Intel Corporation
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

Reply via email to