From: "François Revol" <revol@free.fr>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] atapi on ppc issue (was Re: qemu-system-ppc broken ?)
Date: Sun, 09 Nov 2008 23:07:48 +0100 CET [thread overview]
Message-ID: <22272111134-BeMail@laptop> (raw)
In-Reply-To: <3916532044-BeMail@laptop>
[-- Attachment #1: Type: text/plain, Size: 1687 bytes --]
> > > Though I still can't seem to get OpenHackware to read the CD:
> > > ERROR: ATAPI TEST_UNIT_READY : status 50 != 0x40
> >
> > Replying to myself, it seems this works around the issue, at least
> > it
> > goes further.
> > I suppose OpenHackware only compares instead of checking the ready
> > bit...
>
> It seems I'm not the only one:
> http://groups.google.com/group/linux.debian.bugs.dist/browse_thread/thread/6937d731e3d4d4a8
> >
> I could try to fix the code in OH but I likely don't have the
> toolchain
> required to rebuild it.
>
Ok...
The attached patch makes OpenHackware happy again.
At least qemu-system-ppc can now start debian iso, and mine as well
(though I had to remove the chrp script as OH only checks the CRC on it
instead of interpreting...)
So now I can debug the bootloader at least.
Just posting it in case someone really urgently needs ppc back, as it's
ugly.
OpenHackware should be fixed instead, but it seems the binary in svn
has been updated after the last sources I found (archive.org has a
mirror of the dead website):
r3309 | j_mayer | 2007-10-01 08:44:33 +0200 (lun, 01 oct 2007) | 2
lines
Quickly hack PowerPC BIOS able to boot on CDROM again.
...
r1354 | bellard | 2005-04-07 01:06:54 +0200 (jeu, 07 avr 2005) | 2
lines
Open Hack'Ware version 0.4.1
Seems the last update was already about ATAPI...
Anyone has the latest source used ?
I could at least fix it to check for bits on errors...
Of course it'd be much better to switch to a real OF instead...
but I don't have the time for that, couldn't find usable OpenBIOS
images, and it sees CoreBoot v2 and v3 don't support ppc yet.
François.
[-- Attachment #2: qemu-openhackware-workaround-r5663.diff.txt --]
[-- Type: text/plain, Size: 2181 bytes --]
Index: hw/ide.c
===================================================================
--- hw/ide.c (révision 5663)
+++ hw/ide.c (copie de travail)
@@ -835,7 +835,7 @@
int64_t sector_num;
int ret, n;
- s->status = READY_STAT | SEEK_STAT;
+ s->status = READY_STAT | 0/*SEEK_STAT*/;
s->error = 0; /* not needed by IDE spec, but needed by Windows */
sector_num = ide_get_sector(s);
n = s->nsector;
@@ -940,7 +940,7 @@
/* end of transfer ? */
if (s->nsector == 0) {
- s->status = READY_STAT | SEEK_STAT;
+ s->status = READY_STAT | 0/*SEEK_STAT*/;
ide_set_irq(s);
eot:
bm->status &= ~BM_STATUS_DMAING;
@@ -1088,7 +1088,7 @@
static void ide_atapi_cmd_ok(IDEState *s)
{
s->error = 0;
- s->status = READY_STAT | SEEK_STAT;
+ s->status = READY_STAT | 0/*SEEK_STAT*/;
s->nsector = (s->nsector & ~7) | ATAPI_INT_REASON_IO | ATAPI_INT_REASON_CD;
ide_set_irq(s);
}
@@ -1100,6 +1100,7 @@
#endif
s->error = sense_key << 4;
s->status = READY_STAT | ERR_STAT;
+ s->status = DRQ_STAT;
s->nsector = (s->nsector & ~7) | ATAPI_INT_REASON_IO | ATAPI_INT_REASON_CD;
s->sense_key = sense_key;
s->asc = asc;
@@ -1202,7 +1203,7 @@
if (s->packet_transfer_size <= 0) {
/* end of transfer */
ide_transfer_stop(s);
- s->status = READY_STAT | SEEK_STAT;
+ s->status = READY_STAT | 0/*SEEK_STAT*/;
s->nsector = (s->nsector & ~7) | ATAPI_INT_REASON_IO | ATAPI_INT_REASON_CD;
ide_set_irq(s);
#ifdef DEBUG_IDE_ATAPI
@@ -1280,10 +1281,10 @@
s->io_buffer_index = 0;
if (s->atapi_dma) {
- s->status = READY_STAT | SEEK_STAT | DRQ_STAT;
+ s->status = READY_STAT | 0/*SEEK_STAT*/ | DRQ_STAT;
ide_dma_start(s, ide_atapi_cmd_read_dma_cb);
} else {
- s->status = READY_STAT | SEEK_STAT;
+ s->status = READY_STAT | 0/*SEEK_STAT*/;
ide_atapi_cmd_reply_end(s);
}
}
@@ -1298,7 +1299,7 @@
s->io_buffer_index = sector_size;
s->cd_sector_size = sector_size;
- s->status = READY_STAT | SEEK_STAT;
+ s->status = READY_STAT | 0/*SEEK_STAT*/;
ide_atapi_cmd_reply_end(s);
}
next prev parent reply other threads:[~2008-11-09 22:03 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-07 3:16 [Qemu-devel] qemu-system-ppc broken ? François Revol
2008-11-07 7:08 ` Aurelien Jarno
2008-11-07 7:53 ` François Revol
2008-11-07 8:19 ` [Qemu-devel] atapi on ppc issue (was Re: qemu-system-ppc broken ?) François Revol
2008-11-07 8:28 ` François Revol
2008-11-09 22:07 ` François Revol [this message]
2008-11-09 22:11 ` François Revol
2008-11-10 20:01 ` Andreas Färber
2008-11-10 20:27 ` François Revol
2008-11-10 20:56 ` Andreas Färber
2008-11-10 21:16 ` François Revol
2008-11-11 17:31 ` Blue Swirl
2008-11-11 17:58 ` Andreas Färber
2008-11-11 17:28 ` Blue Swirl
2008-11-11 19:54 ` Laurent Vivier
2008-11-16 19:32 ` Blue Swirl
2008-11-16 19:40 ` Laurent Vivier
2008-11-23 18:55 ` Blue Swirl
2008-11-24 8:34 ` René Rebe
2008-11-24 16:32 ` Andreas Färber
2008-11-27 15:13 ` Shin-ichiro KAWASAKI
2008-11-07 16:38 ` [Qemu-devel] qemu-system-ppc broken ? Laurent Desnogues
2008-11-08 8:57 ` Aurelien Jarno
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=22272111134-BeMail@laptop \
--to=revol@free.fr \
--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).