All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeremy Kerr <jk@ozlabs.org>
To: linuxppc-dev@ozlabs.org
Subject: Re: [PATCH] powerpc: simplify dma_ops bug conditions
Date: Mon, 17 Jul 2006 13:55:41 +1000	[thread overview]
Message-ID: <200607171355.42465.jk@ozlabs.org> (raw)
In-Reply-To: <20060713063947.GD5096@rhun.ibm.com>

Muli,

> Is the BUG_ON() necessary? the next line just goes and deref's it,
> which should lead to a shiny NULL pointer deref.

No, it's not really necessary, more a style thing. The BUG_ON only adds 
an extra 3 instructions (subfic, addi and tdnei), which should be tiny 
compared to the indirect branch.

Also, it makes it a little easier for a user to understand: "there's a 
bug in the kernel" vs. "invalid memory access".


Jeremy

  reply	other threads:[~2006-07-17  3:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-13  6:32 [PATCH] powerpc: simplify dma_ops bug conditions Jeremy Kerr
2006-07-13  6:39 ` Muli Ben-Yehuda
2006-07-17  3:55   ` Jeremy Kerr [this message]
     [not found]   ` <200607171355.10077.jk@ozlabs.org>
     [not found]     ` <20060717062825.GA18291@rhun.ibm.com>
2006-07-17  6:31       ` Muli Ben-Yehuda

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=200607171355.42465.jk@ozlabs.org \
    --to=jk@ozlabs.org \
    --cc=linuxppc-dev@ozlabs.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.