All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sshtylyov@mvista.com>
To: Ralf Baechle <ralf@linux-mips.org>
Cc: Christoph Hellwig <hch@lst.de>,
	naveen yadav <yad.naveen@gmail.com>,
	linux-mips@linux-mips.org
Subject: Re: flush_kernel_vmap_range() invalidate_kernel_vmap_range() API not exists for MIPS
Date: Sat, 18 Jun 2011 17:06:37 +0400	[thread overview]
Message-ID: <4DFCA2DD.9060707@mvista.com> (raw)
In-Reply-To: <20110617152028.GA14107@linux-mips.org>

Hello.

On 17-06-2011 19:20, Ralf Baechle wrote:

>> Ralf,

>> I'll second that request.  We'll really need this, right now embedded XFS
>> users are hacking around it in horrible ways.

> Here's my shot at the problem.  I don't have the time to setup a XFS
> filesystem and tools for testing before the weekend so all I claim is this
> patch builds for R4000-class CPUs but it should be pretty close to the
> real thing.

> Naveen, can you give this patch a spin?  Thanks!

>    Ralf

> Signed-off-by: Ralf Baechle<ralf@linux-mips.org>

[...]

> diff --git a/arch/mips/include/asm/cacheflush.h b/arch/mips/include/asm/cacheflush.h
> index 40bb9fd..69468de 100644
> --- a/arch/mips/include/asm/cacheflush.h
> +++ b/arch/mips/include/asm/cacheflush.h
> @@ -114,4 +114,28 @@ unsigned long run_uncached(void *func);
>   extern void *kmap_coherent(struct page *page, unsigned long addr);
>   extern void kunmap_coherent(void);
>
> +#define ARCH_HAS_FLUSH_KERNEL_DCACHE_PAGE
> +static inline void flush_kernel_dcache_page(struct page *page)
> +{
> +	BUG_ON(cpu_has_dc_aliases&&  PageHighMem(page));
> +}
> +
> +/*
> + * For now flush_kernel_vmap_range and invalidate_kernel_vmap_range both do a
> + * cache writeback and invalidate operation.
> + */
> +extern void (*__flush_kernel_vmap_range)(unsigned long vaddr, int size);
> +
> +static inline void flush_kernel_vmap_range(void *vaddr, int size)
> +{
> +	if (cpu_has_dc_aliases)
> +		__flush_kernel_vmap_range((unsigned long) vaddr, size);
> +}
> +
> +static inline void invalidate_kernel_vmap_range(void *vaddr, int size)
> +{
> +	if (cpu_has_dc_aliases)
> +		__flush_kernel_vmap_range((unsigned long) vaddr, size);

    Not __invalidate_kernel_vmap_range()?

WBR, Sergei

  parent reply	other threads:[~2011-06-18 13:07 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-25  9:08 flush_kernel_vmap_range() invalidate_kernel_vmap_range() API not exists for MIPS naveen yadav
2011-03-25 17:27 ` Ralf Baechle
2011-03-29  5:54   ` naveen yadav
2011-05-19  4:35     ` naveen yadav
2011-06-15  6:28   ` naveen yadav
2011-06-16 18:02     ` Christoph Hellwig
2011-06-17 15:20       ` Ralf Baechle
2011-06-18 10:51         ` naveen yadav
2011-06-18 13:06         ` Sergei Shtylyov [this message]
2011-06-20  9:56           ` Ralf Baechle
2011-06-24  5:06             ` naveen yadav
2011-06-24  7:09               ` Ralf Baechle
2011-06-17  0:05     ` Ralf Baechle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4DFCA2DD.9060707@mvista.com \
    --to=sshtylyov@mvista.com \
    --cc=hch@lst.de \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.org \
    --cc=yad.naveen@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.