From patchwork Fri Sep 28 21:36:14 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 11860 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 98BB323E42 for ; Fri, 28 Sep 2012 21:36:25 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id 43926A180DC for ; Fri, 28 Sep 2012 21:36:25 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id e10so8011610iej.11 for ; Fri, 28 Sep 2012 14:36:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-provags-id:x-gm-message-state; bh=yAD66TkGy6RKh+aHExC8nxP/QKWMNIHvAZoQae3QK+0=; b=l7WZW1scEJPqjN6rxSCy6Rxa6Nh4bDKDrcETjcOZzCRcp/PJRpHxcVDyqa1fOOnJz1 HpQxy5uJ50SZ1kHfpQ4YZC56keIxYuQ5vomEnoDcnkEbKtH1M+pO2vaKcV63ciXv3jGw DJ4pr90i4iAKBwj0OdPc69xvY94M3jHzUeA1gxRA8HJgNWpfmYq3vXhokeF9FcVDa5oB 7+PIe+MjSlmEz03eM9ERtdgElYWQ+ZGOGuOlj8v5DIieSBfpJU5Qha7BLXkbdAOaIcih ZhRuQ3jm8/cYpZ7KGs2TZhTky6hSMcBgKGjI2rWA+pTZEj8VceBDc9AwGcw7S3+JVgrK 4Sgw== Received: by 10.50.217.229 with SMTP id pb5mr25924igc.28.1348868184982; Fri, 28 Sep 2012 14:36:24 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.184.232 with SMTP id ex8csp494986igc; Fri, 28 Sep 2012 14:36:24 -0700 (PDT) Received: by 10.180.105.6 with SMTP id gi6mr131689wib.4.1348868183631; Fri, 28 Sep 2012 14:36:23 -0700 (PDT) Received: from moutng.kundenserver.de (moutng.kundenserver.de. [212.227.126.186]) by mx.google.com with ESMTPS id z8si12358780wep.35.2012.09.28.14.36.23 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 28 Sep 2012 14:36:23 -0700 (PDT) Received-SPF: neutral (google.com: 212.227.126.186 is neither permitted nor denied by best guess record for domain of arnd@arndb.de) client-ip=212.227.126.186; Authentication-Results: mx.google.com; spf=neutral (google.com: 212.227.126.186 is neither permitted nor denied by best guess record for domain of arnd@arndb.de) smtp.mail=arnd@arndb.de Received: from localhost.localdomain (HSI-KBW-149-172-5-253.hsi13.kabel-badenwuerttemberg.de [149.172.5.253]) by mrelayeu.kundenserver.de (node=mrbap2) with ESMTP (Nemesis) id 0M9N4I-1T9Uls0ol4-00CLCv; Fri, 28 Sep 2012 23:36:22 +0200 From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, arm@kernel.org, Arnd Bergmann , Anton Vorontsov , Jason Wessel , Greg Kroah-Hartman Subject: [PATCH 09/12] tty/console: fix warnings in drivers/tty/serial/kgdboc.c Date: Fri, 28 Sep 2012 23:36:14 +0200 Message-Id: <1348868177-21205-10-git-send-email-arnd@arndb.de> X-Mailer: git-send-email 1.7.10 In-Reply-To: <1348868177-21205-1-git-send-email-arnd@arndb.de> References: <1348868177-21205-1-git-send-email-arnd@arndb.de> X-Provags-ID: V02:K0:Cfqt7UvwbYX9gMqm2lDc8Sq7+SuSpUVWWJ8OdhxNULK cDBxPXAvoTu9bcTTz1bVuftmxDTKlsZBqAXeBS9S7E474wLssM m/8nmx4RLyaCEOtyzluQXlTROjAJ9jAqPsPMZuhA/JqrdFbb5g BllUCMOkHGfcEQ54jDe4TgZ2AIe+Bss2iM5gvVQx+IG7vewE4p T2SPfJFh8VMCjcXZ6i8DRxIJIoJmzobpfhaGfhQND/+qjiEuFD nVhmrcW6wHqY11nr7IX49gOYxasbSLUVfFzA9YUqJj/7WB5ERO bdwoSRzj53oPTW/qqZSjdR3DUqHhbVIC3h2oafUT0hSWYvKHon NIYuTL5+wfFh72Uf5RWFh4e91Jprgr9yf4G/79fcZFrSlcZnpE ZpseHSS/9uSyA== X-Gm-Message-State: ALoCoQm610O/Fg3NpGXdRo5bJ4mekTIp5dBysqBiZGc3+q8YwnO5u10mPDMAeKuLLwR+LwRJBKmC The con_debug_leave/con_debug_enter functions are stubbed out by defining them to (0), which causes harmless build warnings. Using proper inline functions is the normal way to deal with this. Without this patch, building the ARM bcm2835_defconfig results in: drivers/tty/serial/kgdboc.c: In function 'kgdboc_pre_exp_handler': drivers/tty/serial/kgdboc.c:279:3: warning: statement with no effect [-Wunused-value] drivers/tty/serial/kgdboc.c: In function 'kgdboc_post_exp_handler': drivers/tty/serial/kgdboc.c:293:3: warning: statement with no effect [-Wunused-value] Signed-off-by: Arnd Bergmann Cc: Anton Vorontsov Cc: Jason Wessel Cc: Greg Kroah-Hartman --- include/linux/console.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/include/linux/console.h b/include/linux/console.h index 7201ce4..dedb082 100644 --- a/include/linux/console.h +++ b/include/linux/console.h @@ -83,8 +83,14 @@ void give_up_console(const struct consw *sw); int con_debug_enter(struct vc_data *vc); int con_debug_leave(void); #else -#define con_debug_enter(vc) (0) -#define con_debug_leave() (0) +static inline int con_debug_enter(struct vc_data *vc) +{ + return 0; +} +static inline int con_debug_leave(void) +{ + return 0; +} #endif /* scroll */