Re: [PATCH v4 1/8] staging: zcache: introduce zero-filled pages handler

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Mar 19, 2013 at 10:25 AM, Wanpeng Li <liwanp@xxxxxxxxxxxxxxxxxx> wrote:
> Introduce zero-filled pages handler to capture and handle zero pages.
>
> Acked-by: Dan Magenheimer <dan.magenheimer@xxxxxxxxxx>
> Signed-off-by: Wanpeng Li <liwanp@xxxxxxxxxxxxxxxxxx>
> ---
>  drivers/staging/zcache/zcache-main.c |   26 ++++++++++++++++++++++++++
>  1 files changed, 26 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/staging/zcache/zcache-main.c b/drivers/staging/zcache/zcache-main.c
> index 328898e..d73dd4b 100644
> --- a/drivers/staging/zcache/zcache-main.c
> +++ b/drivers/staging/zcache/zcache-main.c

> +static void handle_zero_filled_page(void *page)
> +{
> +       void *user_mem;
> +
> +       user_mem = kmap_atomic(page);

kmap_atomic() takes a "struct page *", not a "void *".

> +       memset(user_mem, 0, PAGE_SIZE);
> +       kunmap_atomic(user_mem);
> +
> +       flush_dcache_page(page);

While flush_dcache_page() is a no-op on many architectures, it also
takes a "struct page *", not a "void *":

m68k/allmodconfig:

drivers/staging/zcache/zcache-main.c:309:2: error: request for member
'virtual' in something not a structure or union

Cfr. http://kisskb.ellerman.id.au/kisskb/buildresult/8433711/

> +}

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]