mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jan Kasprzak <kas@fi.muni.cz>
To: torvalds@osdl.org
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH, repost] cosa.c intialization crash
Date: Thu, 6 Jan 2005 10:59:20 +0100	[thread overview]
Message-ID: <20050106095920.GE6961@fi.muni.cz> (raw)
In-Reply-To: <20041202124022.GE11992@fi.muni.cz>

	Linus, please apply the attached patch (I am reposting this again).
Without this, the cosa driver crashes immediately during insmod.

Original mail:

	The attached patch fixes crash on insmod of the cosa.ko module
- the sppp_attach() was called too early when dev->priv has not been
set up yet. Linus, please apply.

Signed-off-by: Jan "Yenya" Kasprzak <kas@fi.muni.cz>

--- linux-2.6.10-rc2/drivers/net/wan/cosa.c.orig	2004-12-02 13:33:00.650293092 +0100
+++ linux-2.6.10-rc2/drivers/net/wan/cosa.c	2004-11-15 02:26:39.000000000 +0100
@@ -642,11 +642,11 @@
 		return;
 	}
 	chan->pppdev.dev = d;
-	sppp_attach(&chan->pppdev);
 	d->base_addr = chan->cosa->datareg;
 	d->irq = chan->cosa->irq;
 	d->dma = chan->cosa->dma;
 	d->priv = chan;
+	sppp_attach(&chan->pppdev);
 	if (register_netdev(d)) {
 		printk(KERN_WARNING "%s: register_netdev failed.\n", d->name);
 		sppp_detach(d);
-- 
| Jan "Yenya" Kasprzak  <kas at {fi.muni.cz - work | yenya.net - private}> |
| GPG: ID 1024/D3498839      Fingerprint 0D99A7FB206605D7 8B35FCDE05B18A5E |
| http://www.fi.muni.cz/~kas/   Czech Linux Homepage: http://www.linux.cz/ |
> Whatever the Java applications and desktop dances may lead to, Unix will <
> still be pushing the packets around for a quite a while.      --Rob Pike <

      reply	other threads:[~2005-01-06  9:59 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-02 12:40 [PATCH] " Jan Kasprzak
2005-01-06  9:59 ` Jan Kasprzak [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=20050106095920.GE6961@fi.muni.cz \
    --to=kas@fi.muni.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.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

all inboxes | Powered by JetHome®