From: Greg Kroah-Hartman Date: Thu, 9 Jun 2011 19:13:08 +0000 (-0700) Subject: Staging: comedi: drivers.c: fix PAGE_KERNEL_NOCACHE issue X-Git-Tag: MMI-PSA29.97-13-9~18845^2~568^2~2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=408093d2a1724ea4c8518bd2bfee166132a6cbfa;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git Staging: comedi: drivers.c: fix PAGE_KERNEL_NOCACHE issue Not all arches have PAGE_KERNEL_NOCACHE, so use the "normal" PAGE_KERNEL on those that do not have it. Reported-by: Stephen Rothwell Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/comedi/drivers.c b/drivers/staging/comedi/drivers.c index 6d60e91b3a85..db1fd63aaab3 100644 --- a/drivers/staging/comedi/drivers.c +++ b/drivers/staging/comedi/drivers.c @@ -502,7 +502,11 @@ int comedi_buf_alloc(struct comedi_device *dev, struct comedi_subdevice *s, } if (i == n_pages) { async->prealloc_buf = +#ifdef PAGE_KERNEL_NOCACHE vmap(pages, n_pages, VM_MAP, PAGE_KERNEL_NOCACHE); +#else + vmap(pages, n_pages, VM_MAP, PAGE_KERNEL); +#endif } vfree(pages);