From: "Andreas Färber" <afaerber@suse.de>
To: Kevin Wolf <kwolf@redhat.com>,
David Gibson <david@gibson.dropbear.id.au>
Cc: Paolo Bonzini <pbonzini@redhat.com>,
Hannes Reinecke <hare@suse.de>, Alexander Graf <agraf@suse.de>,
qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] Use DMADirection type for dma_bdrv_io
Date: Wed, 22 Feb 2012 10:54:08 +0100 [thread overview]
Message-ID: <4F44BB40.8070703@suse.de> (raw)
In-Reply-To: <20120222011154.GN16796@truffala.fritz.box>
Am 22.02.2012 02:11, schrieb David Gibson:
> On Tue, Feb 21, 2012 at 10:09:01AM +0100, Kevin Wolf wrote:
>> Am 21.02.2012 09:35, schrieb Paolo Bonzini:
>>> On 02/20/2012 11:50 AM, Alexander Graf wrote:
>>>>>> DMAAIOCB *dbs = qemu_aio_get(&dma_aio_pool, bs, cb, opaque);
>>>>>>
>>>>>> - trace_dma_bdrv_io(dbs, bs, sector_num, to_dev);
>>>>>> + trace_dma_bdrv_io(dbs, bs, sector_num, dir);
>>>> Was the trace wrong before or is it now? I don't see its definition changed anywhere.
>>>
>>> Not sure what you mean. :)
>>
>> trace-events:
>>
>> dma_bdrv_io(void *dbs, void *bs, int64_t sector_num, bool to_dev)
>> "dbs=%p bs=%p sector_num=%" PRId64 " to_dev=%d"
>
> Ah, damnit. Didn't find that file. I'll resubmit with trace-events
> updated too.
>
>> to_dev is declared bool here, and it should also be renamed to dir (the
>> unfortunate thing about DMADirection is that it swaps 0 and 1 compared
>> to bool to_dev... We need to check carefully that all occurrences have
>> been caught.)
>
> Yeah. And even more unfortunate that afaict there's no way to make
> gcc warn on enum<->bool conversions. Still there are only about 4
> callers of dma_bdrv_io() - nearly everything uses the
> dma_bdrv_{read,write}() wrappers - so I'm confident I got them all.
Re all occurrences: megasas might be affected by such a change, too
(patch on the list).
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
next prev parent reply other threads:[~2012-02-22 9:54 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-20 3:01 [Qemu-devel] [PATCH] Use DMADirection type for dma_bdrv_io David Gibson
2012-02-20 10:50 ` Alexander Graf
2012-02-21 1:14 ` David Gibson
2012-02-21 8:35 ` Paolo Bonzini
2012-02-21 9:09 ` Kevin Wolf
2012-02-22 1:11 ` David Gibson
2012-02-22 9:54 ` Andreas Färber [this message]
2012-02-22 9:55 ` Hannes Reinecke
-- strict thread matches above, loose matches on Subject: below --
2012-03-27 2:42 David Gibson
2012-03-27 7:17 ` Stefan Hajnoczi
2012-03-27 14:30 ` Andreas Färber
2012-03-27 14:43 ` Kevin Wolf
2012-03-27 15:17 ` Andreas Färber
2012-03-27 15:23 ` Kevin Wolf
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=4F44BB40.8070703@suse.de \
--to=afaerber@suse.de \
--cc=agraf@suse.de \
--cc=david@gibson.dropbear.id.au \
--cc=hare@suse.de \
--cc=kwolf@redhat.com \
--cc=pbonzini@redhat.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 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.