All of lore.kernel.org
 help / color / mirror / Atom feed
From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: Jeremy Fitzhardinge <jeremy@goop.org>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	Yu Zhiguo <yuzg@cn.fujitsu.com>
Subject: Re: [PATCH] pv-ops: Fix missing 'ifdef CONFIG_XEN' in acpi
Date: Mon, 19 Apr 2010 09:30:26 -0400	[thread overview]
Message-ID: <20100419133026.GA17501@phenom.dumpdata.com> (raw)
In-Reply-To: <4BCA8E9A.6090209@goop.org>

On Sat, Apr 17, 2010 at 09:46:18PM -0700, Jeremy Fitzhardinge wrote:
> On 04/17/2010 08:56 PM, Yu Zhiguo wrote:
> > Konrad Rzeszutek Wilk wrote:
> >   
> >> On Fri, Apr 16, 2010 at 10:07:19AM +0800, Yu Zhiguo wrote:
> >>     
> >>> routines 'xen_register_gsi' and 'xen_teardown_msi_dev' cannot be used
> >>> unless macro 'CONFIG_XEN' is defined, otherwise build error occurs.
> >>>       
> >> There has to be a better of doing this. Aren't the
> >> xen_register_gsi defined in the header files? How about making in the
> >> header file the #ifdef CONFIG_XEN there?
> >>
> >>
> >>     
> > In fact, 'xen_register_gsi' is declared in header file 'asm/xen/pci.h'
> > with '#ifdef CONFIG_XEN', please refer to the following code.
> >
> > So 'acpi/boot.c' can use it but should check '#ifdef CONFIG_XEN'.
> > What's your opinion?
> >
> > -----------------------asm/xen/pci.h----------------------
> > #ifdef CONFIG_XEN
> > ...
> > #ifdef CONFIG_XEN_DOM0_PCI
> > int xen_register_gsi(u32 gsi, int triggering, int polarity);
> > ...
> > #else

So this #else is for the CONFIG_XEN_DOM0_PCI..
> > static inline int xen_register_gsi(u32 gsi, int triggering, int polarity)
> > {
> >         return -1;
> > }

perhaps add:

#else /* This is for CONFIG_XEN */

static inline int xen_register_gsi(...)
{

}
#endif

Or maybe better take out the xen_register_gsi out of this double
#ifdef and move it to its own. Say:


#if !defined(CONFIG_XEN)
static int xen_register_gsi(..)

#endif


> > ...
> >   
> 
> This is a good way of handling it.

The header file change or the #ifdef in the acpi/boot.c file?
> 
>     J
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel

  reply	other threads:[~2010-04-19 13:30 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-16  2:07 [PATCH] pv-ops: Fix missing 'ifdef CONFIG_XEN' in acpi Yu Zhiguo
2010-04-16 14:56 ` Konrad Rzeszutek Wilk
2010-04-18  3:56   ` Yu Zhiguo
2010-04-18  4:46     ` Jeremy Fitzhardinge
2010-04-19 13:30       ` Konrad Rzeszutek Wilk [this message]
2010-04-19 16:22         ` Jeremy Fitzhardinge
2010-04-20  5:31         ` Yu Zhiguo
2010-04-20 18:33           ` Konrad Rzeszutek Wilk
2010-04-21  3:29             ` Yu Zhiguo
2010-04-21 13:00               ` Konrad Rzeszutek Wilk
2010-04-21 13:53                 ` Yu Zhiguo
2010-04-21 16:33                   ` Jeremy Fitzhardinge
2010-04-22  4:05                     ` Yu Zhiguo
2010-04-22 16:27                       ` Jeremy Fitzhardinge
2010-04-25  4:24                         ` Yu Zhiguo
2010-04-21 16:31               ` Jeremy Fitzhardinge
2010-04-19 11:23   ` Failure to load the most recent kernel 2.6.10 ( xen/stable) under Xen 4.0 on Ubuntu 9.10 Boris Derzhavets
2010-04-20 10:44     ` Failure to load the most recent kernel 2.6.32.10 " Boris Derzhavets
2010-04-20 12:46       ` Boris Derzhavets
2010-04-20 18:21       ` Jeremy Fitzhardinge
2010-04-20 21:25         ` Boris Derzhavets
2010-04-21  8:05           ` Yu, Ke
2010-04-21 12:19             ` Boris Derzhavets

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=20100419133026.GA17501@phenom.dumpdata.com \
    --to=konrad.wilk@oracle.com \
    --cc=jeremy@goop.org \
    --cc=xen-devel@lists.xensource.com \
    --cc=yuzg@cn.fujitsu.com \
    /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.