Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp4029182rdb; Mon, 11 Dec 2023 07:04:56 -0800 (PST) X-Google-Smtp-Source: AGHT+IErvc/EqJrPZuuvJsoLMKlcNW4BljTXA/P4PhrZf0VLLtqxjel8EofdbQJj/nXAtunBlSes X-Received: by 2002:a05:6a20:4b21:b0:190:6617:270e with SMTP id fp33-20020a056a204b2100b001906617270emr5116038pzb.41.1702307096294; Mon, 11 Dec 2023 07:04:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702307096; cv=none; d=google.com; s=arc-20160816; b=ZTOZxK84X+PCdAPaSGEiVZSrEhxWvQq4PBKSpdrDi/KAEKJq5Uo9WhafAzpdgHVWws +uW8wB0+jdxPqakO4bsMgkPZcl8B8kJtg9TzMD6b+8/0Ec/Q1O/q+DpgdXWwwDbTRi9X sM9SptsHPUEtEBo9pk5+E8RXTSMzuoGj4BnHHhPRS2j8tnmduj12UGxB37/pyVDdzo7f cjt3FREXoekbjvV2+vDmpVRfER/UyBlzeQSVktH5zXNihC0Xq/bQAnpQAyLBDMYCOC6J wQ3MlOu/hRcQa5U72enWerPaD5A5IT80kGs1bSZxjGKl+enpGlInuohVx7atIXfztyuQ m6aA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version:date :message-id:subject:references:in-reply-to:cc:to:from:dkim-signature; bh=HzScoqO/ZuzCnWWzpJWRa7B6O5GM0zclC6FPEDxvANs=; fh=KlRFj/zwbnkVhVgLi7X+d6ire/PEvSYb87M/7X4N0Rw=; b=mS+etMzRDSZ2Rz+Z+RgZRR8Wk85EKqmvcWuFbR4jRu3Kjt0AxPSkG0EDlFnRQjUJIC 33wqbFPEHmvnW2CzyVSRVTrr95ElVvQS8UKjF+GBWwgyEhMMDIljdInHHxSsmhUwxiCy WLmavqRrKAy+sDFQk7IoBibKWsJ8GYxbt1FH22HOZxR8uWqo68WiMxYqrOImbCRXSrGK 3DRiIiNm/U8FY9PDS5KKyZw0lLrus3E4M2yKmk8EUOcyKnTQTUCruUpFYF6u6nnycTRD UAP0YbhWDhE6AU4Ek3POftoRUNWTza2hMziMPwUTqN8QaPSKq1hFw4WsP893YQCdAjQM 4cFw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ZRjQEhbz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id e20-20020a656794000000b005c620f350fdsi6177964pgr.341.2023.12.11.07.04.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Dec 2023 07:04:56 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ZRjQEhbz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id BB9A080A22EB; Mon, 11 Dec 2023 07:04:42 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343991AbjLKPEc (ORCPT + 99 others); Mon, 11 Dec 2023 10:04:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60562 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234944AbjLKPE3 (ORCPT ); Mon, 11 Dec 2023 10:04:29 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8CCD8DB for ; Mon, 11 Dec 2023 07:04:35 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 36E1CC433CB; Mon, 11 Dec 2023 15:04:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1702307075; bh=1YrRT7IzA4Ihuwv6ehGHUYg8NSaZHj7uaeGlSMs+Ub0=; h=From:To:Cc:In-Reply-To:References:Subject:Date:From; b=ZRjQEhbzmyMbkfryspKnxuwSVtvo317UrIoOzgcbKCrJYco0b3x2mhw52Ejiw5WhZ IDI9OGDUimIe13n2pvl8LOttmxdTXPDD9U817zSVzKf86totJFc9+XpwuQT5Jf4R/D jXrqmMwSM8xmL+nHD5H8suRERegClAE7X8u+WimS8bG6MfQAoN1argRVAbN0EGFZ9Q 1+bXP1Q04E9p1geo8w2YmcwjXPZTGimvBsLo0C9jKYIF+kWGAEV3xF8JU/cCS6iKbf PQYu5erNWE4uVqhJu/Aw4re9G1Mq1rbC5DhPXQirMnneblycesdh67vrBRInR7Ttxw pwYELzUkOm6Mw== From: Vinod Koul To: Amelie Delaunay Cc: dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20231124160235.2459326-1-amelie.delaunay@foss.st.com> References: <20231124160235.2459326-1-amelie.delaunay@foss.st.com> Subject: Re: [PATCH] dmaengine: dmatest: prevent using swiotlb buffer with nobounce parameter Message-Id: <170230707383.319997.16133040652159955271.b4-ty@kernel.org> Date: Mon, 11 Dec 2023 20:34:33 +0530 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Mailer: b4 0.12.3 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Mon, 11 Dec 2023 07:04:42 -0800 (PST) On Fri, 24 Nov 2023 17:02:35 +0100, Amelie Delaunay wrote: > Source and destination data buffers are allocated with GPF_KERNEL flag. > It means that, if the DDR is more than 2GB, buffers can be allocated above > the 32-bit addressable space. In this case, and if the dma controller is > only 32-bit compatible, swiotlb bounce buffer, located in the 32-bit > addressable space, is used and introduces a memcpy. > > To prevent this extra memcpy, due to swiotlb bounce buffer use because > source or destination data buffer is allocated above the 32-bit addressable > space, force source and destination data buffers allocation with GPF_DMA > instead, when nobounce parameter is true. > > [...] Applied, thanks! [1/1] dmaengine: dmatest: prevent using swiotlb buffer with nobounce parameter commit: 70f008fb3ea9bd2e6727eebc858405acd49a212b Best regards, -- ~Vinod