From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3D79E606A31A for ; Wed, 2 Dec 2026 06:57:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=osuosl.org header.i=@osuosl.org header.a=rsa-sha256 header.s=default header.b=jw2ZzgWL; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=K5iJpBwo Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 1F33880F50; Wed, 2 Dec 2026 06:57:48 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id HQ_3eW8Ec_PM; Wed, 2 Dec 2026 06:57:47 +0000 (UTC) ARC-Filter: OpenARC Filter v1.3.2 smtp1.osuosl.org 7FAA680F22 Authentication-Results: smtp1.osuosl.org; arc=none smtp.remote-ip=140.211.166.142 ARC-Seal: i=1; d=osuosl.org; s=arc; a=rsa-sha256; cv=none; t=1796194667; b=KghcZWbICYnjXBNnNs7gJ+EtU67qqNzdeQf02h+x3MMY8n65+uJoZQHQ6ndACzF6mQJf d0hpdfjtQFSBeFC9wM7pjhkM3swDAmuuR4ck4ZsXkOYdYmUE4jNduZvbtuaAquqGTBSet YHTKap27OYCxZFKRoZujFKpgNp+DfmEqFQOVXJmvRarVcHW4PnhmSpW3R8Dz0ED1ROMF5 WEtwgQ8XrUJghtiMzJgTIyLToxrCXVXsaHfZv6wzjaUYaOoVBmPX8KSURnL/hGUayHv0Q wKxwmW25uuKBgdghGdza1kzJ9uuR+0vtqFC9mYtgjQhtlNuSO3FlRo1/lXUPPwjYBPA== ARC-Message-Signature: i=1; d=osuosl.org; s=arc; a=rsa-sha256; c=relaxed/relaxed; t=1796194667; h=X-Comment:DKIM-Signature:X-Original-To:Delivered-To:Received: Received:X-Virus-Scanned:X-Spam-Flag:X-Spam-Score:X-Spam-Level: X-Spam-Status:Received:ARC-Filter:Received-SPF:Received:Received: DKIM-Signature:X-Google-DKIM-Signature:X-Forwarded-Encrypted: X-Gm-Message-State:X-Received:Date:In-Reply-To:Mime-Version: References:X-Mailer:Message-ID:Subject:From:To:Cc:Content-Type: X-BeenThere:X-Mailman-Version:Precedence:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:Errors-To; bh=JpuLB2ABtKMrC3RumXednwnGDFPQ0l5JFAGo1QdSShE=; b=gPc3dUnBLU5Y5AXjlMhzRzTaHgvM/76gFfJVLI9QXjBMM8eeooXnFgqpr53Oih/4l/S5 T7p5x9c4CoHfdqQL2OPqLvY0KFSdcGH8XlSzFY1zNAfrmYbpMbtp28eG9HJ9GKQ4wSp/6 2UXdW6lfAF6RDdFKLolMTzd7T3W7h7oVj9jXe9PMRrpl6Euh2H6wEKbiUSqtkc+MOcmua weO72Q07cgyhZ8TeQE5Mz2TXmGdlSyqoRtOHLz1nX6opgFBg6Oo2JfefilxENecEjWWIm /vhxGoDgCBkeVlUTmazylRDbOS40K3tEIUgIK4+IdiG5udzCGFzm3dPiTk3F/HqPukA== ARC-Authentication-Results: i=1; smtp1.osuosl.org; dmarc=pass header.from=google.com; dkim=pass header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=K5iJpBwo; arc=none smtp.remote-ip=140.211.166.142 X-Comment: SPF check N/A for local connections - client-ip=140.211.166.142; helo=lists1.osuosl.org; envelope-from=intel-wired-lan-bounces@osuosl.org; receiver= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org; s=default; t=1796194667; bh=JpuLB2ABtKMrC3RumXednwnGDFPQ0l5JFAGo1QdSShE=; h=Date:In-Reply-To:References:Subject:From:To:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=jw2ZzgWLdKJkr0yqDUbIUvxjepPt1SU//nE431CjcUgnpnG1rx4oQNO7lOOnr5Z+D xrlO4ZrmA24YhNuL8KS5FO81DeIvcDOISkO9Ut82/RcQMYG/4M482ns523ZvERNeUn 19WpHXQDGR97MuJ47UoS11LxCIf2vSILCaXSXjaz0q0OSkGMzrLhCHNclxb8rTps6D t3BdZzlxhoOK1I00+aP20U30rxDPbfKshhS+KDlRe34I0HM/lwvoB50saPKSwu9c/t SbUxg53JV2xuyb1443A44DszR7AqsYUTQJK0pBsdvCEzZnrkGXF4WBdqMh1gEuj7gb xRfUYOzCnY5RA== Received: from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142]) by smtp1.osuosl.org (Postfix) with ESMTP id 7FAA680F22; Wed, 2 Dec 2026 06:57:47 +0000 (UTC) Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) by lists1.osuosl.org (Postfix) with ESMTP id D69612FF for ; Wed, 2 Dec 2026 06:57:45 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id A703F80F1C for ; Wed, 2 Dec 2026 06:57:45 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id drhO3I5sCpkX for ; Wed, 2 Dec 2026 06:57:45 +0000 (UTC) ARC-Filter: OpenARC Filter v1.3.2 smtp1.osuosl.org 09BE880EDC Authentication-Results: smtp1.osuosl.org; arc=none smtp.remote-ip="2607:f8b0:4864:20::648" Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=2607:f8b0:4864:20::648; helo=mail-pl1-x648.google.com; envelope-from=3zsepawykd4cv5yt95rzzrwp.nzxty4pw-7t2po-wlywt343.z35z3w.z2r@flex--kuniyu.bounces.google.com; receiver= Authentication-Results: smtp1.osuosl.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=K5iJpBwo Received: from mail-pl1-x648.google.com (mail-pl1-x648.google.com [IPv6:2607:f8b0:4864:20::648]) by smtp1.osuosl.org (Postfix) with ESMTPS id 09BE880EDC for ; Wed, 2 Dec 2026 06:57:43 +0000 (UTC) Received: by mail-pl1-x648.google.com with SMTP id d9443c01a7336-2f0f5721453so49303315ad.0 for ; Tue, 01 Dec 2026 22:57:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20260707; t=1796194663; x=1796799463; darn=lists.osuosl.org; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:from:to:cc:subject:date:message-id:reply-to :content-type; bh=JpuLB2ABtKMrC3RumXednwnGDFPQ0l5JFAGo1QdSShE=; b=K5iJpBwo8BCACF71yx662F22zvAm+A3XB9Rpkacu98n/fP3aYlKmMOv93FNxXdN8np A/2N1/QqKPfdeespT5B+dqFMjC9rnFJNk5X8EGuA8RVtpNIUEP3bpsmMxCyanLHQRtiG QvkvWWQMAwfZWtxQ7viLHghhC/k5bvbPSqogCsGKl3RUec3h3rcrUON28R0Edu3YhMEj XwIiuzmcqf9Xkn/iOZdUthIl1BDTUYM3jGOn4APVUEGK7ux2aCEY2G8aIQ+c7DOkyWh4 o/bWAueJ0/Wvdc0FWiNBHflTZVhx99RaNnfU0+OzYhU4Bg7ypqUYpkQKPsnd9pSH2aL8 ljaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796194663; x=1796799463; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=JpuLB2ABtKMrC3RumXednwnGDFPQ0l5JFAGo1QdSShE=; b=WIOPhNRR9IwGkOly51Y/ATefEOqPf264j2Il5QmuCdNRBQFhJzxEcrK29B8kKEhIaz wTi2EFCfqX7HekTAkBYue1yMO0FKq+7Ec+0LrVyxBQ62RMVhqBA08BSdGRDKKg4zyUCr tX7q1WoYeMIrCxqm5+xhCCi4paPMw4g9k5xDJxXWVBXV1eT45cw7BJp/r2FYushLgG0B Jd+jDje4G8VU0TogTfSMPKa+Eo9AE0sC4QEzn+P965cqCWfUS/Tb7optpYNWRKHig7L3 6McDimRZ7Fq3Kh8pNSEo+kbJlvdkepcnFB7cnlvFcmfq4Fg3Pc9UVuI2ZNwFc810nZoB hpFQ== X-Forwarded-Encrypted: i=1; AL+hErG2zTLLxS0wYA+jPi4dtnHu/Pdr2OAydgEJk7jIjA8tp8ZMNfJCyXLF4rmKJl8rXKhtn/lta3RZMt5lKI6TEh8=@lists.osuosl.org X-Gm-Message-State: APuU4Z93DwWWm7gyIiz/Zg8387TXCSOLTykN08wg3+p2RET7+j49hXoJ xjIkyXbLAp/nhgFmpFk8WqOOw/14aeW3+yg0w8iAb3pAmyRUeAKQ9gtXpeU6OeEHOVPVxZa2Up+ ddQBSiA== X-Received: from plbla13.prod.google.com ([2002:a17:902:fa0d:b0:2f0:cf6f:8311]) (user=kuniyu job=prod-delivery.src-stubby-dispatcher) by 2002:a17:902:f70f:b0:2ef:e1a8:ef1f with SMTP id d9443c01a7336-2f03ef44b2emr398144925ad.5.1796194662924; Tue, 01 Dec 2026 22:57:42 -0800 (PST) Date: Wed, 2 Dec 2026 15:57:22 +0900 In-Reply-To: <20261202065737.207610-1-kuniyu@google.com> X-Archived-By: Mime-Version: 1.0 References: <20261202065737.207610-1-kuniyu@google.com> X-Mailer: git-send-email 2.56.1.911.g883d8bcb20-goog Message-ID: <20261202065737.207610-5-kuniyu@google.com> Subject: [PATCH v1 iwl-next 4/5] libeth: Allow opting out of page_pool DMA mapping on Rx. From: Kuniyuki Iwashima To: Alexander Lobakin , Tony Nguyen , Przemek Kitszel Cc: Kuniyuki Iwashima , Kuniyuki Iwashima , intel-wired-lan@lists.osuosl.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: intel-wired-lan@osuosl.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Intel Wired Ethernet Linux Kernel Driver Development List-Archive: List-Post: List-Help: List-Subscribe: , X-Spam-Status: No, score=-26.4 required=3.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_PASS,USER_AGENT_GIT,USER_IN_DEF_DKIM_WL autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 libeth_rx_fq_create() always configures PP_FLAG_DMA_MAP and PP_FLAG_DMA_SYNC_DEV, so drivers cannot manage page_pool DMA mappings themselves. Let's add a no_dma_map flag to struct libeth_fq to omit PP_FLAG_DMA_MAP and PP_FLAG_DMA_SYNC_DEV. Signed-off-by: Kuniyuki Iwashima --- drivers/net/ethernet/intel/libeth/rx.c | 3 ++- include/net/libeth/rx.h | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/intel/libeth/rx.c b/drivers/net/ethernet/intel/libeth/rx.c index 0c1a565a1b3a..c9ab17b16fef 100644 --- a/drivers/net/ethernet/intel/libeth/rx.c +++ b/drivers/net/ethernet/intel/libeth/rx.c @@ -153,7 +153,8 @@ int libeth_rx_fq_create(struct libeth_fq *fq, void *napi_dev) { struct napi_struct *napi = fq->no_napi ? NULL : napi_dev; struct page_pool_params pp = { - .flags = PP_FLAG_DMA_MAP | PP_FLAG_DMA_SYNC_DEV, + .flags = fq->no_dma_map ? 0 : + (PP_FLAG_DMA_MAP | PP_FLAG_DMA_SYNC_DEV), .order = LIBETH_RX_PAGE_ORDER, .pool_size = fq->count, .nid = fq->nid, diff --git a/include/net/libeth/rx.h b/include/net/libeth/rx.h index 1333850f421a..9e721cf2aac6 100644 --- a/include/net/libeth/rx.h +++ b/include/net/libeth/rx.h @@ -70,6 +70,7 @@ enum libeth_fqe_type { * @hsplit: flag whether header split is enabled * @xdp: flag indicating whether XDP is enabled * @no_napi: the queue is not a data queue and does not have NAPI + * @no_dma_map: opt out of page_pool DMA mapping * @buf_len: HW-writeable length per each buffer * @nid: ID of the closest NUMA node with memory */ @@ -87,6 +88,7 @@ struct libeth_fq { bool hsplit:1; bool xdp:1; bool no_napi:1; + bool no_dma_map:1; u32 buf_len; int nid; -- 2.56.1.911.g883d8bcb20-goog