diff mbox series

net/handshake: Fix section mismatch in handshake_exit

Message ID 20230420173723.3773434-1-geert@linux-m68k.org (mailing list archive)
State Accepted
Commit 6aa445e39693bff9c98b12f960e66b4e18c7378b
Delegated to: Netdev Maintainers
Headers show
Series net/handshake: Fix section mismatch in handshake_exit | expand

Checks

Context Check Description
netdev/series_format warning Single patches do not need cover letters; Target tree name not specified in the subject
netdev/tree_selection success Guessed tree name to be net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 10 this patch: 10
netdev/cc_maintainers success CCed 7 of 7 maintainers
netdev/build_clang success Errors and warnings before: 8 this patch: 8
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success Fixes tag looks correct
netdev/build_allmodconfig_warn success Errors and warnings before: 10 this patch: 10
netdev/checkpatch warning WARNING: Please use correct Fixes: style 'Fixes: <12 chars of sha1> ("<title line>")' - ie: 'Fixes: 3b3009ea8abb ("net/handshake: Create a NETLINK service for handling handshake requests")' WARNING: Unknown link reference 'Closes:', use 'Link:' instead
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Geert Uytterhoeven April 20, 2023, 5:37 p.m. UTC
If CONFIG_NET_NS=n (e.g. m68k/defconfig):

    WARNING: modpost: vmlinux.o: section mismatch in reference: handshake_exit (section: .exit.text) -> handshake_genl_net_ops (section: .init.data)
    ERROR: modpost: Section mismatches detected.

Fix this by dropping the __net_initdata tag from handshake_genl_net_ops.

Fixes: 3b3009ea8abb713b ("net/handshake: Create a NETLINK service for handling handshake requests")
Reported-by: noreply@ellerman.id.au
Closes: http://kisskb.ellerman.id.au/kisskb/buildresult/14912987
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
 net/handshake/netlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Chuck Lever April 21, 2023, 12:36 a.m. UTC | #1
On Thu, Apr 20, 2023 at 07:37:23PM +0200, Geert Uytterhoeven wrote:
> If CONFIG_NET_NS=n (e.g. m68k/defconfig):
> 
>     WARNING: modpost: vmlinux.o: section mismatch in reference: handshake_exit (section: .exit.text) -> handshake_genl_net_ops (section: .init.data)
>     ERROR: modpost: Section mismatches detected.
> 
> Fix this by dropping the __net_initdata tag from handshake_genl_net_ops.
> 
> Fixes: 3b3009ea8abb713b ("net/handshake: Create a NETLINK service for handling handshake requests")
> Reported-by: noreply@ellerman.id.au
> Closes: http://kisskb.ellerman.id.au/kisskb/buildresult/14912987
> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>

Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

> ---
>  net/handshake/netlink.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/net/handshake/netlink.c b/net/handshake/netlink.c
> index 8ea0ff993f9fba50..35c9c445e0b850d8 100644
> --- a/net/handshake/netlink.c
> +++ b/net/handshake/netlink.c
> @@ -249,7 +249,7 @@ static void __net_exit handshake_net_exit(struct net *net)
>  	}
>  }
>  
> -static struct pernet_operations __net_initdata handshake_genl_net_ops = {
> +static struct pernet_operations handshake_genl_net_ops = {
>  	.init		= handshake_net_init,
>  	.exit		= handshake_net_exit,
>  	.id		= &handshake_net_id,
> -- 
> 2.34.1
>
patchwork-bot+netdevbpf@kernel.org April 22, 2023, 3:30 a.m. UTC | #2
Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Thu, 20 Apr 2023 19:37:23 +0200 you wrote:
> If CONFIG_NET_NS=n (e.g. m68k/defconfig):
> 
>     WARNING: modpost: vmlinux.o: section mismatch in reference: handshake_exit (section: .exit.text) -> handshake_genl_net_ops (section: .init.data)
>     ERROR: modpost: Section mismatches detected.
> 
> Fix this by dropping the __net_initdata tag from handshake_genl_net_ops.
> 
> [...]

Here is the summary with links:
  - net/handshake: Fix section mismatch in handshake_exit
    https://git.kernel.org/netdev/net-next/c/6aa445e39693

You are awesome, thank you!
diff mbox series

Patch

diff --git a/net/handshake/netlink.c b/net/handshake/netlink.c
index 8ea0ff993f9fba50..35c9c445e0b850d8 100644
--- a/net/handshake/netlink.c
+++ b/net/handshake/netlink.c
@@ -249,7 +249,7 @@  static void __net_exit handshake_net_exit(struct net *net)
 	}
 }
 
-static struct pernet_operations __net_initdata handshake_genl_net_ops = {
+static struct pernet_operations handshake_genl_net_ops = {
 	.init		= handshake_net_init,
 	.exit		= handshake_net_exit,
 	.id		= &handshake_net_id,