public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andi Kleen <ak@suse.de>
To: discuss@x86-64.org
Cc: Jeff Garzik <jeff@garzik.org>, Muli Ben-Yehuda <mulix@mulix.org>,
	Jon Mason <jdmason@us.ibm.com>, Muli Ben-Yehuda <muli@il.ibm.com>,
	Linux-Kernel <linux-kernel@vger.kernel.org>,
	Andrew Morton <akpm@osdl.org>
Subject: Re: [discuss] Re: [PATCH 2/4] x86-64: Calgary IOMMU - move valid_dma_direction into the callers
Date: Fri, 26 May 2006 09:57:01 +0200	[thread overview]
Message-ID: <200605260957.02163.ak@suse.de> (raw)
In-Reply-To: <44757FD3.3070805@garzik.org>

On Thursday 25 May 2006 11:58, Jeff Garzik wrote:
> Muli Ben-Yehuda wrote:
> > On Thu, May 25, 2006 at 12:35:07AM -0400, Jeff Garzik wrote:
> >> Jon Mason wrote:
> >>> >From Andi Kleen's comments on the original Calgary patch, move
> >>> valid_dma_direction into the calling functions.
> >>>
> >>> Signed-off-by: Muli Ben-Yehuda <muli@il.ibm.com>
> >>> Signed-off-by: Jon Mason <jdmason@us.ibm.com>
> >> Even though BUG_ON() includes unlikely(), this introduces additional 
> >> tests in very hot paths.
> > 
> > Are they really very hot? I mean if you're calling the DMA API, you're
> > about to frob the hardware or have already frobbed it - does this
> > check really matter?
> 
> When you are adding a check that will _never_ be hit in production, to 
> the _hottest_ paths in the kernel, you can be assured it matters...

pci_dma_* shouldn't be that hot. Or at least IO usually has so much
overhead that some more bugging shouldn't matter.

On the other hand if the problem of passing wrong parameters here
isn't common I would be ok with dropping them.

-Andi

  reply	other threads:[~2006-05-26  7:58 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-25  3:35 [PATCH 2/4] x86-64: Calgary IOMMU - move valid_dma_direction into the callers Jon Mason
2006-05-25  4:35 ` Jeff Garzik
2006-05-25  9:42   ` Muli Ben-Yehuda
2006-05-25  9:58     ` Jeff Garzik
2006-05-26  7:57       ` Andi Kleen [this message]
2006-05-26  8:55         ` [discuss] " Jeff Garzik
2006-05-26  9:35           ` Andi Kleen

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=200605260957.02163.ak@suse.de \
    --to=ak@suse.de \
    --cc=akpm@osdl.org \
    --cc=discuss@x86-64.org \
    --cc=jdmason@us.ibm.com \
    --cc=jeff@garzik.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=muli@il.ibm.com \
    --cc=mulix@mulix.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