From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752420AbbK3CM4 (ORCPT ); Sun, 29 Nov 2015 21:12:56 -0500 Received: from kvm5.telegraphics.com.au ([98.124.60.144]:57720 "EHLO kvm5.telegraphics.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751544AbbK3CMy (ORCPT ); Sun, 29 Nov 2015 21:12:54 -0500 Date: Mon, 30 Nov 2015 13:12:45 +1100 (AEDT) From: Finn Thain To: Geert Uytterhoeven cc: Ondrej Zary , "James E.J. Bottomley" , Michael Schmitz , linux-m68k , linux-scsi , linux-kernel Subject: Re: [PATCH 22/71] ncr5380: Eliminate selecting state In-Reply-To: Message-ID: References: <20151118083455.331768508@telegraphics.com.au> <201511252259.26792.linux@rainbow-software.org> <201511262035.40920.linux@rainbow-software.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 29 Nov 2015, Geert Uytterhoeven wrote: > If an ISA access takes 8 us, while the CPU runs at 1 GHz, i.e. 500M > loops/s, the difference will be huge. Ondrej showed that an ISA access can take about 1.6 us. I don't know what to make of the "8 uS" comment in the mainline driver. Maybe it was an even slower ISA card. Anyway, I made a measurement on my hardware and confirmed that lpj is a very bad proxy for device register access throughput. The "loops per access" gap is several orders of magnitude: lpj HZ access time (us) lpa ------------------------------------------------------------------------ Ondrej's 5380 ISA card (PC): 4797252 250 1.6 1.9k My DMX3191D PCI card (PowerMac): 167079 100 0.42 7.0 > > Perhaps you can calibrate an NCR5380_read() loop at driver init time, > and use the calibration value later? I had the same idea but I didn't think that the complexity was justified by the low precision requirement. But now that I have some timings I have to agree. --