From patchwork Sat Aug 25 19:40:08 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Gra=C5=BEvydas_Ignotas?= X-Patchwork-Id: 962197 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=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="u4yEaCsA"; dkim-atps=neutral Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 41yT5d2KPhz9s4v for ; Sun, 26 Aug 2018 05:40:32 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id CA70CC21E26; Sat, 25 Aug 2018 19:40:22 +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=FREEMAIL_FROM, RCVD_IN_MSPIKE_H2, T_DKIM_INVALID 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 D0FC2C21C27; Sat, 25 Aug 2018 19:40:19 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 930DDC21C27; Sat, 25 Aug 2018 19:40:18 +0000 (UTC) Received: from mail-lf1-f68.google.com (mail-lf1-f68.google.com [209.85.167.68]) by lists.denx.de (Postfix) with ESMTPS id EB0ADC21BE5 for ; Sat, 25 Aug 2018 19:40:17 +0000 (UTC) Received: by mail-lf1-f68.google.com with SMTP id g9-v6so9074747lfh.1 for ; Sat, 25 Aug 2018 12:40:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=yIqK4GbJFpCcyQa8cA84oBKsZT2dXPyw4JtfXpMZjHw=; b=u4yEaCsAj/nzVPtbum7BvJRXutipXpctsasA64aer6LCdWDQVwhCqIxjjZBLoyE/IE 44gdIgLElsM3qOHdOq1U0M2RKkKvkl2L7maxXZHXTboX2bhSdIvAQQFqERDLld/6hsLq JIcoqW3x+SJ5M20GVMZvuEDvrw2FkgKnxaMipVVMYE7wUx7W7sjPK2YNzUK/BA6YDNKD BAlWIiTTZ02FVOgiSKdZgfLT66+rM6rCQzUib92g9UPKa1OPXQ+JEA8QhjW2BSrwBKWW /tFKvAsumIy6FAgXvl/T34kOMwcaVTQngIUuc6hhTRjThq6NuIqpqBDcrMgRYvQTeTxO h0VA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=yIqK4GbJFpCcyQa8cA84oBKsZT2dXPyw4JtfXpMZjHw=; b=iItzCWz6dVUISOytsah+AKbGfJ/zEPWpWlVNwrCFwTY3WrxeCW5m+uErZOclacJHys Ak59V7BzTvbCNrteaxSrC/jaqprhhf14jat/8cC6vgel5++X6CgwOmFjSDuEbQb6yBf8 FBzMDVeddQYS3Svogdfa0+3EC9jMIqZ/vcjR9g79pChVadTQCo6OWut86VYV6VM3hS21 8zmArrBghc0j6HekUokZX2hpCH1qNJ2mTwTFhPeZrPqbX4zKlFJiaWnlX7G3Ip93ZcFL HrjgEFsWJq42pSvUiE84UoyZM8PMHYDsUb0OImpw540evgicpDVgOuXIa7+8GlVNF2VV 0BPw== X-Gm-Message-State: APzg51AaFcykskE3MoAHIvpZDhKdItCNozm/IMOqc/YXlMM4i6tricH6 nBwR2gU52jQEK0cuVa5o+GfEBPHU X-Google-Smtp-Source: ANB0VdY2lHThQZutjAmgQ8IAysZCOMfpmXDHJPlA5Bir6PRYkBtc03i8fT6cO2arZ095GjFjDkgydQ== X-Received: by 2002:a19:3855:: with SMTP id d21-v6mr4332665lfj.24.1535226014787; Sat, 25 Aug 2018 12:40:14 -0700 (PDT) Received: from localhost.localdomain (ip-46-251-49-50.kava.lt. [46.251.49.50]) by smtp.gmail.com with ESMTPSA id q19-v6sm1819451lji.14.2018.08.25.12.40.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 25 Aug 2018 12:40:14 -0700 (PDT) From: Grazvydas Ignotas To: u-boot@lists.denx.de Date: Sat, 25 Aug 2018 22:40:08 +0300 Message-Id: <20180825194008.3625-1-notasas@gmail.com> X-Mailer: git-send-email 2.17.1 Subject: [U-Boot] [PATCH] omap3: pandora: Enable DM_SERIAL 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" This patch enables DM_SERIAL for the pandora board. Verified that the default kernel can still be booted with this. Signed-off-by: Grazvydas Ignotas --- board/pandora/pandora.c | 14 ++++++++++++++ configs/omap3_pandora_defconfig | 4 +++- include/configs/omap3_pandora.h | 17 ----------------- 3 files changed, 17 insertions(+), 18 deletions(-) diff --git a/board/pandora/pandora.c b/board/pandora/pandora.c index 4f91dc3bee..a9aae7951d 100644 --- a/board/pandora/pandora.c +++ b/board/pandora/pandora.c @@ -13,6 +13,8 @@ * Texas Instruments, */ #include +#include +#include #include #include #include @@ -33,6 +35,18 @@ DECLARE_GLOBAL_DATA_PTR; #define GPIO_IO_PWRDNZ (1 << 6) #define PBIASLITEVMODE1 (1 << 8) +static const struct ns16550_platdata pandora_serial = { + .base = OMAP34XX_UART3, + .reg_shift = 2, + .clock = V_NS16550_CLK, + .fcr = UART_FCR_DEFVAL, +}; + +U_BOOT_DEVICE(pandora_uart) = { + "ns16550_serial", + &pandora_serial +}; + /* * Routine: board_init * Description: Early hardware init. diff --git a/configs/omap3_pandora_defconfig b/configs/omap3_pandora_defconfig index 6dce53834d..c2b4a4f0d2 100644 --- a/configs/omap3_pandora_defconfig +++ b/configs/omap3_pandora_defconfig @@ -1,6 +1,7 @@ CONFIG_ARM=y CONFIG_ARCH_OMAP2PLUS=y CONFIG_SYS_TEXT_BASE=0x80008000 +CONFIG_SYS_MALLOC_F_LEN=0x2000 CONFIG_TARGET_OMAP3_PANDORA=y CONFIG_DISTRO_DEFAULTS=y CONFIG_NR_DRAM_BANKS=2 @@ -25,11 +26,12 @@ CONFIG_MTDIDS_DEFAULT="nand0=omap2-nand.0" CONFIG_MTDPARTS_DEFAULT="mtdparts=omap2-nand.0:512k(xloader),1920k(uboot),128k(uboot-env),10m(boot),-(rootfs)" CONFIG_CMD_UBI=y CONFIG_ENV_IS_IN_NAND=y +CONFIG_DM=y CONFIG_TWL4030_LED=y CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y CONFIG_SYS_NAND_BUSWIDTH_16BIT=y -CONFIG_CONS_INDEX=3 +CONFIG_DM_SERIAL=y CONFIG_SYS_NS16550=y CONFIG_SPI=y CONFIG_OMAP3_SPI=y diff --git a/include/configs/omap3_pandora.h b/include/configs/omap3_pandora.h index 5a82cbee71..82c66c4b8c 100644 --- a/include/configs/omap3_pandora.h +++ b/include/configs/omap3_pandora.h @@ -19,23 +19,6 @@ #define CONFIG_SYS_DEVICE_NULLDEV 1 -/* - * Hardware drivers - */ - -/* TWL4030 LED */ - -/* - * NS16550 Configuration - */ -#undef CONFIG_SYS_NS16550_CLK -#define CONFIG_SYS_NS16550_SERIAL -#define CONFIG_SYS_NS16550_REG_SIZE (-4) -#define CONFIG_SYS_NS16550_CLK V_NS16550_CLK -#define CONFIG_SYS_NS16550_COM3 OMAP34XX_UART3 - -/* commands to include */ - /* * Board NAND Info. */