linux-mips
[Top] [All Lists]

Re: [PATCH v3 1/3] Loongson-2F: Flush the branch target history such as

To: Wu Zhangjin <wuzhangjin@gmail.com>
Subject: Re: [PATCH v3 1/3] Loongson-2F: Flush the branch target history such as BTB and RAS
From: Ralf Baechle <ralf@linux-mips.org>
Date: Wed, 17 Mar 2010 16:11:24 +0100
Cc: linux-mips@linux-mips.org, Shinya Kuribayashi <shinya.kuribayashi@necel.com>
In-reply-to: <05e2ba2596f23fa4dda64d63ce2480504b1be4ac.1268453720.git.wuzhangjin@gmail.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <cover.1268453720.git.wuzhangjin@gmail.com> <05e2ba2596f23fa4dda64d63ce2480504b1be4ac.1268453720.git.wuzhangjin@gmail.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.5.20 (2009-08-17)
On Sat, Mar 13, 2010 at 12:34:15PM +0800, Wu Zhangjin wrote:

> From: Wu Zhangjin <wuzhangjin@gmail.com>
> 
> As the Chapter 15: "Errata: Issue of Out-of-order in loongson"[1] shows, to
> workaround the Issue of Loongson-2F,We need to do:
> 
> "When switching from user mode to kernel mode, you should flush the
> branch target history such as BTB and RAS."
> 
> This patch did clear BTB(branch target buffer), forbid RAS(return
> address stack) via Loongson-2F's 64bit diagnostic register.
> 
> [1] Chinese Version: http://www.loongson.cn/uploadfile/file/200808211
> [2] English Version of Chapter 15:
> http://groups.google.com.hk/group/loongson-dev/msg/e0d2e220958f10a6?dmode=source

Thanks, applied.

  Ralf

<Prev in Thread] Current Thread [Next in Thread>