From nobody Sun Feb 8 07:25:15 2026 Received: from mail-yw1-f174.google.com (mail-yw1-f174.google.com [209.85.128.174]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2C76240F8ED for ; Wed, 4 Feb 2026 15:38:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.174 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770219518; cv=none; b=U1zrNpuv/ug4u49EDYzJpXSrozENBn9wYXGIR0ikwcenXOQx702bMWB0Iym/9CAlQ9dmD1Iz9pvN/FOsrbc82ZTkUJ4wbotRnIDJnr/K90bvpJtYVQKEhWgX83q/vCnGTmNwbTEqve2BocQlneV0Thg04YJfgO9sFbsgbP7XJNI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770219518; c=relaxed/simple; bh=MxODx3pS4AdMwobsyC+HGet1jyKV2KIg3yAsOJarsoo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=aWrXpZPPkbGNBzdwwli7wg/WQa0qoxPxmHKR5fWRavFt0iwpPmCNg3+J8e66Xk8ZQK6yHB81aspDawYnmtt+Rj67M+Clox9dCBR4vZZ9Pm63px1CQ9URC3WnRF7SEmRuOZ1NCZaq8RxZ1QEOaR5ZMGpNlAhdwzhA72cU1z6JjOI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=J5gYtpMT; arc=none smtp.client-ip=209.85.128.174 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="J5gYtpMT" Received: by mail-yw1-f174.google.com with SMTP id 00721157ae682-790884840baso66211777b3.0 for ; Wed, 04 Feb 2026 07:38:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1770219517; x=1770824317; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=IQXv16HV512qbYg7bqvE7dda3nhbD1riX7k58Uh8FtI=; b=J5gYtpMTq/mSafxZ551ErP9w41VsyklmB0KP6zZCBay29es79skMvuBCYNEjJyC0eE ybog4Dov6zlqkbv1t4cqMRIIjaf04/qyuA0Af8QQqNw9Mu1JJj7TjC6CSBShcoLU6cS9 j3G/oW7GSWssSWVIaAMPLy2Si2oC2XXqJmHqE2aHwOpsracMPtKNzTaqigFNMj9/NTd1 6EM6BeatX8tECkUzKnrdlUVPko/fsTM23KTy3a8dchL6hk71wvBudCqEmrjLnI9Gf3pd esJWRJjYmQEonHe8DRPZOb6TCjF+eNlrowEMXgFvCq0hyQaUqJFMvb1iLbFpg6z0SxJ/ e0Jw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1770219517; x=1770824317; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=IQXv16HV512qbYg7bqvE7dda3nhbD1riX7k58Uh8FtI=; b=vRwZt2sO3MAaUYoq/uvLundtQK/+WSlaaGRoND0jwJBH98pHcSXm+x3W9ybOQ9pfza sscnhRQm7elLqdwVeZnfNkxBayO2vS42ImlONL6sG3k+ZRxUDpDk1UQIXiyv6fPsbMUY V5hpqi8M5n2lS+0NKiQ8cPSqCnyLX2F7PcdyO3nkYAWAu//HNR3n1Th0nqs1l4EOZpst AxgYs1Xtg/FbgBFw+BkE4yh5KbktyiaZfYwvjheNXzOPcWU95jegMDFkaaACuNEJd15s pbGmWiLsdAKsp1uQEGEGiLOn4t7WWx2devhhVIoKd9nm6g47X780mG11a1XoIGNCCAsq 7yWg== X-Forwarded-Encrypted: i=1; AJvYcCWRPJPHotQ9twxd63J8RJiQtY6pvGB3oU/UZb/rSHtnWdMNarWgbLqS9GtxVYh/kigOdP1B2j5lL+ODRlc=@vger.kernel.org X-Gm-Message-State: AOJu0Yx0daHy8NjvIq82eMGgbyUVia9LpvgPgI4ifJqXaDPYkBomOYdA wJ+tzHyEKH5kdIJCaxv3jHKi2syLGzhIh6WKJZ5mQaY9MVegqg6UIfRI2ggUCYknRko= X-Gm-Gg: AZuq6aKtAcb31FZL3L9zbgLoxEJQspRcUtUeG/ifMDYifHEgRN5qXgPmtzF4SR4PuWn QTFWUzaotj6w/2mszMXOn8+vrCR/qqAIKainJjz6StKwn6tBqOhgrDcSabasurJNuaPpArpbf4C 8Go4zFUre1lrb+L9V4gNUFpmK4xV8pBiaJFl7fNURz4ybRHVbtieCLi2NpU7Zyyx1WxJzsVxAaZ LCcUpCs3KJ022BcLeYMK6tae3majD9Yc/lM6qS2iSycCopcT6hte0acj/fLGnGh10gvFeCDgRon /dnCSZ2UnDDTAvgk+kAvbZy4Fbf9kBHORYPQPVCd2pDPIFnN9eKEn7BM7eoNDXcBfKs3m2vFigI 2+owkHlai3IA2J5jvFbUPg5/x5tMXLNscCEEpoM+Cxfud+tUVtbY52SUiREEFla28FmX0FkuGrG yl3gXDNLXwWUwtnkIQ8B8PnjWV9j25xldYA1p07HGhz3GkWUvcxoG1ZvcVMi6xv3YMEv6tlxLr8 eQc3cuylQ== X-Received: by 2002:a05:690c:dc7:b0:794:3392:5d64 with SMTP id 00721157ae682-794fe74783bmr34112767b3.44.1770219517080; Wed, 04 Feb 2026 07:38:37 -0800 (PST) Received: from localhost.localdomain (108-214-96-168.lightspeed.sntcca.sbcglobal.net. [108.214.96.168]) by smtp.gmail.com with ESMTPSA id 00721157ae682-794fefedd4bsm23609397b3.48.2026.02.04.07.38.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Feb 2026 07:38:36 -0800 (PST) From: Sun Jian To: Florian Westphal Cc: Pablo Neira Ayuso , netfilter-devel@vger.kernel.org, linux-kernel@vger.kernel.org, Sun Jian Subject: [PATCH v4 1/5] netfilter: amanda: annotate nf_nat_amanda_hook with __rcu Date: Wed, 4 Feb 2026 23:38:08 +0800 Message-ID: <20260204153812.739799-2-sun.jian.kdev@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260204153812.739799-1-sun.jian.kdev@gmail.com> References: <20260204153812.739799-1-sun.jian.kdev@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The nf_nat_amanda_hook is an RCU-protected pointer but lacks the proper __rcu annotation. Add the annotation to ensure the declaration correctly reflects its usage via rcu_dereference(). Suggested-by: Florian Westphal Signed-off-by: Sun Jian --- include/linux/netfilter/nf_conntrack_amanda.h | 12 ++++++------ net/netfilter/nf_conntrack_amanda.c | 14 +++++++------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/include/linux/netfilter/nf_conntrack_amanda.h b/include/linux/= netfilter/nf_conntrack_amanda.h index 6f0ac896fcc9..9f957598a9da 100644 --- a/include/linux/netfilter/nf_conntrack_amanda.h +++ b/include/linux/netfilter/nf_conntrack_amanda.h @@ -7,10 +7,10 @@ #include #include =20 -extern unsigned int (*nf_nat_amanda_hook)(struct sk_buff *skb, - enum ip_conntrack_info ctinfo, - unsigned int protoff, - unsigned int matchoff, - unsigned int matchlen, - struct nf_conntrack_expect *exp); +extern unsigned int (__rcu *nf_nat_amanda_hook)(struct sk_buff *skb, + enum ip_conntrack_info ctinfo, + unsigned int protoff, + unsigned int matchoff, + unsigned int matchlen, + struct nf_conntrack_expect *exp); #endif /* _NF_CONNTRACK_AMANDA_H */ diff --git a/net/netfilter/nf_conntrack_amanda.c b/net/netfilter/nf_conntra= ck_amanda.c index 7be4c35e4795..c0132559f6af 100644 --- a/net/netfilter/nf_conntrack_amanda.c +++ b/net/netfilter/nf_conntrack_amanda.c @@ -37,13 +37,13 @@ MODULE_PARM_DESC(master_timeout, "timeout for the maste= r connection"); module_param(ts_algo, charp, 0400); MODULE_PARM_DESC(ts_algo, "textsearch algorithm to use (default kmp)"); =20 -unsigned int (*nf_nat_amanda_hook)(struct sk_buff *skb, - enum ip_conntrack_info ctinfo, - unsigned int protoff, - unsigned int matchoff, - unsigned int matchlen, - struct nf_conntrack_expect *exp) - __read_mostly; +unsigned int (__rcu *nf_nat_amanda_hook)(struct sk_buff *skb, + enum ip_conntrack_info ctinfo, + unsigned int protoff, + unsigned int matchoff, + unsigned int matchlen, + struct nf_conntrack_expect *exp) + __read_mostly; EXPORT_SYMBOL_GPL(nf_nat_amanda_hook); =20 enum amanda_strings { --=20 2.43.0