Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp107943iob; Tue, 17 May 2022 20:26:40 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzusO4rVgrlpL3wyaEkHwLBCdph29Wn51HCM8R2g5EsC+yBF8gO18sfl8NHmdQRhhJMI0ZS X-Received: by 2002:a17:90b:4d90:b0:1de:b54f:c5d with SMTP id oj16-20020a17090b4d9000b001deb54f0c5dmr27786352pjb.27.1652844400720; Tue, 17 May 2022 20:26:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652844400; cv=none; d=google.com; s=arc-20160816; b=S6cSK0xjHUmWzbX2OYd3rkiW/0o1cg+05jIBrTKUrnfir6x4RY00/WNwkocre1qOrC N9z1G6+yypkAX70/sWelLMUbASHcIE8Z5FS8LuEb/60rN7jSG3FkZwgcBlQ32itkNdaM GyB1pM8wn+0IaL0arEo6pyKUHvYGV6IULKCHXVIp0XAPpCYHS+xXHP8EKnl6PhgncZXe SFiYYqrqygZLY6pgR/TTGeseOupGKiE4kuVrmpbANaPmF19HC1ZKSE1xnrooYdD4fWca ldNWPGuRTWn4xffA9ISHnbR2Ru38XEkNs++H3pUIR97hpWDbmWl4SwSQSQe9iCEP0WPv 3xIQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=QnbKYBhh3c63Yumph0EWjqW7Wj2wBUNjFmt4Rfdy8jc=; b=v8WjKBjznWswF4zg9Gku7/aWYvAxFjgYWPchX/F8vFg4PJDOafAx2q3p7nvsRNe/ou QXAFMYAnSHsmO5SuFlLeVDfRdf1uICLELWs8T7VsT4uD7kMYP1Sa73wB1lY2lpimfs7L oZK6S76/1W7IfC8515lrS/o3Ob9raoKqrZDAvsH/8qY11XEPKiJYlzNGdGhak7y/jjXN 6QcJb+bYwuWgZCH4pQ14/cYQP2H0vDyANbiPXpaZBDZ6DJr8PI+IzhCO18VsDMDw24JT r4dbStk07sva+fTR86/hpJ85gNq2vz8SshwyM0iS2NHI5jkRcJMo8J4JzREb9x9c6JhA DxDA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b=UCDLE6md; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id x24-20020a63db58000000b003f5ddd8592esi1225982pgi.189.2022.05.17.20.26.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 May 2022 20:26:40 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b=UCDLE6md; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 26EA9689B2; Tue, 17 May 2022 20:22:09 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352764AbiEQTf2 (ORCPT + 99 others); Tue, 17 May 2022 15:35:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48356 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348481AbiEQTfT (ORCPT ); Tue, 17 May 2022 15:35:19 -0400 Received: from mail-qk1-x72a.google.com (mail-qk1-x72a.google.com [IPv6:2607:f8b0:4864:20::72a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 41E9E522D2 for ; Tue, 17 May 2022 12:35:18 -0700 (PDT) Received: by mail-qk1-x72a.google.com with SMTP id c1so15312609qkf.13 for ; Tue, 17 May 2022 12:35:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=QnbKYBhh3c63Yumph0EWjqW7Wj2wBUNjFmt4Rfdy8jc=; b=UCDLE6mdjuGa1AhVdCEcBtExr96rjGXBSfEIQfr7ykTyHhQER0s0t79knhisfx/JC1 LjKqwJmJLW3zBjmEU2Rnwt7SKxPUics0pfUJVLOHxKJJL3Q18/6zj6anFNufHe7u6Twr LNNH2zyFm1uVvNAvNrH6PLvqGI5JoCIpeafoNbKLk2ArMwb81GrFbAO0pw1kAq5TfDWw lIO8eTksc5Cgo1IbAOny3t54T3tlORvXjrZ2VxK2keaT+hG7v0H6LH8ca5anh2hlDwDE y02VhaC+GMQGeVU/EG/l6UccIUFS9muojSW9hKGhwex+CwPVJm9IvzBQ+NRJGsIXocRd rdcw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=QnbKYBhh3c63Yumph0EWjqW7Wj2wBUNjFmt4Rfdy8jc=; b=1qycGQAU3ngLVQaY15A8XaPM1vEgMsXZ5AlVxjJ6Ic+mtKNni4BFHHvdNkwKjRQszW T8T4bVL7E+gpWIh4/BwNGeDSJooie5eH2/+gPzLo/jAGtaX1ZkrxcJviqA9v8kD+pKyp TahEyaM3mqQ4vAFXrabGYkQKNS9Cz5LBMBfrYq1ugCFyZlsCa9/BuH9NQaQqogprxTNZ dQIzC89tWhgPFGcwgbB1rglSlWlQ0X8V0NUkDWBBolbNJedTz29n+qFjmVB+r66xAc/I v/2QCu51jymzJ4AiGDkD7mWNbZX5o3Q9PdXVEJzYJkFCOg//5tTYpqbQrcHmwEvArLQ1 Wygg== X-Gm-Message-State: AOAM530H/Rv6Je9tDLJUmYTo+gKleP7Wg8zLW17Ly57CaQ41B80YKsMg yFp0HrZQBSoOl0ay6tw6NXOq/g== X-Received: by 2002:a37:a04b:0:b0:69f:baff:b185 with SMTP id j72-20020a37a04b000000b0069fbaffb185mr17318830qke.176.1652816117436; Tue, 17 May 2022 12:35:17 -0700 (PDT) Received: from ziepe.ca (hlfxns017vw-142-162-113-129.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.113.129]) by smtp.gmail.com with ESMTPSA id f6-20020a05622a114600b002f39b99f69esm8203853qty.56.2022.05.17.12.35.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 May 2022 12:35:16 -0700 (PDT) Received: from jgg by mlx with local (Exim 4.94) (envelope-from ) id 1nr2yR-008A2U-Qr; Tue, 17 May 2022 16:35:15 -0300 Date: Tue, 17 May 2022 16:35:15 -0300 From: Jason Gunthorpe To: Long Li Cc: KY Srinivasan , Haiyang Zhang , Stephen Hemminger , Wei Liu , Dexuan Cui , "David S. Miller" , Jakub Kicinski , Paolo Abeni , Leon Romanovsky , "linux-hyperv@vger.kernel.org" , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-rdma@vger.kernel.org" Subject: Re: [PATCH 05/12] net: mana: Set the DMA device max page size Message-ID: <20220517193515.GN63055@ziepe.ca> References: <1652778276-2986-1-git-send-email-longli@linuxonhyperv.com> <1652778276-2986-6-git-send-email-longli@linuxonhyperv.com> <20220517145949.GH63055@ziepe.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 On Tue, May 17, 2022 at 07:32:51PM +0000, Long Li wrote: > > Subject: Re: [PATCH 05/12] net: mana: Set the DMA device max page size > > > > On Tue, May 17, 2022 at 02:04:29AM -0700, longli@linuxonhyperv.com wrote: > > > From: Long Li > > > > > > The system chooses default 64K page size if the device does not > > > specify the max page size the device can handle for DMA. This do not > > > work well when device is registering large chunk of memory in that a > > > large page size is more efficient. > > > > > > Set it to the maximum hardware supported page size. > > > > For RDMA devices this should be set to the largest segment size an ib_sge can > > take in when posting work. It should not be the page size of MR. 2M is a weird > > number for that, are you sure it is right? > > Yes, this is the maximum page size used in hardware page tables. As I said, it should be the size of the sge in the WQE, not the "hardware page tables" Jason