All of lore.kernel.org
 help / color / mirror / Atom feed
From: Francois romieu <romieu@ensta.fr>
To: Dan Aloni <karrde@callisto.yi.org>
Cc: linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH (2.4)] atomic use count for proc_dir_entry
Date: Fri, 17 Nov 2000 11:23:33 +0000	[thread overview]
Message-ID: <20001117112333.D839@nic.fr> (raw)
In-Reply-To: <Pine.LNX.4.21.0011162320230.17038-100000@callisto.yi.org> <Pine.LNX.4.21.0011171015270.19287-100000@callisto.yi.org>
In-Reply-To: <Pine.LNX.4.21.0011171015270.19287-100000@callisto.yi.org>; from karrde@callisto.yi.org on Fri, Nov 17, 2000 at 10:37:39AM +0200

CPU A: assume de->count = 1 (in de_put)
fs/proc/inode.c::44 if (!--de->count) {
de->count = 0

CPU B: (in remove_proc_entry)
fs/proc/generic.c::577         if (!de->count)
fs/proc/generic.c::578             free_proc_entry(de);

CPU A: (in de_put)
fs/proc/inode.c::45 if (de->deleted) { <-- dereferencing kfreed pointer

What does protect us from the preceding if lock_kernel is thrown ?

-- 
Ueimor
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

  reply	other threads:[~2000-11-17 10:54 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-11-16 21:00 [PATCH (2.4)] atomic use count for proc_dir_entry Dan Aloni
2000-11-16 21:14 ` Linus Torvalds
2000-11-16 21:31   ` Dan Aloni
2000-11-17  8:37     ` Dan Aloni
2000-11-17 11:23       ` Francois romieu [this message]
2000-11-17 11:40         ` Dan Aloni
  -- strict thread matches above, loose matches on Subject: below --
2000-11-17  5:21 Jacob Luna Lundberg
2000-11-17  7:26 ` Dan Aloni
2000-11-17  8:35   ` Jacob Luna Lundberg
2000-11-17  9:51     ` Dan Aloni
2000-11-17 11:24     ` Ingo Oeser

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=20001117112333.D839@nic.fr \
    --to=romieu@ensta.fr \
    --cc=karrde@callisto.yi.org \
    --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 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.