From patchwork Thu Aug 20 13:45:21 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Krzysztof Halasa X-Patchwork-Id: 31736 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@bilbo.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from ozlabs.org (ozlabs.org [203.10.76.45]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mx.ozlabs.org", Issuer "CA Cert Signing Authority" (verified OK)) by bilbo.ozlabs.org (Postfix) with ESMTPS id C5751B70CF for ; Thu, 20 Aug 2009 23:46:59 +1000 (EST) Received: by ozlabs.org (Postfix) id B869ADDD0B; Thu, 20 Aug 2009 23:46:59 +1000 (EST) Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id 4E494DDD04 for ; Thu, 20 Aug 2009 23:46:59 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754641AbZHTNpc (ORCPT ); Thu, 20 Aug 2009 09:45:32 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754487AbZHTNpa (ORCPT ); Thu, 20 Aug 2009 09:45:30 -0400 Received: from khc.piap.pl ([195.187.100.11]:56677 "EHLO khc.piap.pl" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754632AbZHTNp0 convert rfc822-to-8bit (ORCPT ); Thu, 20 Aug 2009 09:45:26 -0400 Received: from intrepid.localdomain (intrepid.localdomain [10.0.0.2]) by khc.piap.pl (Postfix) with ESMTP id 7C89F934E; Thu, 20 Aug 2009 15:45:21 +0200 (CEST) To: Walt Holman Cc: David Miller , linux-kernel@vger.kernel.org, netdev@vger.kernel.org Subject: Re: Strange network timeouts w/ 2.6.30.5 References: <985009134.71250769263099.JavaMail.root@mail.holmansrus.com> From: Krzysztof Halasa Date: Thu, 20 Aug 2009 15:45:21 +0200 In-Reply-To: <985009134.71250769263099.JavaMail.root@mail.holmansrus.com> (Walt Holman's message of "Thu\, 20 Aug 2009 06\:54\:23 -0500 \(CDT\)") Message-ID: MIME-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Walt Holman writes: > dmesg is attached. This box does have >2GB Ram (6GB total). The dmesg > will show e100 init'd 3 times since the first is the stock modprobe, > 2nd was forced with use_io and the 3rd modprobe was after reverting > the patch. You most probably can't test without swiotlb (RAM has to be limited to 2 GB or so), can you? That would (dis)prove my theory. Alternatively (or better), a test on IOMMU-equipped system would do. Since swiotlb is x86-only thing (though other 64-bit archs may have something similar), I think the correct work around is to enable the "for_device" handoff on !X86. Something like maybe: Signed-off-by: Krzysztof HaƂasa diff --git a/drivers/net/e100.c b/drivers/net/e100.c index 014dfb6..b610088 100644 --- a/drivers/net/e100.c +++ b/drivers/net/e100.c @@ -1762,9 +1762,12 @@ static int e100_rx_indicate(struct nic *nic, struct rx *rx, if (ioread8(&nic->csr->scb.status) & rus_no_res) nic->ru_running = RU_SUSPENDED; +#ifndef CONFIG_X86 + /* FIXME interferes with swiotlb. */ pci_dma_sync_single_for_device(nic->pdev, rx->dma_addr, sizeof(struct rfd), PCI_DMA_BIDIRECTIONAL); +#endif return -ENODATA; }