From patchwork Wed Apr 3 14:23:09 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Gortmaker X-Patchwork-Id: 2387641 X-Patchwork-Delegate: lethal@linux-sh.org Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 32A623FD8C for ; Wed, 3 Apr 2013 14:24:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758844Ab3DCOYK (ORCPT ); Wed, 3 Apr 2013 10:24:10 -0400 Received: from mail1.windriver.com ([147.11.146.13]:54774 "EHLO mail1.windriver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752837Ab3DCOYJ (ORCPT ); Wed, 3 Apr 2013 10:24:09 -0400 Received: from ALA-HCA.corp.ad.wrs.com (ala-hca.corp.ad.wrs.com [147.11.189.40]) by mail1.windriver.com (8.14.5/8.14.3) with ESMTP id r33ENfhc015526 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=FAIL); Wed, 3 Apr 2013 07:23:41 -0700 (PDT) Received: from yow-lpgnfs-02.corp.ad.wrs.com (128.224.149.8) by ALA-HCA.corp.ad.wrs.com (147.11.189.40) with Microsoft SMTP Server id 14.2.342.3; Wed, 3 Apr 2013 07:23:41 -0700 From: Paul Gortmaker To: Andrew Morton CC: Geert Uytterhoeven , , , Paul Gortmaker , Thomas Gleixner , Paul Mundt Subject: [PATCH-mmotm] sh4: make the bios early console support depend on EARLY_PRINTK Date: Wed, 3 Apr 2013 10:23:09 -0400 Message-ID: <1364998989-27357-1-git-send-email-paul.gortmaker@windriver.com> X-Mailer: git-send-email 1.8.1.2 MIME-Version: 1.0 Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org The commit "early_printk: consolidate random copies of identical code" introduces a build failure for the lboxre2_defconfig because arch/sh unconditionally assumes that there will be an early_console struct present that it can populate with bios routines to drive the early printk support. Making this whole block conditional on EARLY_PRINTK solves the problem and gets rid of unused runtime code for when the feature is disabled at the same time. Reported-by: Geert Uytterhoeven Cc: Thomas Gleixner Cc: Andrew Morton Cc: Paul Mundt Signed-off-by: Paul Gortmaker --- Related mmotm patches: * early_printk-consolidate-random-copies-of-identical-code.patch * early_printk-consolidate-random-copies-of-identical-code-v3.patch * early_printk-consolidate-random-copies-of-identical-code-v3-fix.patch * include-linux-printkh-include-stdargh.patch arch/sh/kernel/sh_bios.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/sh/kernel/sh_bios.c b/arch/sh/kernel/sh_bios.c index a5b51b9..fe584e5 100644 --- a/arch/sh/kernel/sh_bios.c +++ b/arch/sh/kernel/sh_bios.c @@ -104,6 +104,7 @@ void sh_bios_vbr_reload(void) ); } +#ifdef CONFIG_EARLY_PRINTK /* * Print a string through the BIOS */ @@ -168,3 +169,4 @@ static int __init setup_early_printk(char *buf) return 0; } early_param("earlyprintk", setup_early_printk); +#endif