All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefan Weil <weil@mail.berlios.de>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] [STABLE] Clean some PCI defines
Date: Sun, 22 Mar 2009 15:20:32 +0100	[thread overview]
Message-ID: <49C64930.1070509@mail.berlios.de> (raw)
In-Reply-To: <E9531151-F5C4-4C49-880E-7D6B347FBE7E@web.de>

Andreas Färber schrieb:
> Hello,
>
> Am 22.03.2009 um 12:46 schrieb Stefan Weil:
>
>> Some defines from linux/pci_regs.h had similar, but not
>> the same defines in hw/pci.h (PCI_REVISION_ID / PCI_REVISION,
>> PCI_SUBSYSTEM_VENDOR_ID / PCI_SUBVENDOR_ID,
>> PCI_SUBSYSTEM_ID / PCI_SUBDEVICE_ID).
>>
>> I suggest to use the "standard" from linux/pci_regs.h and
>> replace the "old" Qemu ones. [...]
>> After a migration to the "standard" defines,
>> pci.h could use linux/pci_regs.h which is far more complete.
>
> Please keep in mind that linux/pci_regs.h is most likely not suitable
> for cross-platform use.
>
> You could of course do
>
> #ifdef __linux__
> #include <linux/pci_regs.h>
> #else
> #define PCI_... 0x1234
> ...
> #endif
>
> but then you would still need to sync the two sections.
>
> Andreas
>
>
>


There is nothing platform-specific in linux/pci_regs.h, only
general PCI stuff. No need for conditional compilation.

Stefan

  reply	other threads:[~2009-03-22 14:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-22 11:46 [Qemu-devel] [PATCH] [STABLE] Clean some PCI defines Stefan Weil
2009-03-22 12:31 ` Andreas Färber
2009-03-22 14:20   ` Stefan Weil [this message]
2009-03-22 14:46     ` Andreas Färber
2009-03-22 15:30       ` Stefan Weil
2009-03-22 13:09 ` M. Warner Losh
2009-03-28 17:31 ` Anthony Liguori

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=49C64930.1070509@mail.berlios.de \
    --to=weil@mail.berlios.de \
    --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.