public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Prasanna S Panchamukhi <prasanna@in.ibm.com>
To: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Don't oops when unregistering unknown kprobes
Date: Tue, 26 Apr 2005 21:57:51 +0530	[thread overview]
Message-ID: <20050426162751.GD32766@in.ibm.com> (raw)
In-Reply-To: <20050426162203.GE27406@gilgamesh.home.res>

> @@ -107,6 +107,13 @@ rm_kprobe:
>  void unregister_kprobe(struct kprobe *p)
>  {
>  	unsigned long flags;
> +
> +	if (!get_kprobe(p)) {
> +		printk(KERN_WARNING "Warning: Attempt to unregister "
> +					"unknown kprobe (addr:0x%lx)\n",
> +					(unsigned long) p);
> +		return;
> +	}

This is wrong. You should call get_kprobe() with spin_lock().
 

-Prasanna

-- 

Prasanna S Panchamukhi
Linux Technology Center
India Software Labs, IBM Bangalore
Ph: 91-80-25044636
<prasanna@in.ibm.com>

  reply	other threads:[~2005-04-26 16:35 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-04-26 16:22 [PATCH] Don't oops when unregistering unknown kprobes Frederik Deweerdt
2005-04-26 16:27 ` Prasanna S Panchamukhi [this message]
2005-04-26 21:42   ` Frederik Deweerdt
2005-04-26 22:09     ` Jesper Juhl
2005-04-26 22:31       ` Frederik Deweerdt
2005-04-26 19:48 ` Chris Wedgwood
2005-04-27  5:08   ` Prasanna S Panchamukhi

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=20050426162751.GD32766@in.ibm.com \
    --to=prasanna@in.ibm.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox