From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9E2F5C433EF for ; Wed, 29 Jun 2022 06:33:15 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 24F018E0001; Wed, 29 Jun 2022 02:33:15 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 1FE196B0072; Wed, 29 Jun 2022 02:33:15 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0ED158E0001; Wed, 29 Jun 2022 02:33:15 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 015FF6B0071 for ; Wed, 29 Jun 2022 02:33:14 -0400 (EDT) Received: from smtpin14.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id C24EB13D0 for ; Wed, 29 Jun 2022 06:33:14 +0000 (UTC) X-FDA: 79630306308.14.1BB5B40 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by imf23.hostedemail.com (Postfix) with ESMTP id 0F13C140034 for ; Wed, 29 Jun 2022 06:33:13 +0000 (UTC) Received: by verein.lst.de (Postfix, from userid 2407) id E206E68AFE; Wed, 29 Jun 2022 08:33:08 +0200 (CEST) Date: Wed, 29 Jun 2022 08:33:08 +0200 From: Christoph Hellwig To: Logan Gunthorpe Cc: linux-kernel@vger.kernel.org, linux-nvme@lists.infradead.org, linux-block@vger.kernel.org, linux-pci@vger.kernel.org, linux-mm@kvack.org, iommu@lists.linux-foundation.org, Stephen Bates , Christoph Hellwig , Dan Williams , Jason Gunthorpe , Christian =?iso-8859-1?Q?K=F6nig?= , John Hubbard , Don Dutile , Matthew Wilcox , Daniel Vetter , Minturn Dave B , Jason Ekstrand , Dave Hansen , Xiong Jianxin , Bjorn Helgaas , Ira Weiny , Robin Murphy , Martin Oliveira , Chaitanya Kulkarni , Ralph Campbell , Chaitanya Kulkarni Subject: Re: [PATCH v7 01/21] lib/scatterlist: add flag for indicating P2PDMA segments in an SGL Message-ID: <20220629063308.GB17234@lst.de> References: <20220615161233.17527-1-logang@deltatee.com> <20220615161233.17527-2-logang@deltatee.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220615161233.17527-2-logang@deltatee.com> User-Agent: Mutt/1.5.17 (2007-11-01) ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1656484394; a=rsa-sha256; cv=none; b=yA/DhqYIb2DXu6Lm4rPN+IcJbHVVCcVFke9K5E1MZIqi2XdC+4cMDSF9jRV8d0gY/zKOxt WEaLuZwkJrEp+BCQvCiRID4BmLwAL2OjGrLADOaUWRLSy3AjmS7+4FeVlJhg7tNaqOO4j0 zQAwnEl5CZVCghWno62nd4Oqy/1gyco= ARC-Authentication-Results: i=1; imf23.hostedemail.com; dkim=none; spf=none (imf23.hostedemail.com: domain of hch@lst.de has no SPF policy when checking 213.95.11.211) smtp.mailfrom=hch@lst.de; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1656484394; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ijpxmAbTE0vRZn+aZto/IHK42HMSoe2IL8nzCtTckDo=; b=qKuG2SPptggYfwojHU2FgY8qhPsSHlAlMnPEFI1BJlEDTzWvx1IOHvep2LpNof1JD46b0o aB1Hg0LAlKaqnFK26SPL4/RQFuLqVV9AiWWD/UNhFv2wmv6HabnkeQv1vs4XWafA3SSuXc CSDGOphAQ9rsUyHqKv74JEPLx01D/ds= X-Rspamd-Server: rspam09 X-Rspamd-Queue-Id: 0F13C140034 Authentication-Results: imf23.hostedemail.com; dkim=none; spf=none (imf23.hostedemail.com: domain of hch@lst.de has no SPF policy when checking 213.95.11.211) smtp.mailfrom=hch@lst.de; dmarc=none X-Rspam-User: X-Stat-Signature: c4hg1kxgeubkcy8g9chd9gxq8rtk658m X-HE-Tag: 1656484393-550019 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Wed, Jun 15, 2022 at 10:12:13AM -0600, Logan Gunthorpe wrote: > Make use of the third free LSB in scatterlist's page_link on 64bit systems. > > The extra bit will be used by dma_[un]map_sg_p2pdma() to determine when a > given SGL segments dma_address points to a PCI bus address. > dma_unmap_sg_p2pdma() will need to perform different cleanup when a > segment is marked as a bus address. > > The new bit will only be used when CONFIG_PCI_P2PDMA is set; this means > PCI P2PDMA will require CONFIG_64BIT. This should be acceptable as the > majority of P2PDMA use cases are restricted to newer root complexes and > roughly require the extra address space for memory BARs used in the > transactions. > > Signed-off-by: Logan Gunthorpe > Reviewed-by: Chaitanya Kulkarni Looks good: Reviewed-by: Christoph Hellwig