[Top] [All Lists]

Re: [PATCH] MIPS: lib: Optimize partial checksum ops using prefetching.

To: Ralf Baechle <>
Subject: Re: [PATCH] MIPS: lib: Optimize partial checksum ops using prefetching.
From: "Steven J. Hill" <>
Date: Tue, 21 Jan 2014 14:58:44 -0600
Cc: <>
In-reply-to: <>
List-archive: <>
List-help: <>
List-id: linux-mips <>
List-owner: <>
List-post: <>
List-software: Ecartis version 1.0.0
List-subscribe: <>
List-unsubscribe: <>
Original-recipient: rfc822;
References: <> <>
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0
On 01/21/2014 02:49 PM, Ralf Baechle wrote:
On Tue, Jan 21, 2014 at 10:18:42AM -0600, Steven J. Hill wrote:

From: Leonid Yegoshin <>

Use the PREF instruction to optimize partial checksum operations.

Prefetch operations may cause obscure bus error exceptions on some systems
such as Malta, for example, when prefetching beyond the end of memory.
It may also mean memory regions that are just undergoing a DMA transfer
are being brought back into cache.

This pretty much means that pref is only safe to use on cache-coherent

So, could we have:

   #define PREFSIZE   (1 << MIPS_L1_CACHE_SHIFT)

and then use the PREFSIZE value instead of the hardcoded value of 32?


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