Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752765AbbHEQZZ (ORCPT ); Wed, 5 Aug 2015 12:25:25 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:54588 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751294AbbHEQZY (ORCPT ); Wed, 5 Aug 2015 12:25:24 -0400 Date: Wed, 5 Aug 2015 18:25:22 +0200 From: Pavel Machek To: Jiri Slaby Cc: Chen Bough , Ulf Hansson , "linux-mmc@vger.kernel.org" , Linux kernel mailing list Subject: Re: [RFC] sdhci: fix DMA leaks [was: [SHDCI] Heavy (thousands) DMA leaks] Message-ID: <20150805162522.GC16341@amd> References: <55B9EF02.7040404@suse.cz> <55BF36D6.4080504@suse.cz> <55C1F919.4080002@suse.cz> <55C227B4.3030102@suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <55C227B4.3030102@suse.cz> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1528 Lines: 43 On Wed 2015-08-05 17:11:48, Jiri Slaby wrote: > On 08/05/2015, 01:52 PM, Jiri Slaby wrote: > >> Yes, I see: > >> sdhci-pci 0000:02:00.0: swiotlb buffer is full (sz: 65536 bytes) > >> after some time. The driver falls back to non-DMA transfers after that. > >> It also generates a warning about that: > >> WARNING: CPU: 0 PID: 0 at drivers/mmc/host/sdhci.c:857 > >> sdhci_prepare_data+0x8ec/0x900 [sdhci]() > > > > I am attaching a debug patch and a debug log. You can see where > > 0x00000000fffb0000 and 0x00000000fffe0000 is leaked. It is when 'invalid > > cookie' error happens. > > And you could see the cookie handling is totally bogus. > > With this rewrite, I no longer see the problems. Could you confirm it > still does the good job with respect to performance -- the numbers you > mentioned in your commit. > > Ulf, what do you think about the attached patch? (Do not look at the > commented info prints.) Umm. Normally we inline patches for easier comments. Attaching it with type of _mailbox_ is not really good. Pavel [-- Attachment #2: fix.patch --] [-- Type: application/mbox, Encoding: base64, Size: 8.2K --] -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html -- 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/