Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3171796pxj; Mon, 7 Jun 2021 04:17:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxk3tlnMFA3z9E3e8rxZuLHrHPOd9Irrm//9M/9D55qe9dYDMiAPhUVFeMowG9f/JGqgYIa X-Received: by 2002:a17:906:3da9:: with SMTP id y9mr17255320ejh.303.1623064662999; Mon, 07 Jun 2021 04:17:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623064662; cv=none; d=google.com; s=arc-20160816; b=b67+VwoixxyrnggD8k6s7Mq/HgwBw9ZADcAw+jYxkCGTTWAX0DxIEgtCTOvozGluZJ mWxTxLQvl5SM4/3qvmPQaMo9yE0v6Q/xcfFY/S4EjF85Hux6g545Fxb584yUzrDKHTRc fCpr0KDF5e0AXZzLjtQ6+R6R68o8BWwt/XRWSelYnWKiLC2tVkhzQ0RNThmy9YhoLzpo yYUWKgpxnIrb+Ic+5Af44DVuj7j4KVpJzCevine81zK8u1nEOvqncbi1v3OCF9f47/L5 7ny13aapoYSFdKZsK8DHVFtuyFnmPyxhnrlSqJKT/4dAJjzCCM9woznJmDkpbXXYeawV rbnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=7ACEmrf8lqyzWj1iuROjfn+lhLVzwVCH6LojGY7H628=; b=rb+GJ+P+Rg+T8SGBroYwgNo2DuKHH5rez8P6MaxZPTPsctt7Nxsx/kHEtMXwnWudSQ 3EO/lAdv87UtQSQM3Z1Fx6ke2lM5tdNJUZtCdkBVa4ZuNInZ/bweip/mePTEP46kUi+Z +Ti7dAIiN8cCTaEtSCv4ojZB3jYsxbRXbn496jM3wowe7pZPjOg47R5E8XiSCNOt7JxG 9JKgm9rVW9QODpOq9H/dDY/eB4JD68t9ZUMYxrqMSECmKVKchfj1298QMTxtGIP/3/7F ZUtBlyMBi71KZjpfUPD6AxPHvVq2OyVUSbk8SZuFPdkseFXGZ7BiiqrAY2+HHbWmI7fL Kzgg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="RCl/z9d6"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n16si11784497edq.422.2021.06.07.04.17.18; Mon, 07 Jun 2021 04:17:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="RCl/z9d6"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230479AbhFGLQI (ORCPT + 99 others); Mon, 7 Jun 2021 07:16:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37920 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230178AbhFGLQH (ORCPT ); Mon, 7 Jun 2021 07:16:07 -0400 Received: from mail-ej1-x62f.google.com (mail-ej1-x62f.google.com [IPv6:2a00:1450:4864:20::62f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9F447C061766; Mon, 7 Jun 2021 04:14:16 -0700 (PDT) Received: by mail-ej1-x62f.google.com with SMTP id ci15so25969390ejc.10; Mon, 07 Jun 2021 04:14:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=7ACEmrf8lqyzWj1iuROjfn+lhLVzwVCH6LojGY7H628=; b=RCl/z9d6IftfWrwk+FiDXEW1F4Mn9b/AoqsKhGfflCHlNXvTJ9X7vqkXg7AnJ4pOOj o/VpRMuHVuKIdT8beFckHMwzGGwmrDRVwOdiVBRZjJqi5gxGjx3g38TBe1oKxBflbWZp LWb8CbXm1Mgz/28+iLRyJSNOFEES4p4Pr52NVOdG5nMToeDwr0OIOk1w1ZyuICd8bfDF XmKNvV5HZ2rWQoWxLsZLnFUxv4He3otR1Q1dek1YAyT9p/ugydwXu5LNCSqtL1nFkGj5 Tl+eUz5HV2mC+qj3eljITRiR9G34f9AcVuOys+Zq/0jiHeNanhlG841eL8H6JN2haIiS Qybw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=7ACEmrf8lqyzWj1iuROjfn+lhLVzwVCH6LojGY7H628=; b=bS6GUXaJt2Snb0E7YJJhRL1WGjBD4FDBfQH7TQ0JqUcWupqS4rjzE192O/3K3OKv9x ZbFAVBbz5z+1wwpd/Ogz2uDuVvwUIVoalC6yHi4a4H4Bmi41prWFZSVfh0vZ0YtUak8T ao8gArxVsvtT/LCAMkZWTxjGUs8nZfJ4HgAE1S+A50/uj2nPmIuUU5VX2gw8rM42Hyny nV4CXL0snewABpZcsmyduWecOiT4FJNykPwpxGfl0ZPMxC/dm2FXf1Ro4FZ28WwIiM6n nyBXflu3utG7/0dfV9rd0LdBFHnE2oBeymkV3Q0YohmywQFK/suJ4tkHf3dB/HFbORwX YHtQ== X-Gm-Message-State: AOAM53193lFqXeXXb/0J1N/xnTERR7onPRo+iIEU6ZwmIUYqJtyGdvky GQ7Xy6rILg8ToMY3ZtVuXa8= X-Received: by 2002:a17:906:9713:: with SMTP id k19mr17643598ejx.516.1623064455283; Mon, 07 Jun 2021 04:14:15 -0700 (PDT) Received: from [10.80.22.114] ([193.47.165.251]) by smtp.gmail.com with ESMTPSA id n15sm6383140ejz.36.2021.06.07.04.14.10 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 07 Jun 2021 04:14:14 -0700 (PDT) Subject: Re: [PATCH net-next v6 3/5] page_pool: Allow drivers to hint on SKB recycling To: Ilias Apalodimas Cc: Matteo Croce , David Ahern , Yunsheng Lin , netdev@vger.kernel.org, linux-mm@kvack.org, Ayush Sawal , Vinay Kumar Yadav , Rohit Maheshwari , "David S. Miller" , Jakub Kicinski , Thomas Petazzoni , Marcin Wojtas , Russell King , Mirko Lindner , Stephen Hemminger , Tariq Toukan , Jesper Dangaard Brouer , Alexei Starovoitov , Daniel Borkmann , John Fastabend , Boris Pismenny , Arnd Bergmann , Andrew Morton , "Peter Zijlstra (Intel)" , Vlastimil Babka , Yu Zhao , Will Deacon , Fenghua Yu , Roman Gushchin , Hugh Dickins , Peter Xu , Jason Gunthorpe , Jonathan Lemon , Alexander Lobakin , Cong Wang , wenxu , Kevin Hao , Jakub Sitnicki , Marco Elver , Willem de Bruijn , Miaohe Lin , Guillaume Nault , linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org, bpf@vger.kernel.org, Matthew Wilcox , Eric Dumazet , Lorenzo Bianconi , Saeed Mahameed , Andrew Lunn , Paolo Abeni , Sven Auhagen References: <20210521161527.34607-1-mcroce@linux.microsoft.com> <20210521161527.34607-4-mcroce@linux.microsoft.com> <722e5567-d8ee-228c-978e-9d5966257bb1@gmail.com> <63a4ea45-9938-3106-9eda-0f7e8fe079ce@gmail.com> From: Tariq Toukan Message-ID: Date: Mon, 7 Jun 2021 14:14:09 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/7/2021 7:38 AM, Ilias Apalodimas wrote: > Hi Tariq, > >>>>> >>>>> Yes the comment is there to prohibit people (mlx5 only actually) to add the >>>>> recycling bit on their driver. Because if they do it will *probably* work >>>>> but they might get random corrupted packets which will be hard to debug. >>>>> >>>> >>>> What's the complexity for getting it to work with split page model? >>>> Since 1500 is the default MTU, requiring a page per packet means a lot >>>> of wasted memory. >>> >>> We could create a new memory model, e.g. MEM_TYPE_PAGE_SPLIT, and >>> restore the behavior present in the previous versions of this serie, >>> which is, save xdp_mem_info in struct page. >>> As this could slightly impact the performances, this can be added in a >>> future change when the drivers which are doing it want to use this >>> recycling api. >>> >> >> page-split model doesn't only help reduce memory waste, but increase >> cache-locality, especially for aggregated GRO SKBs. >> >> I'm looking forward to integrating the page-pool SKB recycling API into >> mlx5e datapath. For this we need it to support the page-split model. >> >> Let's see what's missing and how we can help making this happen. > > Yes that's the final goal. As I said I don't think adding the page split > model will fundamentally change the current patchset. So imho we should > get this in first, make sure that everything is fine, and then add code for > the mlx cards. > Sounds good