qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [PATCHv2] qemu: target library, use it in msix


From: Blue Swirl
Subject: [Qemu-devel] Re: [PATCHv2] qemu: target library, use it in msix
Date: Thu, 24 Sep 2009 23:13:38 +0300

On Thu, Sep 24, 2009 at 10:11 PM, Michael S. Tsirkin <address@hidden> wrote:
> On Thu, Sep 24, 2009 at 08:50:11PM +0300, Blue Swirl wrote:
>> On Wed, Sep 23, 2009 at 11:06 PM, Michael S. Tsirkin <address@hidden> wrote:
>> > This creates target.c, which builds per-target, and makes it possible
>> > for devices to become target-independent.  Use it in msix, reverting
>> > part of 5e520a7d500ec2569d22d80f9ef4272a34cb3c80, as we no longer have
>> > to pass target page around.
>>
>> > +unsigned target_page_align(unsigned value)
>> > +{
>> > +       return TARGET_PAGE_ALIGN(value);
>> > +}
>>
>> This must be:
>> target_phys_addr_t target_page_align(target_phys_addr_t value)
>
> what's the point then? It has to be target independent.
> Let's make it unsigned long long, should be good enough.

target_phys_addr_t is handled by hwlib definitions, so it can be used
for hwlib devices. If you can remove all target_phys_addr_t uses, then
the compilation of the file could be moved from Makefile.hw to
Makefile.

One day the bus addresses should be decoupled from the target CPU
addresses, but for now we are stick with target_phys_addr_t.

>> As this is not a clean revert anyway, please don't revert the part changing
>> if (x)
>>  y;
>> else
>>  z;
>>
>> to
>>
>> if (x) {
>>  y;
>> } else {
>>  z;
>> }
>
> Did I mention I hate this style? But okay :).

I'm not a great fan of this either, but this is the CODING_STYLE.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]