From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Grall Subject: Re: [PATCH v3 4/5] xen/console: Add support for early printk Date: Wed, 12 Mar 2014 15:32:57 +0000 Message-ID: <53207E29.9060209@linaro.org> References: <1394634891-27906-1-git-send-email-julien.grall@linaro.org> <1394634891-27906-5-git-send-email-julien.grall@linaro.org> <5320893402000078001234E4@nat28.tlf.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1WNl9Q-00026o-UT for xen-devel@lists.xenproject.org; Wed, 12 Mar 2014 15:33:01 +0000 Received: by mail-wg0-f47.google.com with SMTP id x12so11426235wgg.18 for ; Wed, 12 Mar 2014 08:32:59 -0700 (PDT) In-Reply-To: <5320893402000078001234E4@nat28.tlf.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Jan Beulich Cc: xen-devel@lists.xenproject.org, Keir Fraser , stefano.stabellini@citrix.com, ian.campbell@citrix.com, tim@xen.org List-Id: xen-devel@lists.xenproject.org Hi Jan, On 03/12/2014 03:20 PM, Jan Beulich wrote: >>>> On 12.03.14 at 15:34, Julien Grall wrote: >> --- /dev/null >> +++ b/xen/include/xen/early_printk.h >> @@ -0,0 +1,21 @@ >> +/* >> + * printk() for use before the console is initialized >> + */ >> +#ifndef __XEN_EARLY_PRINTK_H__ >> +#define __XEN_EARLY_PRINTK_H__ >> + >> +#ifdef CONFIG_EARLY_PRINTK >> +void early_puts(const char *s); >> +#else >> +static inline void early_puts(const char *s) {}; > > Considering that the only (source) use of the function is to take its > address, using an inline function for that purpose is bogus. Either > #define it to NULL (thus leaving the serial_steal_fn initializer > unchanged for x86) or have it be a static __init function in > xen/drivers/char/console.c, conditional upon !CONFIG_EARLY_PRINTK. Right, I will fix it for the next version of this patch. Regards, -- Julien Grall