* [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC
@ 2003-08-18 18:17 Stephen Hemminger
2003-08-18 18:40 ` Jean Tourrilhes
2003-08-20 4:10 ` David S. Miller
0 siblings, 2 replies; 6+ messages in thread
From: Stephen Hemminger @ 2003-08-18 18:17 UTC (permalink / raw)
To: Jean Tourrilhes; +Cc: irda-users, netdev
Ircomm in 2.6.0-test3 can just set the owner field in the tty structure
like other drivers, and not mess with MOD_INC/MOD_DEC.
diff -Nru a/net/irda/ircomm/ircomm_tty.c b/net/irda/ircomm/ircomm_tty.c
--- a/net/irda/ircomm/ircomm_tty.c Mon Aug 18 11:07:15 2003
+++ b/net/irda/ircomm/ircomm_tty.c Mon Aug 18 11:07:15 2003
@@ -117,6 +117,7 @@
return -ENOMEM;
}
+ driver->owner = THIS_MODULE;
driver->driver_name = "ircomm";
driver->name = "ircomm";
driver->devfs_name = "ircomm";
@@ -363,10 +364,8 @@
IRDA_DEBUG(2, "%s()\n", __FUNCTION__ );
- MOD_INC_USE_COUNT;
line = tty->index;
if ((line < 0) || (line >= IRCOMM_TTY_PORTS)) {
- MOD_DEC_USE_COUNT;
return -ENODEV;
}
@@ -377,7 +376,6 @@
self = kmalloc(sizeof(struct ircomm_tty_cb), GFP_KERNEL);
if (self == NULL) {
ERROR("%s(), kmalloc failed!\n", __FUNCTION__);
- MOD_DEC_USE_COUNT;
return -ENOMEM;
}
memset(self, 0, sizeof(struct ircomm_tty_cb));
@@ -503,7 +501,6 @@
spin_lock_irqsave(&self->spinlock, flags);
if (tty_hung_up_p(filp)) {
- MOD_DEC_USE_COUNT;
spin_unlock_irqrestore(&self->spinlock, flags);
IRDA_DEBUG(0, "%s(), returning 1\n", __FUNCTION__ );
@@ -530,7 +527,6 @@
self->open_count = 0;
}
if (self->open_count) {
- MOD_DEC_USE_COUNT;
spin_unlock_irqrestore(&self->spinlock, flags);
IRDA_DEBUG(0, "%s(), open count > 0\n", __FUNCTION__ );
@@ -572,8 +568,6 @@
self->flags &= ~(ASYNC_NORMAL_ACTIVE|ASYNC_CLOSING);
wake_up_interruptible(&self->close_wait);
-
- MOD_DEC_USE_COUNT;
}
/*
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC
2003-08-18 18:17 [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC Stephen Hemminger
@ 2003-08-18 18:40 ` Jean Tourrilhes
2003-08-18 22:07 ` Jeff Garzik
2003-08-18 22:51 ` David S. Miller
2003-08-20 4:10 ` David S. Miller
1 sibling, 2 replies; 6+ messages in thread
From: Jean Tourrilhes @ 2003-08-18 18:40 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: irda-users, netdev
On Mon, Aug 18, 2003 at 11:17:46AM -0700, Stephen Hemminger wrote:
> Ircomm in 2.6.0-test3 can just set the owner field in the tty structure
> like other drivers, and not mess with MOD_INC/MOD_DEC.
You missed a couple of comments. I sent the more complete
version of the exact same patch a few weeks ago to Jeff Garzik, you
may want to check with Jeff what the status on this.
Of course, I would prefer the "more complete" version to go
in.
By the way, because of Jeff's turnaround, we are going to have
this problem a lot. All my pending IrDA patches are listed on my web
page, you may want to check it :
http://www.hpl.hp.com/personal/Jean_Tourrilhes/IrDA/IrDA.html
Thanks for the good work !
Jean
P.S. : Did you manage to set-up the crossover serial cable ?
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC
2003-08-18 18:40 ` Jean Tourrilhes
@ 2003-08-18 22:07 ` Jeff Garzik
2003-08-18 22:34 ` Jean Tourrilhes
2003-08-18 22:51 ` David S. Miller
1 sibling, 1 reply; 6+ messages in thread
From: Jeff Garzik @ 2003-08-18 22:07 UTC (permalink / raw)
To: jt; +Cc: Stephen Hemminger, irda-users, netdev
Jean Tourrilhes wrote:
> On Mon, Aug 18, 2003 at 11:17:46AM -0700, Stephen Hemminger wrote:
>
>>Ircomm in 2.6.0-test3 can just set the owner field in the tty structure
>>like other drivers, and not mess with MOD_INC/MOD_DEC.
>
>
> You missed a couple of comments. I sent the more complete
> version of the exact same patch a few weeks ago to Jeff Garzik, you
> may want to check with Jeff what the status on this.
> Of course, I would prefer the "more complete" version to go
> in.
>
> By the way, because of Jeff's turnaround, we are going to have
> this problem a lot. All my pending IrDA patches are listed on my web
> page, you may want to check it :
Yes, I have "ircomm module fix" and "NSC '39x fixes" queued, and going
to Linus today with some more net driver stuff.
Jeff
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC
2003-08-18 22:07 ` Jeff Garzik
@ 2003-08-18 22:34 ` Jean Tourrilhes
0 siblings, 0 replies; 6+ messages in thread
From: Jean Tourrilhes @ 2003-08-18 22:34 UTC (permalink / raw)
To: Jeff Garzik; +Cc: Stephen Hemminger, irda-users, netdev
On Mon, Aug 18, 2003 at 06:07:59PM -0400, Jeff Garzik wrote:
>
> Yes, I have "ircomm module fix" and "NSC '39x fixes" queued, and going
> to Linus today with some more net driver stuff.
>
> Jeff
By the way, I don't want you to take it the wrong way, I
prefer a reliable person than a quick one. It's just hard to
synchronise everything.
Have fun...
Jean
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC
2003-08-18 18:40 ` Jean Tourrilhes
2003-08-18 22:07 ` Jeff Garzik
@ 2003-08-18 22:51 ` David S. Miller
1 sibling, 0 replies; 6+ messages in thread
From: David S. Miller @ 2003-08-18 22:51 UTC (permalink / raw)
To: jt; +Cc: jt, shemminger, irda-users, netdev
On Mon, 18 Aug 2003 11:40:59 -0700
Jean Tourrilhes <jt@bougret.hpl.hp.com> wrote:
> By the way, because of Jeff's turnaround,
Jeff's turnaround time isn't so hot lately, just use me for all the
IRDA stuff until we can rely upon him again.
I live in my email box and can push things into Linus's tree
in 24 hours or less.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC
2003-08-18 18:17 [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC Stephen Hemminger
2003-08-18 18:40 ` Jean Tourrilhes
@ 2003-08-20 4:10 ` David S. Miller
1 sibling, 0 replies; 6+ messages in thread
From: David S. Miller @ 2003-08-20 4:10 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: jt, irda-users, netdev
On Mon, 18 Aug 2003 11:17:46 -0700
Stephen Hemminger <shemminger@osdl.org> wrote:
> Ircomm in 2.6.0-test3 can just set the owner field in the tty structure
> like other drivers, and not mess with MOD_INC/MOD_DEC.
Applied, thanks Stephen.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2003-08-20 4:10 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-08-18 18:17 [PATCH] ircomm - set owner get rid of MOD_INC/MOD_DEC Stephen Hemminger
2003-08-18 18:40 ` Jean Tourrilhes
2003-08-18 22:07 ` Jeff Garzik
2003-08-18 22:34 ` Jean Tourrilhes
2003-08-18 22:51 ` David S. Miller
2003-08-20 4:10 ` 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).