linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: ilmari@ilmari.org (Dagfinn Ilmari Mannsåker)
To: linux-kernel@vger.kernel.org
Cc: bluez-devel@lists.sourceforge.net
Subject: Re: rfcomm oops in 2.5.74
Date: Fri, 04 Jul 2003 06:04:58 +0200	[thread overview]
Message-ID: <d8jfzlnym1h.fsf@wirth.ping.uio.no> (raw)
In-Reply-To: d8jznjvzr07.fsf@wirth.ping.uio.no

ilmari@ilmari.org (Dagfinn Ilmari Mannsåker) writes:

> Calling socket(PF_BLUETOOTH, SOCK_RAW, BTPROTO_RFCOMM) on 2.5.74
> segfaults and gives the below oops. module.h:297 is
> BUG_ON(module_refcount(module) == 0) in __module_get(), which is called
> from rfcomm_sock_alloc() via sk_set_owner().

It turns out that net/bluetooth/rfcomm/sock.c (and
net/bluetooth/hci_sock.c) had been left out when net_proto_family gained
an owner field, here's a patch that fixes them both. Now I can transfer
pictures from my phone over OBEX Object Push again :)

--- net/bluetooth/rfcomm/sock.c~	2003-07-02 22:50:14.000000000 +0200
+++ net/bluetooth/rfcomm/sock.c	2003-07-04 05:24:15.000000000 +0200
@@ -878,6 +878,7 @@
 
 static struct net_proto_family rfcomm_sock_family_ops = {
 	.family		= PF_BLUETOOTH,
+	.owner		= THIS_MODULE,
 	.create		= rfcomm_sock_create
 };
 
--- net/bluetooth/hci_sock.c~	2003-07-02 22:49:11.000000000 +0200
+++ net/bluetooth/hci_sock.c	2003-07-04 05:24:54.000000000 +0200
@@ -632,6 +632,7 @@
 
 struct net_proto_family hci_sock_family_ops = {
 	.family = PF_BLUETOOTH,
+	.owner	= THIS_MODULE,
 	.create = hci_sock_create,
 };
 

-- 
ilmari


  parent reply	other threads:[~2003-07-04  3:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-03 13:20 rfcomm oops in 2.5.74 Dagfinn Ilmari Mannsåker
2003-07-03 15:02 ` [Bluez-devel] " Aurelien Minet
2003-07-03 15:54   ` Dagfinn Ilmari Mannsåker
2003-07-04  7:39     ` Aurelien Minet
2003-07-04  4:04 ` Dagfinn Ilmari Mannsåker [this message]
2003-07-07 17:56   ` [Bluez-devel] " Max Krasnyansky

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=d8jfzlnym1h.fsf@wirth.ping.uio.no \
    --to=ilmari@ilmari.org \
    --cc=bluez-devel@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).