From: Anthony Liguori <anthony@codemonkey.ws>
To: qemu-devel@nongnu.org
Cc: Gleb Natapov <gleb@qumranet.com>
Subject: Re: [Qemu-devel] [PATCH] Ignore IDE command if issued while IDE is busy.
Date: Thu, 21 Aug 2008 14:46:49 -0500 [thread overview]
Message-ID: <48ADC629.90703@codemonkey.ws> (raw)
In-Reply-To: <20080818102240.30186.32779.stgit@gleb-debian.qumranet.com.qumranet.com>
Gleb Natapov wrote:
> @@ -2511,6 +2524,11 @@ static uint32_t ide_data_readw(void *opaque, uint32_t addr)
> IDEState *s = ((IDEState *)opaque)->cur_drive;
> uint8_t *p;
> int ret;
> +
> + /* PIO data access allowed only when DRQ bit is set */
> + if (!(s->status & DRQ_STAT))
> + return;
>
Returns a uint32_t but you just do return;
> p = s->data_ptr;
> ret = cpu_to_le16(*(uint16_t *)p);
> p += 2;
> @@ -2525,6 +2543,10 @@ static void ide_data_writel(void *opaque, uint32_t addr, uint32_t val)
> IDEState *s = ((IDEState *)opaque)->cur_drive;
> uint8_t *p;
>
> + /* PIO data access allowed only when DRQ bit is set */
> + if (!(s->status & DRQ_STAT))
> + return;
> +
> p = s->data_ptr;
> *(uint32_t *)p = le32_to_cpu(val);
> p += 4;
> @@ -2539,6 +2561,10 @@ static uint32_t ide_data_readl(void *opaque, uint32_t addr)
> uint8_t *p;
> int ret;
>
> + /* PIO data access allowed only when DRQ bit is set */
> + if (!(s->status & DRQ_STAT))
> + return;
>
This function returns a uint32_t but you just have a return; here.
Regards,
Anthony Liguori
> p = s->data_ptr;
> ret = cpu_to_le32(*(uint32_t *)p);
> p += 4;
>
>
>
>
next prev parent reply other threads:[~2008-08-21 19:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-18 10:22 [Qemu-devel] [PATCH] Ignore IDE command if issued while IDE is busy Gleb Natapov
2008-08-21 19:46 ` Anthony Liguori [this message]
2008-08-21 21:00 ` Gleb Natapov
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=48ADC629.90703@codemonkey.ws \
--to=anthony@codemonkey.ws \
--cc=gleb@qumranet.com \
--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).