From: John Snow <jsnow@redhat.com>
To: qemu-devel@nongnu.org
Cc: peter.maydell@linaro.org, jsnow@redhat.com
Subject: [Qemu-devel] [PULL 3/3] qtest/ide-test: ppc64be correction for ATAPI tests
Date: Mon, 5 Oct 2015 12:01:54 -0400 [thread overview]
Message-ID: <1444060914-17069-4-git-send-email-jsnow@redhat.com> (raw)
In-Reply-To: <1444060914-17069-1-git-send-email-jsnow@redhat.com>
the 16bit ide data register is LE by definition.
Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Message-id: 1443461938-30039-1-git-send-email-jsnow@redhat.com
---
tests/ide-test.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/ide-test.c b/tests/ide-test.c
index 5594738..b6e9e1a 100644
--- a/tests/ide-test.c
+++ b/tests/ide-test.c
@@ -633,7 +633,7 @@ static void send_scsi_cdb_read10(uint64_t lba, int nblocks)
/* Send Packet */
for (i = 0; i < sizeof(Read10CDB)/2; i++) {
- outw(IDE_BASE + reg_data, ((uint16_t *)&pkt)[i]);
+ outw(IDE_BASE + reg_data, cpu_to_le16(((uint16_t *)&pkt)[i]));
}
}
@@ -733,7 +733,7 @@ static void cdrom_pio_impl(int nblocks)
size_t offset = i * (limit / 2);
size_t rem = (rxsize / 2) - offset;
for (j = 0; j < MIN((limit / 2), rem); j++) {
- rx[offset + j] = inw(IDE_BASE + reg_data);
+ rx[offset + j] = le16_to_cpu(inw(IDE_BASE + reg_data));
}
ide_wait_intr(IDE_PRIMARY_IRQ);
}
--
2.4.3
next prev parent reply other threads:[~2015-10-05 16:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-05 16:01 [Qemu-devel] [PULL 0/3] Ide patches John Snow
2015-10-05 16:01 ` [Qemu-devel] [PULL 1/3] qtest/ahci: fix redundant assertion John Snow
2015-10-05 16:01 ` [Qemu-devel] [PULL 2/3] MAINTAINERS: Small IDE/FDC touchup John Snow
2015-10-05 16:01 ` John Snow [this message]
2015-10-06 12:42 ` [Qemu-devel] [PULL 0/3] Ide patches Peter Maydell
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=1444060914-17069-4-git-send-email-jsnow@redhat.com \
--to=jsnow@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).