Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp4272550imm; Mon, 15 Oct 2018 11:53:29 -0700 (PDT) X-Google-Smtp-Source: ACcGV60zdPiTduUwPxmHXbkXNqnuViphjGz9jtu6i7hx1iXwFtoLb4m9V8fihibR4/Bt4quSYojT X-Received: by 2002:a63:b95c:: with SMTP id v28-v6mr17074936pgo.221.1539629609890; Mon, 15 Oct 2018 11:53:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539629609; cv=none; d=google.com; s=arc-20160816; b=HJQwsmN3nAKBtSGwwJ8hj9FPxscUTcEGcyrypWKgsYPlPmakn0Fk0MGvEaI8UaUB6A RB70JxcoQwm28hTV/ajQiIgMyfT3vQZApd5fBPei9dgBxNekWeHw3sFgs1zqiy2UdQgD jh9xDV2e/GljQZPKVUTbuRsItCIQB03oN23PVHyCb+ZBUc2Xk3ebxbfcEPovKFGd3R4f 0bKi+djxbVm2IlslVAED0H1shjTl+CNcECNip2trME1DmWojz1DebonuTcZl9bo+j/fo i6yQuzs81LAQYKuQ9NJ3OcczBP8OgYbGR9tep3+Ywxh/qohzQvuV3TgSkRS8NUD1nd/8 NzKA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject :dkim-signature; bh=LvlJKWLbOrAulcjHvwydWZksSapHFybt6NEQPd5hrgM=; b=z2TbtyLK/H3BPK29kF2uQgCTNFHtnzRO+cD6vUNo4atA9MXLk2j8LPP/sPyYpnDC3u 43xrLcuq2ADhMzHKqEkRAQk73l//6WQOA4DHU5rgchA8lh8TsEx4EJI7XeY35HydsGVi 6amwoEb/93eSNgNjCMiTsg+Q3lnHApUuUBCkm9lDb3/mFMUp1SUPc8vzE4s+xodMvyGU fhnfnN9EFHGROOiNd76FLPtk3zsTi3kP+dZELpg+BkV7ph/G6zL1sRKfVNnQ1r4shHfu fGeh4BCk4JvKJOE5Q9LbUyhmC5MNabxxNiYSbGTJmFs67agQYhJKuLQCZRdJJU9oXgU/ gtew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2018-07-02 header.b=qx0yaDQl; 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=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f11-v6si12934650plm.244.2018.10.15.11.53.13; Mon, 15 Oct 2018 11:53:29 -0700 (PDT) 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; dkim=pass header.i=@oracle.com header.s=corp-2018-07-02 header.b=qx0yaDQl; 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=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726904AbeJPCin (ORCPT + 99 others); Mon, 15 Oct 2018 22:38:43 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:50654 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726707AbeJPCin (ORCPT ); Mon, 15 Oct 2018 22:38:43 -0400 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w9FId6Te078044; Mon, 15 Oct 2018 18:52:07 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=LvlJKWLbOrAulcjHvwydWZksSapHFybt6NEQPd5hrgM=; b=qx0yaDQlOJ8JoxKtvHXqoLCR12fg+q06bvmsM6Di3ZHzxqCC/UOXmprNf14gPVhB+QGC bXEqZG1vCmAn3pjXf7gJ3QfjxHVzVSVqW54Ysj8PNd5m92cgcE0s6N6YYITzo+zkzs4g a7FitjbzqrhuVox2D2SVdpwYVsAYiYWcnVLdJN6+pJ5rCVVHWQkNs2iHvabeO6QxSFF+ lJRS7aYVjMxb++EJiGP/iVkPd349PjMSpBXzvlJ+mZxtaAiXxVFhiB/cceMFsRm6uKgL xDIL+OhkBx3LVu9g/pBgwvnhbPTQ2y29WUolki6ABRjRDYLjL5f9psel3BeSzIcp/PoO vw== Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp2120.oracle.com with ESMTP id 2n38npv9jv-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 15 Oct 2018 18:52:07 +0000 Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserv0021.oracle.com (8.14.4/8.14.4) with ESMTP id w9FIq6kP014220 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 15 Oct 2018 18:52:06 GMT Received: from abhmp0003.oracle.com (abhmp0003.oracle.com [141.146.116.9]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w9FIq6EQ001659; Mon, 15 Oct 2018 18:52:06 GMT Received: from konrads-mbp.lan (/209.6.36.129) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 15 Oct 2018 11:52:06 -0700 Subject: Re: [PATCH] x86: enable swiotlb for > 4GiG ram on 32-bit kernels To: Christoph Hellwig , x86@kernel.org Cc: tedheadster@gmail.com, iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org References: <20181014075208.2715-1-hch@lst.de> From: Konrad Rzeszutek Wilk Organization: Oracle Corporation Message-ID: <0a8d58b8-3c8b-c89f-e023-9d7d5d79f37c@oracle.com> Date: Mon, 15 Oct 2018 14:52:04 -0400 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <20181014075208.2715-1-hch@lst.de> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9047 signatures=668706 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1807170000 definitions=main-1810150162 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/14/18 3:52 AM, Christoph Hellwig wrote: > We already build the swiotlb code for 32b-t kernels with PAE support, > but the code to actually use swiotlb has only been enabled for 64-bit > kernel for an unknown reason. > > Before Linux 4.18 we papers over this fact because the networking code, > the scsi layer and some random block drivers implenented their own > bounce buffering scheme. > > Fixes: 21e07dba ("scsi: reduce use of block bounce buffers") > Fixes: ab74cfeb ("net: remove the PCI_DMA_BUS_IS_PHYS check in illegal_highdma") > Reported-by: tedheadster > Tested-by: tedheadster Reviewed-by: Konrad Rzeszutek Wilk But since it is already in 'tip' feel free to ignore my tag. Thanks! > --- > arch/x86/kernel/pci-swiotlb.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/arch/x86/kernel/pci-swiotlb.c b/arch/x86/kernel/pci-swiotlb.c > index 661583662430..71c0b01d93b1 100644 > --- a/arch/x86/kernel/pci-swiotlb.c > +++ b/arch/x86/kernel/pci-swiotlb.c > @@ -42,10 +42,8 @@ IOMMU_INIT_FINISH(pci_swiotlb_detect_override, > int __init pci_swiotlb_detect_4gb(void) > { > /* don't initialize swiotlb if iommu=off (no_iommu=1) */ > -#ifdef CONFIG_X86_64 > if (!no_iommu && max_possible_pfn > MAX_DMA32_PFN) > swiotlb = 1; > -#endif > > /* > * If SME is active then swiotlb will be set to 1 so that bounce >