From patchwork Fri Jul 6 13:41:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hannes Schmelzer X-Patchwork-Id: 940510 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=oevsv.at Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 41MbY96h2hz9s4c for ; Fri, 6 Jul 2018 23:43:57 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 467DAC21DDC; Fri, 6 Jul 2018 13:42:38 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id F1A2FC22065; Fri, 6 Jul 2018 13:41:59 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 86487C21F58; Fri, 6 Jul 2018 13:41:55 +0000 (UTC) Received: from mail.schmelzer.or.at (mail.schmelzer.or.at [87.106.47.214]) by lists.denx.de (Postfix) with ESMTP id 1232CC22046 for ; Fri, 6 Jul 2018 13:41:52 +0000 (UTC) Received: from localhost (s15287728.onlinehome-server.info [127.0.0.1]) by hamspirit.at (Postfix) with ESMTP id E93E48F48CB4; Fri, 6 Jul 2018 13:41:51 +0000 (UTC) Received: from mail.schmelzer.or.at ([127.0.0.1]) by localhost (s15287728.onlinehome-server.info [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id pB9kEZgrkvie; Fri, 6 Jul 2018 13:41:46 +0000 (UTC) Received: from scm-ws12.ampr.at (unknown [213.174.225.82]) by hamspirit.at (Postfix) with ESMTP id 107488F480C1; Fri, 6 Jul 2018 13:41:42 +0000 (UTC) From: Hannes Schmelzer To: u-boot@lists.denx.de Date: Fri, 6 Jul 2018 15:41:20 +0200 Message-Id: <1530884489-28089-4-git-send-email-oe5hpm@oevsv.at> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1530884489-28089-1-git-send-email-oe5hpm@oevsv.at> References: <1530884489-28089-1-git-send-email-oe5hpm@oevsv.at> Cc: Hannes Schmelzer Subject: [U-Boot] [PATCH 03/12] board/BuR/common: make CONFIG_LCD optional X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Since we're going to drop LCD-support on brppt1 boards, we have to make this stuff here optional and remove the #error path. We also move out the ft_board_setup(...) from this #ifdef because there's no relationship with the LCD-code and on the other hand this is still needed in future even with LCD-support off. Signed-off-by: Hannes Schmelzer --- board/BuR/common/common.c | 39 ++++++++++++++++++--------------------- 1 file changed, 18 insertions(+), 21 deletions(-) diff --git a/board/BuR/common/common.c b/board/BuR/common/common.c index 29430e9..e1ac6c4 100644 --- a/board/BuR/common/common.c +++ b/board/BuR/common/common.c @@ -156,24 +156,6 @@ int load_lcdtiming(struct am335x_lcdpanel *panel) return 0; } -int ft_board_setup(void *blob, bd_t *bd) -{ - int nodeoffset; - - nodeoffset = fdt_path_offset(blob, "/factory-settings"); - if (nodeoffset < 0) { - puts("set bootloader version 'factory-settings' not in dtb!\n"); - return -1; - } - if (fdt_setprop(blob, nodeoffset, "bl-version", - PLAIN_VERSION, strlen(PLAIN_VERSION)) != 0) { - puts("set bootloader version 'bl-version' prop. not in dtb!\n"); - return -1; - } - - return 0; -} - static void br_summaryscreen_printenv(char *prefix, char *name, char *altname, char *suffix) @@ -262,11 +244,26 @@ void lcd_enable(void) br_summaryscreen(); lcdbacklight(1); } -#elif CONFIG_SPL_BUILD -#else -#error "LCD-support with a suitable FB-Driver is mandatory !" #endif /* CONFIG_LCD */ +int ft_board_setup(void *blob, bd_t *bd) +{ + int nodeoffset; + + nodeoffset = fdt_path_offset(blob, "/factory-settings"); + if (nodeoffset < 0) { + puts("set bootloader version 'factory-settings' not in dtb!\n"); + return -1; + } + if (fdt_setprop(blob, nodeoffset, "bl-version", + PLAIN_VERSION, strlen(PLAIN_VERSION)) != 0) { + puts("set bootloader version 'bl-version' prop. not in dtb!\n"); + return -1; + } + + return 0; +} + #ifdef CONFIG_SPL_BUILD void pmicsetup(u32 mpupll) {