Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932663Ab0FQNg7 (ORCPT ); Thu, 17 Jun 2010 09:36:59 -0400 Received: from cantor2.suse.de ([195.135.220.15]:55941 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754070Ab0FQNg4 (ORCPT ); Thu, 17 Jun 2010 09:36:56 -0400 Subject: Re: bnx2 fails to compile on parisc because of missing get_dma_ops() From: James Bottomley To: Michael Chan Cc: "'FUJITA Tomonori'" , "vapier@gentoo.org" , "netdev@vger.kernel.org" , "linux-parisc@vger.kernel.org" , "linux-kernel@vger.kernel.org" In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Date: Thu, 17 Jun 2010 08:36:51 -0500 Message-ID: <1276781811.7285.4.camel@mulgrave.site> Mime-Version: 1.0 X-Mailer: Evolution 2.28.2 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1308 Lines: 33 On Thu, 2010-06-17 at 06:30 -0700, Michael Chan wrote: > James Bottomley wrote: > > > On Thu, 2010-06-17 at 05:54 -0700, Michael Chan wrote: > > > This prefetch improves performance noticeably when the driver is > > > handling incoming 64-byte packets at a sustained rate. > > > > So why not do it unconditionally? The worst that can happen > > is that you > > pull in a stale cache line which will get cleaned in the > > dma_sync, thus > > slightly degrading performance on incoherent architectures. > > The original patch was an unconditional prefetch. There was > some discussion that it might not be correct if the DMA wasn't > sync'ed yet on some archs. If the concensus is that it is ok to > do so, that would be the simplest solution. It's definitely not "correct" in that it may pull in stale data. But it should be harmless in that if it does, the subsequent sync will destroy the cache line (even if it actually pulled in correct data) and prevent the actual use of the prefetched data being wrong (or indeed being prefetched at all). James -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/