Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: Dajie Tan <jiankemeng@gmail.com>
Cc: John Levon <levon@movementarian.org>,
	linux-mips <linux-mips@linux-mips.org>,
	phil.el@wanadoo.fr, oprofile-list@lists.sourceforge.net
Subject: Re: [PATCH] Add support for profiling Loongson 2E
Date: Thu, 26 Jul 2007 12:17:03 +0100	[thread overview]
Message-ID: <20070726111703.GA30004@linux-mips.org> (raw)
In-Reply-To: <5861a7880707251814q4b6876a1u4291d068e201488c@mail.gmail.com>

On Thu, Jul 26, 2007 at 05:14:14AM +0400, Dajie Tan wrote:

> >> Yeah,this change is to enhance the robust of oprofile. When using
> >> performace counter manually(writting control register in a module, no
> >> need to use the oprofile),I usually make kernel panic if I do not
> >> initialize the oprofile and enable the overflow interrupt carelessly.
> >> So, this change can avoid this panic. :D
> >
> >This panic is good and should stay. It shows that you've made a mistake.
> >
> >john
> >
> 
> This panic is caused by accessing a null pointer.Do you think that
> accessing a null
> pointer is allowed in a robust system ?

Of course it isn't.  From the perspective of us kernel maintainers patches
that add such checks are a red flag which raise concerns about the
correctness of the caller of the function.  So if a patch like this is
submitted the first thing that is likely to happen is that we will ask
why the check is needed.  It does not mean such a patch is fundamentally
a no-no but the code will be looked at a little harder.

  Ralf

      parent reply	other threads:[~2007-07-26 11:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-24  9:20 [PATCH] Add support for profiling Loongson 2E Dajie Tan
2007-07-24 14:40 ` Ralf Baechle
2007-07-25  3:41   ` Dajie Tan
2007-07-25 12:52     ` John Levon
2007-07-26  1:14       ` Dajie Tan
2007-07-26  4:48         ` Fuxin Zhang
2007-07-26 11:17         ` Ralf Baechle [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=20070726111703.GA30004@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=jiankemeng@gmail.com \
    --cc=levon@movementarian.org \
    --cc=linux-mips@linux-mips.org \
    --cc=oprofile-list@lists.sourceforge.net \
    --cc=phil.el@wanadoo.fr \
    /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