All of lore.kernel.org
 help / color / mirror / Atom feed
From: Till Immanuel Patzschke <tip@internetwork-ag.de>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: laughing@shared-source.org
Subject: [PATCH] 2.4.10-pre13: ATM drivers cause panic
Date: Sat, 22 Sep 2001 15:36:20 +0200	[thread overview]
Message-ID: <3BAC93D4.65E17AA6@internetwork-ag.de> (raw)
In-Reply-To: <E15kU3r-0000bv-00@the-village.bc.nu>

Hi,

seems a couple of spin_lock(s) and a spin_unlock was missing.
Why didn't this problem show up with earlier releases ???
Anyways, please find a (quick) patch below. It would be great if this patch or
any other similar could make it into the next release!
Thanks,

Immanuel


diff -Naur net/atm/resources.c.bug net/atm/resources.c
--- net/atm/resources.c.bug     Fri Dec 29 23:35:47 2000
+++ net/atm/resources.c Sat Sep 22 15:31:35 2001
@@ -76,14 +76,17 @@
 {
        struct atm_dev *dev;
 
+       spin_lock (&atm_dev_lock);
        dev = alloc_atm_dev(type);
        if (!dev) {
                printk(KERN_ERR "atm_dev_register: no space for dev %s\n",
                    type);
+               spin_unlock (&atm_dev_lock);
                return NULL;
        }
        if (number != -1) {
                if (atm_find_dev(number)) {
+                       spin_unlock (&atm_dev_lock);
                        free_atm_dev(dev);
                        return NULL;
                }


--
Till Immanuel Patzschke                 mailto: tip@internetwork-ag.de
interNetwork AG                         Phone:  +49-(0)611-1731-121
Bierstadter Str. 7                      Fax:    +49-(0)611-1731-31
D-65189 Wiesbaden                       Web:    http://www.internetwork-ag.de

  parent reply	other threads:[~2001-09-22 13:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-09-21 17:19 [BUG] 2.4.10-pre13: ATM drivers cause panic Till Immanuel Patzschke
2001-09-21 17:25 ` Alan Cox
2001-09-21 17:51   ` Till Immanuel Patzschke
2001-09-22 13:36   ` Till Immanuel Patzschke [this message]
2001-09-22 16:01     ` [PATCH] " Alan Cox
2001-09-23  9:33       ` Mitchell Blank Jr
2001-09-22 16:04     ` Alan Cox
2001-09-24  9:47       ` Till Immanuel Patzschke
2001-09-24 12:16         ` Mr. James W. Laferriere

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=3BAC93D4.65E17AA6@internetwork-ag.de \
    --to=tip@internetwork-ag.de \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=laughing@shared-source.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tip@prs.de \
    /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.