From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 71C67C41604 for ; Tue, 6 Oct 2020 07:08:36 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0EDB02075A for ; Tue, 6 Oct 2020 07:08:36 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="ygm7GVcO"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=st.com header.i=@st.com header.b="e49nVdPh" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0EDB02075A Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=st.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe :List-Id:MIME-Version:Content-ID:In-Reply-To:References:Message-ID:Date: Subject:To:From:Reply-To:Cc:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=FBWlKtrEARepNWfPx5kdhC/dmKC2/9vYcFxLxow2C5c=; b=ygm7GVcOi0i7eEIxOA84sEX97Z FCdsdfITwWzajTrNPWLWMAHa1w0zRJ0QvRB1HGGgHYGtRjHIXhzk8pnsv6dmJjU/vnUQd+lIk0hq9 MqUDqK+M5Tw5LySND0ZRVV69/mYlilCVj+PkuuU2bNdzfXhrRTZHHj3ahJXs2VfRIiyyqWdPNkPls ChVxNPOoYMzrkS60MVVxsU04V2uv87OgpmrEcUumuFsDQ8lHI+0L5okYj+zivEnyiG0TwelpqiyqG zenn5dLBHkax2HDFkmh93NC11FSL8bbhLHgLmXjU1hfj+GDgCNdSnC795z4gUmyLNoaOMj+GaedcH m1JU1V9g==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kPh45-0004SM-Sf; Tue, 06 Oct 2020 07:07:13 +0000 Received: from mx07-00178001.pphosted.com ([185.132.182.106]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kPh42-0004RC-JE for linux-arm-kernel@lists.infradead.org; Tue, 06 Oct 2020 07:07:12 +0000 Received: from pps.filterd (m0046668.ppops.net [127.0.0.1]) by mx07-00178001.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 0966wFXG022130; Tue, 6 Oct 2020 09:06:50 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com; h=from : to : subject : date : message-id : references : in-reply-to : content-type : content-id : content-transfer-encoding : mime-version; s=STMicroelectronics; bh=FxjkPnYQkvGM1UmAHc6w4pfL14faN87LhAm30HIRRnE=; b=e49nVdPhjPNupETe6/U4g30ynwcqKKTHgkMelWWBoGAFOEC9lJ8XidzVX84zrLKHLGS4 LTDYEUezQxAHaln8YjsxkQE5P4J1w7tScTJlr+zOrHUAVmNV/8tnxs9zD/KUBE/5NsbI mCBw9IOcp3le5FRgAWgM8j5OFiLYvBk0NdcAyGmQmds4af1de1jN2Z62W+xUKI4l3gNV 7F7E1oeoDnJAh9fnEc/odvcJ3cGrjSzoPDutXj+ZazvhuIsXrHlBJaKQ61QQrZhKatA7 ilcc+T65G1iyq1kYhMwxNAa3G9sMAWQQ2N6Q352CLltmukm3bHVst4aMp+yAV2KUmyB6 uA== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 3402tjctq2-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 06 Oct 2020 09:06:50 +0200 Received: from euls16034.sgp.st.com (euls16034.sgp.st.com [10.75.44.20]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 7BEE710002A; Tue, 6 Oct 2020 09:06:48 +0200 (CEST) Received: from Webmail-eu.st.com (sfhdag2node1.st.com [10.75.127.4]) by euls16034.sgp.st.com (STMicroelectronics) with ESMTP id 4FA91212FB1; Tue, 6 Oct 2020 09:06:48 +0200 (CEST) Received: from SFHDAG2NODE3.st.com (10.75.127.6) by SFHDAG2NODE1.st.com (10.75.127.4) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Tue, 6 Oct 2020 09:06:47 +0200 Received: from SFHDAG2NODE3.st.com ([fe80::31b3:13bf:2dbe:f64c]) by SFHDAG2NODE3.st.com ([fe80::31b3:13bf:2dbe:f64c%20]) with mapi id 15.00.1473.003; Tue, 6 Oct 2020 09:06:47 +0200 From: Patrice CHOTARD To: Alain Volmat , Russell King , "Arnd Bergmann" , Sascha Hauer , "Olof Johansson" , Linus Walleij , "Nathan Huckleberry" , Geert Uytterhoeven , Claudiu Beznea , Enrico Weigelt , Thomas Gleixner , "Kate Stewart" , Greg Kroah-Hartman , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v2 1/2] arm: use DEBUG_UART_PHYS and DEBUG_UART_VIRT for sti LL_UART Thread-Topic: [PATCH v2 1/2] arm: use DEBUG_UART_PHYS and DEBUG_UART_VIRT for sti LL_UART Thread-Index: AQHWfwft1nwSe3V2OE+vyTqBVDD3damKPumA Date: Tue, 6 Oct 2020 07:06:47 +0000 Message-ID: <63b485cb-664d-f00f-8319-ad860f9e69c9@st.com> References: <20200830195748.30221-1-avolmat@me.com> <20200830195748.30221-2-avolmat@me.com> In-Reply-To: <20200830195748.30221-2-avolmat@me.com> Accept-Language: fr-FR, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.75.127.44] Content-ID: <2D593EB3D5E00B45B909EE0E40B52C8B@st.com> MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.235, 18.0.687 definitions=2020-10-06_02:2020-10-06, 2020-10-06 signatures=0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201006_030710_999766_6A255882 X-CRM114-Status: GOOD ( 26.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Alain On 8/30/20 9:57 PM, Alain Volmat wrote: > Update the sti platform LL_UART support to rely on > CONFIG_DEBUG_UART_PHYS and CONFIG_DEBUG_UART_VIRT from Kconfig > > Signed-off-by: Alain Volmat > --- > arch/arm/Kconfig.debug | 23 ++++++++++++----------- > arch/arm/include/debug/sti.S | 26 ++------------------------ > 2 files changed, 14 insertions(+), 35 deletions(-) > > diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug > index 80000a66a4e3..e97d6e5c8898 100644 > --- a/arch/arm/Kconfig.debug > +++ b/arch/arm/Kconfig.debug > @@ -1184,10 +1184,9 @@ choice > Say Y here if you want kernel low-level debugging support > on ST SPEAr13xx based platforms. > > - config STIH41X_DEBUG_ASC2 > + config DEBUG_STIH41X_ASC2 > bool "Use StiH415/416 ASC2 UART for low-level debug" > depends on ARCH_STI > - select DEBUG_STI_UART > help > Say Y here if you want kernel low-level debugging support > on STiH415/416 based platforms like b2000, which has > @@ -1195,10 +1194,9 @@ choice > > If unsure, say N. > > - config STIH41X_DEBUG_SBC_ASC1 > + config DEBUG_STIH41X_SBC_ASC1 > bool "Use StiH415/416 SBC ASC1 UART for low-level debug" > depends on ARCH_STI > - select DEBUG_STI_UART > help > Say Y here if you want kernel low-level debugging support > on STiH415/416 based platforms like b2020. which has > @@ -1534,10 +1532,6 @@ config DEBUG_TEGRA_UART > bool > depends on ARCH_TEGRA > > -config DEBUG_STI_UART > - bool > - depends on ARCH_STI > - > config DEBUG_STM32_UART > bool > depends on ARCH_STM32 > @@ -1591,7 +1585,8 @@ config DEBUG_LL_INCLUDE > default "debug/s3c24xx.S" if DEBUG_S3C24XX_UART || DEBUG_S3C64XX_UART > default "debug/s5pv210.S" if DEBUG_S5PV210_UART > default "debug/sirf.S" if DEBUG_SIRFSOC_UART > - default "debug/sti.S" if DEBUG_STI_UART > + default "debug/sti.S" if DEBUG_STIH41X_ASC2 > + default "debug/sti.S" if DEBUG_STIH41X_SBC_ASC1 > default "debug/stm32.S" if DEBUG_STM32_UART > default "debug/tegra.S" if DEBUG_TEGRA_UART > default "debug/ux500.S" if DEBUG_UX500_UART > @@ -1723,7 +1718,9 @@ config DEBUG_UART_PHYS > default 0xfc00c000 if DEBUG_AT91_SAMA5D4_USART3 > default 0xfcb00000 if DEBUG_HI3620_UART > default 0xfd883000 if DEBUG_ALPINE_UART0 > + default 0xfe531000 if DEBUG_STIH41X_SBC_ASC1 > default 0xfe800000 if ARCH_IOP32X > + default 0xfed32000 if DEBUG_STIH41X_ASC2 > default 0xff690000 if DEBUG_RK32_UART2 > default 0xffc02000 if DEBUG_SOCFPGA_UART0 > default 0xffc02100 if DEBUG_SOCFPGA_ARRIA10_UART1 > @@ -1752,7 +1749,8 @@ config DEBUG_UART_PHYS > DEBUG_S3C64XX_UART || \ > DEBUG_BCM63XX_UART || DEBUG_ASM9260_UART || \ > DEBUG_SIRFSOC_UART || DEBUG_DIGICOLOR_UA0 || \ > - DEBUG_AT91_UART || DEBUG_STM32_UART > + DEBUG_AT91_UART || DEBUG_STM32_UART || \ > + DEBUG_STIH41X_ASC2 || DEBUG_STIH41X_SBC_ASC1 > > config DEBUG_UART_VIRT > hex "Virtual base address of debug UART" > @@ -1817,7 +1815,9 @@ config DEBUG_UART_VIRT > default 0xfc705000 if DEBUG_ZTE_ZX > default 0xfcfe8600 if DEBUG_BCM63XX_UART > default 0xfd000000 if DEBUG_SPEAR3XX || DEBUG_SPEAR13XX > + default 0xfd531000 if DEBUG_STIH41X_SBC_ASC1 > default 0xfd883000 if DEBUG_ALPINE_UART0 > + default 0xfdd32000 if DEBUG_STIH41X_ASC2 > default 0xfe010000 if STM32MP1_DEBUG_UART > default 0xfe017000 if DEBUG_MMP_UART2 > default 0xfe018000 if DEBUG_MMP_UART3 > @@ -1863,7 +1863,8 @@ config DEBUG_UART_VIRT > DEBUG_S3C64XX_UART || \ > DEBUG_BCM63XX_UART || DEBUG_ASM9260_UART || \ > DEBUG_SIRFSOC_UART || DEBUG_DIGICOLOR_UA0 || \ > - DEBUG_AT91_UART || DEBUG_STM32_UART > + DEBUG_AT91_UART || DEBUG_STM32_UART || \ > + DEBUG_STIH41X_ASC2 || DEBUG_STIH41X_SBC_ASC1 > > config DEBUG_UART_8250_SHIFT > int "Register offset shift for the 8250 debug UART" > diff --git a/arch/arm/include/debug/sti.S b/arch/arm/include/debug/sti.S > index 6b42c91f217d..a903a60b81c6 100644 > --- a/arch/arm/include/debug/sti.S > +++ b/arch/arm/include/debug/sti.S > @@ -6,28 +6,6 @@ > * Copyright (C) 2013 STMicroelectronics (R&D) Limited. > */ > > -#define STIH41X_COMMS_BASE 0xfed00000 > -#define STIH41X_ASC2_BASE (STIH41X_COMMS_BASE+0x32000) > - > -#define STIH41X_SBC_LPM_BASE 0xfe400000 > -#define STIH41X_SBC_COMMS_BASE (STIH41X_SBC_LPM_BASE + 0x100000) > -#define STIH41X_SBC_ASC1_BASE (STIH41X_SBC_COMMS_BASE + 0x31000) > - > - > -#define VIRT_ADDRESS(x) (x - 0x1000000) > - > -#if IS_ENABLED(CONFIG_STIH41X_DEBUG_ASC2) > -#define DEBUG_LL_UART_BASE STIH41X_ASC2_BASE > -#endif > - > -#if IS_ENABLED(CONFIG_STIH41X_DEBUG_SBC_ASC1) > -#define DEBUG_LL_UART_BASE STIH41X_SBC_ASC1_BASE > -#endif > - > -#ifndef DEBUG_LL_UART_BASE > -#error "DEBUG UART is not Configured" > -#endif > - > #define ASC_TX_BUF_OFF 0x04 > #define ASC_CTRL_OFF 0x0c > #define ASC_STA_OFF 0x14 > @@ -37,8 +15,8 @@ > > > .macro addruart, rp, rv, tmp > - ldr \rp, =DEBUG_LL_UART_BASE @ physical base > - ldr \rv, =VIRT_ADDRESS(DEBUG_LL_UART_BASE) @ virt base > + ldr \rp, =CONFIG_DEBUG_UART_PHYS @ physical base > + ldr \rv, =CONFIG_DEBUG_UART_VIRT @ virt base > .endm > > .macro senduart,rd,rx Reviewed-by: Patrice Chotard Thanks Patrice _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel