From: "Blue Swirl" <blauwirbel@gmail.com>
To: Ryan Harper <ryanh@us.ibm.com>
Cc: qemu-devel@nongnu.org, Paul Brook <paul@codesourcery.com>
Subject: [Qemu-devel] Re: [RESEND][PATCH] Add 40-bit DMA support to LSI scsi emulation
Date: Mon, 17 Nov 2008 21:25:27 +0200 [thread overview]
Message-ID: <f43fc5580811171125o2ed645ehcf28605d3c7e7546@mail.gmail.com> (raw)
In-Reply-To: <20081117173417.GT31893@us.ibm.com>
On 11/17/08, Ryan Harper <ryanh@us.ibm.com> wrote:
>
> Looking for some feedback on this patch, MAINTAINERS points to Paul for
> scsi stuff, and I saw Blue Swirl commit a scsi patch recently.
>
> This patch fixes Linux machines configured with > 4G of ram and using a
> SCSI device. I'm working on 64-bit DMA support as well which should
> hopefully fix 64-bit Windows using SCSI devices as well.
addr = s->dnad;
+ if (lsi_dma_40bit(s))
+ addr |= ((uint64_t)s->dnad64 << 32UL);
+ else if (s->sbms)
+ addr |= ((uint64_t)s->sbms << 32UL);
Maybe the address could be calculated at script parsing phase for
small performance gain.
I would use ULL instead of UL, because on 32 bit host long is still 32 bits.
> + DPRINTF("DMA addr=0x%" PRIx64 " len=%d\n", addr, count);
PRIx64 will be incorrect if target_phys_addr_t is 32 bits. You should
use TARGET_FMT_plx instead.
> + uint32_t addr, addr64;
Looking at the code after this I thought that addr64 is 64 bits, maybe
addr_high would be a better name?
next prev parent reply other threads:[~2008-11-17 19:25 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-17 17:34 [Qemu-devel] [RESEND][PATCH] Add 40-bit DMA support to LSI scsi emulation Ryan Harper
2008-11-17 19:25 ` Blue Swirl [this message]
2008-11-17 20:02 ` [Qemu-devel] " Anthony Liguori
2008-11-17 20:47 ` M. Warner Losh
2008-11-17 20:56 ` Ryan Harper
2008-11-18 22:01 ` Anthony Liguori
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=f43fc5580811171125o2ed645ehcf28605d3c7e7546@mail.gmail.com \
--to=blauwirbel@gmail.com \
--cc=paul@codesourcery.com \
--cc=qemu-devel@nongnu.org \
--cc=ryanh@us.ibm.com \
/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;
as well as URLs for NNTP newsgroup(s).