Received: by 2002:ac0:8c9a:0:0:0:0:0 with SMTP id r26csp5510747ima; Tue, 5 Feb 2019 13:03:02 -0800 (PST) X-Google-Smtp-Source: AHgI3Ia5gRMoWm4rLpftEohJzHVGfoUv0YJGZGGoiUS8a4OzMSyP10mHFhbILLnU6gT1gsAXtsJd X-Received: by 2002:a63:30c8:: with SMTP id w191mr6553511pgw.120.1549400582160; Tue, 05 Feb 2019 13:03:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549400582; cv=none; d=google.com; s=arc-20160816; b=lYh+AERacDTkweeChikf103tGtrGaSoDOFW5/pkV3CSV82bg4rsEgaYueiwSuwpoP6 x1H4t1Tnza2j7GL4styIDTf07JpCog5w3rKOmwhsSu8hFhAy+oIG3sA6lEV6D/yKlTe4 VCeV0lhuiaK3TTv04IlB0m1QgYQtO3UbYWG63DcWzPznP/nR9wcIkmnlLHvRWqQINoKn RB0QapSjqJQWRkXmgI9Qe70n0MlV95XloWKYj+NRLa5lOVLwFrtFAPraofM4qHCtqPR+ vIFyBPPpvhifV9c8q4erz6hX2X1sPM4+N+iZxEl3YUWz2l2oXWvSndz4wZi3IxSgkiQl bIqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=8fd8npBaH89eIS9ik52ObC3uPr2xtrIZVVrmtX90oOM=; b=QcyA1VK92U4pAtDJ8p2HdIidn1uVMOlWdiznDDlPaDZC0GTKu+U0+V41PiB9/JjwBH MVUAu+ix1XOo6vhfopOyRhO8xQ4k6DpP7O0p/bUfWjtSJIA0mbcztFDom7kbQB7rbXF8 7eiO3hwLMODyyWvGexOhyZkQAafEs4Sy+moIaNWiB9Xzr2teadrhy5tK4ueqmvoZ/AAp 6hXyoXZGUOLtP/3rgN9xFtdMeiKlSiNuRzg4zzArFWUGre4PDH/JTpoTZafpap+qmJ3k yN1scHvFzYVNYq7a8RjHqbEzu9oj0c/Ji3sL/yyfAvCPYIjuW7RAhk0kvW1uBP6EZdef J5vg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q14si4042226pgf.47.2019.02.05.13.02.45; Tue, 05 Feb 2019 13:03:02 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728182AbfBEUwt (ORCPT + 99 others); Tue, 5 Feb 2019 15:52:49 -0500 Received: from mx1.redhat.com ([209.132.183.28]:46748 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726114AbfBEUwt (ORCPT ); Tue, 5 Feb 2019 15:52:49 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B1F0FC0528BD; Tue, 5 Feb 2019 20:52:48 +0000 (UTC) Received: from redhat.com (ovpn-116-138.sin2.redhat.com [10.67.116.138]) by smtp.corp.redhat.com (Postfix) with SMTP id 331D7601B0; Tue, 5 Feb 2019 20:52:40 +0000 (UTC) Date: Tue, 5 Feb 2019 15:52:38 -0500 From: "Michael S. Tsirkin" To: Joerg Roedel Cc: Jason Wang , Konrad Rzeszutek Wilk , Christoph Hellwig , Jens Axboe , virtualization@lists.linux-foundation.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, iommu@lists.linux-foundation.org, jfehlig@suse.com, jon.grimm@amd.com, brijesh.singh@amd.com, jroedel@suse.de, Thomas.Lendacky@amd.com Subject: Re: [PATCH 0/5 v6] Fix virtio-blk issue with SWIOTLB Message-ID: <20190205155133-mutt-send-email-mst@kernel.org> References: <20190131163403.11363-1-joro@8bytes.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190131163403.11363-1-joro@8bytes.org> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Tue, 05 Feb 2019 20:52:49 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 31, 2019 at 05:33:58PM +0100, Joerg Roedel wrote: > Hi, > > here is the next version of this patch-set. Previous > versions can be found here: > > V1: https://lore.kernel.org/lkml/20190110134433.15672-1-joro@8bytes.org/ > > V2: https://lore.kernel.org/lkml/20190115132257.6426-1-joro@8bytes.org/ > > V3: https://lore.kernel.org/lkml/20190123163049.24863-1-joro@8bytes.org/ > > V4: https://lore.kernel.org/lkml/20190129084342.26030-1-joro@8bytes.org/ > > V5: https://lore.kernel.org/lkml/20190130164007.26497-1-joro@8bytes.org/ > > The problem solved here is a limitation of the SWIOTLB implementation, > which does not support allocations larger than 256kb. When the > virtio-blk driver tries to read/write a block larger than that, the > allocation of the dma-handle fails and an IO error is reported. > > Changes to v5 are: > > - Changed patch 3 to uninline dma_max_mapping_size() And this lead to problems reported by kbuild :( BTW when you repost, can I ask you to pls include the version in all patches? Both --subject-prefix and -v flags to git format-patch will do this for you. > Please review. > > Thanks, > > Joerg > > Joerg Roedel (5): > swiotlb: Introduce swiotlb_max_mapping_size() > swiotlb: Add is_swiotlb_active() function > dma: Introduce dma_max_mapping_size() > virtio: Introduce virtio_max_dma_size() > virtio-blk: Consider virtio_max_dma_size() for maximum segment size > > Documentation/DMA-API.txt | 8 ++++++++ > drivers/block/virtio_blk.c | 10 ++++++---- > drivers/virtio/virtio_ring.c | 11 +++++++++++ > include/linux/dma-mapping.h | 8 ++++++++ > include/linux/swiotlb.h | 11 +++++++++++ > include/linux/virtio.h | 2 ++ > kernel/dma/direct.c | 11 +++++++++++ > kernel/dma/mapping.c | 14 ++++++++++++++ > kernel/dma/swiotlb.c | 14 ++++++++++++++ > 9 files changed, 85 insertions(+), 4 deletions(-) > > -- > 2.17.1