All of lore.kernel.org
 help / color / mirror / Atom feed
From: "David S. Miller" <davem@redhat.com>
To: rusty@rustcorp.com.au
Cc: linux-kernel@vger.kernel.org, acme@conectiva.com.br
Subject: Re: [2.5.69-mm1] kernel BUG at include/linux/module.h:284!
Date: Tue, 06 May 2003 22:52:23 -0700 (PDT)	[thread overview]
Message-ID: <20030506.225223.116372228.davem@redhat.com> (raw)
In-Reply-To: <20030507035148.31D332C117@lists.samba.org>

   From: Rusty Russell <rusty@rustcorp.com.au>
   Date: Wed, 07 May 2003 13:48:15 +1000

   In message <1052227331.983.46.camel@rth.ninka.net> you write:
   > Arnaldo, ipv6 creates a socket of it's own type during
   > module init, try_module_get() on the current module fails
   > during module load... do you see the problem?
   > 
   > Rusty, you said you were working on a solution for modules
   > that call themselves during their own init?
   
   In fact, it's backwards.

You're, of course, right.  I misread the bug report, and this
patch below ought to fix it.  It's untested, but I'll do that in
a bit and push upstream.

# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
#	           ChangeSet	1.1083  -> 1.1084 
#	  net/ipv4/af_inet.c	1.44    -> 1.45   
#	 net/ipv6/af_inet6.c	1.33    -> 1.34   
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 03/05/06	davem@nuts.ninka.net	1.1084
# [IPV4/IPV6]: Set owner field in family ops.
# --------------------------------------------
#
diff -Nru a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c
--- a/net/ipv4/af_inet.c	Tue May  6 23:58:43 2003
+++ b/net/ipv4/af_inet.c	Tue May  6 23:58:43 2003
@@ -926,6 +926,7 @@
 struct net_proto_family inet_family_ops = {
 	.family = PF_INET,
 	.create = inet_create,
+	.owner	= THIS_MODULE,
 };
 
 
diff -Nru a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c
--- a/net/ipv6/af_inet6.c	Tue May  6 23:58:43 2003
+++ b/net/ipv6/af_inet6.c	Tue May  6 23:58:43 2003
@@ -535,6 +535,7 @@
 struct net_proto_family inet6_family_ops = {
 	.family = PF_INET6,
 	.create = inet6_create,
+	.owner	= THIS_MODULE,
 };
 
 #ifdef MODULE

      reply	other threads:[~2003-05-07  6:47 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-06 12:44 [2.5.69-mm1] kernel BUG at include/linux/module.h:284! Kimmo Sundqvist
2003-05-06 13:22 ` David S. Miller
2003-05-07  3:48   ` Rusty Russell
2003-05-07  5:52     ` David S. Miller [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030506.225223.116372228.davem@redhat.com \
    --to=davem@redhat.com \
    --cc=acme@conectiva.com.br \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rusty@rustcorp.com.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.