All of lore.kernel.org
 help / color / mirror / Atom feed
From: Grant Grundler <iod00d@hp.com>
To: linux-ia64@vger.kernel.org
Subject: Re: SCSI ERRORS triggered by BIO_VMERGE_BOUNDARY
Date: Mon, 23 Jun 2003 20:24:03 +0000	[thread overview]
Message-ID: <marc-linux-ia64-105640005723820@msgid-missing> (raw)
In-Reply-To: <marc-linux-ia64-105604433402604@msgid-missing>

On Mon, Jun 23, 2003 at 09:52:06AM -0700, David Mosberger wrote:
> No, BIO_VMERGE_BOUNDARY must be 0xffffffffffffffff if there is no
> hardware I/O MMU present (i.e., the I/O MMU page size is 2^64) and
> PAGE_SIZE if an I/O MMU is present (which can support PAGE_SIZE
> pages).

yes - that's what I thought. I'm just having problems counting tildes.

#define BIO_VMERGE_BOUNDARY   (0UL)//(ia64_max_iommu_merge_mask + 1)

Which for sba_iommu should have been:
   (ia64_max_iommu_merge_mask + 1)
		= (~IOVP_MASK + 1)
		= (~PAGE_MASK + 1)
		= (~(~(PAGE_SIZE-1)) + 1)
		= PAGE_SIZE

(I hope I have that right now)

> No, you got this backwards:

:^(

> the bio-level code _assumes_ that
> discontiguous physical pages can be remapped linearly by the I/O MMU
> code.  If the I/O MMU code doesn't actually do the merging, the kernel
> will fall flat on its face.

uhmm...why does the bio-level code care what can/can't be merged if
it's not going to do it?

Seems like a waste of CPU cycles to walk the sg_list an extra time
in the IOMMU code to figure what can (and will) be merged.  My gut
feeling is bio-level code doesn't know enough to do it efficiently
and the IOMMU code needs to walk the list at least once to program
the HW (effectively twice if sba_iommu wants to attempt coalescing).

thanks,
grant

  parent reply	other threads:[~2003-06-23 20:24 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-19 17:36 SCSI ERRORS triggered by BIO_VMERGE_BOUNDARY David Mosberger
2003-06-19 20:48 ` Jesse Barnes
2003-06-19 21:47 ` Grant Grundler
2003-06-23  7:11 ` Grant Grundler
2003-06-23 15:04 ` Alex Williamson
2003-06-23 16:52 ` David Mosberger
2003-06-23 20:24 ` Grant Grundler [this message]
2003-06-23 20:41 ` David Mosberger
2003-06-23 22:05 ` Grant Grundler
2003-06-23 22:14 ` David Mosberger
2003-06-24 21:07 ` Grant Grundler

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=marc-linux-ia64-105640005723820@msgid-missing \
    --to=iod00d@hp.com \
    --cc=linux-ia64@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.