netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Bluetooth BUG() in set_sk_owner().
@ 2003-09-10  8:58 David Woodhouse
  2003-09-12  1:22 ` David S. Miller
  0 siblings, 1 reply; 5+ messages in thread
From: David Woodhouse @ 2003-09-10  8:58 UTC (permalink / raw)
  To: netdev; +Cc: Stephen Hemminger, makx, marcel

It loks like the recent addition of sk_set_owner() to 
bt_sock_alloc() was bogus... some of the callers of bt_sock_alloc()
already do that for  This patch reverts it, and makes the remaining
callers also set the owner for themselves...

===== net/bluetooth/af_bluetooth.c 1.22 vs edited =====
--- 1.22/net/bluetooth/af_bluetooth.c	Sun Aug 31 03:30:42 2003
+++ edited/net/bluetooth/af_bluetooth.c	Tue Sep  9 11:28:51 2003
@@ -130,7 +130,6 @@
 	}
 
 	sock_init_data(sock, sk);
-	sk_set_owner(sk, THIS_MODULE);
 	INIT_LIST_HEAD(&bt_sk(sk)->accept_q);
 	
 	sk->sk_zapped   = 0;
===== net/bluetooth/hci_sock.c 1.24 vs edited =====
--- 1.24/net/bluetooth/hci_sock.c	Sat Jul  5 07:52:58 2003
+++ edited/net/bluetooth/hci_sock.c	Tue Sep  9 11:30:43 2003
@@ -587,6 +587,8 @@
 	if (!sk)
 		return -ENOMEM;
 
+	sk_set_owner(sk, THIS_MODULE);
+
 	sock->state = SS_UNCONNECTED;
 	sk->sk_state   = BT_OPEN;
 
===== net/bluetooth/bnep/sock.c 1.11 vs edited =====
--- 1.11/net/bluetooth/bnep/sock.c	Thu Jun  5 01:57:08 2003
+++ edited/net/bluetooth/bnep/sock.c	Tue Sep  9 11:29:54 2003
@@ -175,6 +175,9 @@
 
 	if (!(sk = bt_sock_alloc(sock, PF_BLUETOOTH, 0, GFP_KERNEL)))
 		return -ENOMEM;
+
+	sk_set_owner(sk, THIS_MODULE);
+
 	sock->ops = &bnep_sock_ops;
 
 	sock->state  = SS_UNCONNECTED;


-- 
dwmw2

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Bluetooth BUG() in set_sk_owner().
  2003-09-10  8:58 Bluetooth BUG() in set_sk_owner() David Woodhouse
@ 2003-09-12  1:22 ` David S. Miller
  2003-09-15  8:54   ` David Woodhouse
  0 siblings, 1 reply; 5+ messages in thread
From: David S. Miller @ 2003-09-12  1:22 UTC (permalink / raw)
  To: David Woodhouse; +Cc: netdev, shemminger, makx, marcel

On Wed, 10 Sep 2003 09:58:57 +0100
David Woodhouse <dwmw2@infradead.org> wrote:

> It loks like the recent addition of sk_set_owner() to 
> bt_sock_alloc() was bogus... some of the callers of bt_sock_alloc()
> already do that for  This patch reverts it, and makes the remaining
> callers also set the owner for themselves...

Applied, thanks David.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Bluetooth BUG() in set_sk_owner().
  2003-09-12  1:22 ` David S. Miller
@ 2003-09-15  8:54   ` David Woodhouse
  2003-09-15  9:57     ` Marcel Holtmann
  0 siblings, 1 reply; 5+ messages in thread
From: David Woodhouse @ 2003-09-15  8:54 UTC (permalink / raw)
  To: David S. Miller; +Cc: netdev, shemminger, maxk, marcel

On Thu, 2003-09-11 at 18:22 -0700, David S. Miller wrote:
> On Wed, 10 Sep 2003 09:58:57 +0100
> David Woodhouse <dwmw2@infradead.org> wrote:
> 
> > It loks like the recent addition of sk_set_owner() to 
> > bt_sock_alloc() was bogus... some of the callers of bt_sock_alloc()
> > already do that for  This patch reverts it, and makes the remaining
> > callers also set the owner for themselves...
> 
> Applied, thanks David.

Needs this too...

===== net/bluetooth/bnep/sock.c 1.11 vs edited =====
--- 1.11/net/bluetooth/bnep/sock.c	Thu Jun  5 01:57:08 2003
+++ edited/net/bluetooth/bnep/sock.c	Fri Sep 12 09:16:17 2003
@@ -186,7 +189,8 @@
 
 static struct net_proto_family bnep_sock_family_ops = {
 	.family = PF_BLUETOOTH,
-	.create = bnep_sock_create
+	.create = bnep_sock_create,
+	.owner = THIS_MODULE
 };
 
 int __init bnep_sock_init(void)


-- 
dwmw2

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Bluetooth BUG() in set_sk_owner().
  2003-09-15  8:54   ` David Woodhouse
@ 2003-09-15  9:57     ` Marcel Holtmann
  2003-09-15 23:02       ` David S. Miller
  0 siblings, 1 reply; 5+ messages in thread
From: Marcel Holtmann @ 2003-09-15  9:57 UTC (permalink / raw)
  To: David Woodhouse; +Cc: David S. Miller, netdev, shemminger, Max Krasnyansky

Hi David,

> Needs this too...
> 
> ===== net/bluetooth/bnep/sock.c 1.11 vs edited =====
> --- 1.11/net/bluetooth/bnep/sock.c	Thu Jun  5 01:57:08 2003
> +++ edited/net/bluetooth/bnep/sock.c	Fri Sep 12 09:16:17 2003
> @@ -186,7 +189,8 @@
>  
>  static struct net_proto_family bnep_sock_family_ops = {
>  	.family = PF_BLUETOOTH,
> -	.create = bnep_sock_create
> +	.create = bnep_sock_create,
> +	.owner = THIS_MODULE
>  };
>  
>  int __init bnep_sock_init(void)

it is only cosmetic, but put the .owner above the .create.

Regards

Marcel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Bluetooth BUG() in set_sk_owner().
  2003-09-15  9:57     ` Marcel Holtmann
@ 2003-09-15 23:02       ` David S. Miller
  0 siblings, 0 replies; 5+ messages in thread
From: David S. Miller @ 2003-09-15 23:02 UTC (permalink / raw)
  To: Marcel Holtmann; +Cc: dwmw2, netdev, shemminger, maxk

On 15 Sep 2003 11:57:01 +0200
Marcel Holtmann <marcel@holtmann.org> wrote:

> >  static struct net_proto_family bnep_sock_family_ops = {
> >  	.family = PF_BLUETOOTH,
> > -	.create = bnep_sock_create
> > +	.create = bnep_sock_create,
> > +	.owner = THIS_MODULE
> >  };
> 
> it is only cosmetic, but put the .owner above the .create.

I applied David's patch with Marcel's requested cosmetic change.

Thanks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-09-15 23:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-09-10  8:58 Bluetooth BUG() in set_sk_owner() David Woodhouse
2003-09-12  1:22 ` David S. Miller
2003-09-15  8:54   ` David Woodhouse
2003-09-15  9:57     ` Marcel Holtmann
2003-09-15 23:02       ` David S. Miller

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).