From nobody Wed Sep 07 10:04:53 2022 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4MMyY13bB3z4c5gh; Wed, 7 Sep 2022 10:04:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4MMyY12mdzz4Mlb; Wed, 7 Sep 2022 10:04:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1662545093; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zcHYR6xuNosv3uDftoak/d11b8D2kSXhYTeXXBZCt84=; b=AMapd3aOicdX9k3B08e8jCVMiVNUw6tuypmlQa9JxF67ltgMlIVNg4/P5kLho3UfvWkhcT OGy1RJizOapMMHZdeyzwJQ+IvOjXTFuSNze1nZSHSqf0CbVcUOnLrEsX2873FAw6jrjWpd /HoBJDgm7H5UAlsOwiGDhIlGneoWtMsdIDT0DRLyYb0FxNd5W6zXV9n+lVlGV9OEUjXP+e kKt7X3+MPp7JYekK5bjepDHC0tkhGUgeqi7e6/DFNM9UtR8NZAYPpaRTk5Xm1BHyMQbxwI YxRZuPuUZ223A4aPMLStT2KPoDEJt8FshoD9SAAvcUm9wZSablgEaXe5+RxFhA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4MMyY11rmFzVHk; Wed, 7 Sep 2022 10:04:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 287A4r69044102; Wed, 7 Sep 2022 10:04:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 287A4rAI044101; Wed, 7 Sep 2022 10:04:53 GMT (envelope-from git) Date: Wed, 7 Sep 2022 10:04:53 GMT Message-Id: <202209071004.287A4rAI044101@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mateusz Guzik Subject: git: 14c9a2dbfbb0 - main - net: retire PFIL_FWD List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 14c9a2dbfbb081c59d091001b7ddf75eef00da07 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1662545093; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zcHYR6xuNosv3uDftoak/d11b8D2kSXhYTeXXBZCt84=; b=XvgQ/Fu/mPaKTI3dWJQBUaMtRpszqpiDROBO7Sg3pAtTQQG6tat/Zfj51QoorLeqlfP+E5 hNYvg6LpxkFBgOeLRTBiz3s1cIpUzJGpyG6l4NYg77qJlJqAs/lcjQKRB3ifbC3FgHpmz8 q8dLlzTRieLxElFIGDwzijh/HKJWsLfIB7V1Pu7oRZVG4WsfV3SEu0FDffWHLHq4HMKs1y lcsygwtCGLruxSiUm6iKeesSjY5RzA/0GsTbd0eEMXU/TWjqEqI+iqk4yrP6IY4bXowRXV rLWeMpBd0HRkh8onp0czkc5EdPR8E56+V3ZNfWNN0HAFFeIhOafg76pXDw5Www== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1662545093; a=rsa-sha256; cv=none; b=a0llr2We+zwISuWwF4JfE96CYQbn2u9kkjqarSYQnlRKQbbvV+QOBZZPcvs6Gth+OOi/xx aa7cRpFEb1WYoKdqzzYZ5ukbVMz4jb9mFogUagN9ZDG0KItk71fF6o0RV2QsQI+N0q4Tqn dF7GP7et3aY9vTd3JhmbG+qnQwW4JREmV8ynTpNCV9VL33dcbR3D8I1K2eWy3cX9blDQHw SFQPhEmup6HxGKzyu2PoJbaJ60nIt12cC9yvkU0p46/yO4akwbke0hEzEopXyXtOmIUOhl LfjASKWmkHCe2kD+XH+Uh1GLx09YF8pzBH4km+5YA9HpmRaPglPifO0Ndj/UKw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=14c9a2dbfbb081c59d091001b7ddf75eef00da07 commit 14c9a2dbfbb081c59d091001b7ddf75eef00da07 Author: Mateusz Guzik AuthorDate: 2022-09-02 16:37:55 +0000 Commit: Mateusz Guzik CommitDate: 2022-09-07 10:04:31 +0000 net: retire PFIL_FWD It is now unused and not having it allows further clean ups. Reviewed by: cy, glebius, kp Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D36452 --- sys/net/pfil.h | 2 +- sys/netinet/ip_fastfwd.c | 2 +- sys/netinet/ip_output.c | 3 --- sys/netinet6/ip6_fastfwd.c | 4 ++-- sys/netinet6/ip6_forward.c | 4 ++-- 5 files changed, 6 insertions(+), 9 deletions(-) diff --git a/sys/net/pfil.h b/sys/net/pfil.h index da045b30c6ed..5caee0e715f9 100644 --- a/sys/net/pfil.h +++ b/sys/net/pfil.h @@ -80,7 +80,7 @@ struct pfilioc_link { #define PFIL_IN 0x00010000 #define PFIL_OUT 0x00020000 -#define PFIL_FWD 0x00040000 +/* UNUSED 0x00040000 */ #define PFIL_DIR(f) ((f) & (PFIL_IN|PFIL_OUT)) #define PFIL_MEMPTR 0x00080000 #define PFIL_HEADPTR 0x00100000 diff --git a/sys/netinet/ip_fastfwd.c b/sys/netinet/ip_fastfwd.c index 02a6be78d241..33cd08a0005b 100644 --- a/sys/netinet/ip_fastfwd.c +++ b/sys/netinet/ip_fastfwd.c @@ -403,7 +403,7 @@ passin: goto passout; if (pfil_run_hooks(V_inet_pfil_head, &m, nh->nh_ifp, - PFIL_OUT | PFIL_FWD, NULL) != PFIL_PASS) + PFIL_OUT, NULL) != PFIL_PASS) goto drop; M_ASSERTVALID(m); diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index a502f50ac4df..db39663e508e 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -117,9 +117,6 @@ ip_output_pfil(struct mbuf **mp, struct ifnet *ifp, int flags, struct ip *ip; int pflags = PFIL_OUT; - if (flags & IP_FORWARDING) - pflags |= PFIL_FWD; - m = *mp; ip = mtod(m, struct ip *); diff --git a/sys/netinet6/ip6_fastfwd.c b/sys/netinet6/ip6_fastfwd.c index b6a8af8013c4..34c04f4ec683 100644 --- a/sys/netinet6/ip6_fastfwd.c +++ b/sys/netinet6/ip6_fastfwd.c @@ -214,8 +214,8 @@ passin: /* * Outgoing packet firewall processing. */ - if (pfil_run_hooks(V_inet6_pfil_head, &m, nh->nh_ifp, PFIL_OUT | - PFIL_FWD, NULL) != PFIL_PASS) + if (pfil_run_hooks(V_inet6_pfil_head, &m, nh->nh_ifp, PFIL_OUT, + NULL) != PFIL_PASS) goto dropout; /* diff --git a/sys/netinet6/ip6_forward.c b/sys/netinet6/ip6_forward.c index d4306eea416f..03ecaf32b7b5 100644 --- a/sys/netinet6/ip6_forward.c +++ b/sys/netinet6/ip6_forward.c @@ -313,8 +313,8 @@ again: odst = ip6->ip6_dst; /* Run through list of hooks for forwarded packets. */ - if (pfil_run_hooks(V_inet6_pfil_head, &m, nh->nh_ifp, PFIL_OUT | - PFIL_FWD, NULL) != PFIL_PASS) + if (pfil_run_hooks(V_inet6_pfil_head, &m, nh->nh_ifp, PFIL_OUT, + NULL) != PFIL_PASS) goto freecopy; ip6 = mtod(m, struct ip6_hdr *);