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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 603AEC4167B for ; Fri, 1 Dec 2023 21:03:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=N95ATwKdqO73w2Q0nHX6K78ifHLgL64WYQvJKlB3cs0=; b=VeyK1aynM/0EPe ie6aDJbB6Ef1VJlD+dazD1WRV8QNhbLGFte8L8Kgt2T/iyoN1IGPap4QGDCRIbrVjMzskolYOR42k DrQP7ycRBG/H7eMSQXX6lkZxbLK3OuLYpLTp+XIMyXmtpiiC1/1p5CqGeTJEfn+9lVw2zOZRBm3Oo l0BapBR6mmBxxPNiSfCfsjQ3t1gn71gQHycMLO2uujQdqIra8p1HwcU9cCO+cKoL1UuNPfecWQVx9 ha37D4jsHEJL4BsZOc344FwQIoXvggdAhNjiUdRX0NGbMzutLpjfyCP3Y9CPP7Ezg2i4wDWwx2o8b 2Zx/8+MDCFugE0Bp4cLg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1r9AfL-00Ediz-23; Fri, 01 Dec 2023 21:03:15 +0000 Received: from gloria.sntech.de ([185.11.138.130]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1r9AfI-00EdiO-0w; Fri, 01 Dec 2023 21:03:13 +0000 Received: from i53875b61.versanet.de ([83.135.91.97] helo=diego.localnet) by gloria.sntech.de with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1r9AfE-00031l-UN; Fri, 01 Dec 2023 22:03:08 +0100 From: Heiko =?ISO-8859-1?Q?St=FCbner?= To: Florian Fainelli , Francesco Dolcini Cc: linux-rockchip@lists.infradead.org, Francesco Dolcini , linux-arm-kernel@lists.infradead.org, quentin.schulz@theobroma-systems.com, Heiko Stuebner Subject: Re: [PATCH] arm64: defconfig: Increase SERIAL_8250_NR_UARTS to 10 Date: Fri, 01 Dec 2023 22:03:07 +0100 Message-ID: <3923943.BzM5BlMlMQ@diego> In-Reply-To: <4075500.2IRrRt1zHL@diego> References: <20231201191228.343230-1-heiko@sntech.de> <4075500.2IRrRt1zHL@diego> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231201_130312_326132_5EAC0BD2 X-CRM114-Status: GOOD ( 34.29 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Am Freitag, 1. Dezember 2023, 21:56:27 CET schrieb Heiko St=FCbner: > Hi, > = > Am Freitag, 1. Dezember 2023, 21:09:29 CET schrieb Francesco Dolcini: > > On Fri, Dec 01, 2023 at 11:57:53AM -0800, Florian Fainelli wrote: > > > +Francesco, > > > = > > > On 12/1/23 11:12, Heiko Stuebner wrote: > > > > From: Heiko Stuebner > > > > = > > > > Boards using socs like the rk3588 can use up to 10 uarts, so the de= fault > > > > of 4 is way too low. Therefore increase the maximum number to 10. > > Do you have an actual need of 10, e.g. an existing board with 10 uarts > > enabled supported by the mainline kernel? Just thinking at the last arm= 64 SoC I > > am working with it should be 12 if we use this as a metric. > = > The rk3588 can do 10 (0-9), the board I'm working on is using up to uart7= (aka 8 uarts). > Reasoning below in the 3rd paragraph. > = > = > > > > SERIAL_8250_RUNTIME_UARTS on the other hand describes the number of= uart > > > > data structures to prepare before registering them. This option can= stay > > > > at its default value of 4 since for one it can be changed via a boot > > > > parameter 8250.nr_uarts but also since > > > > commit 9d86719f8769 ("serial: 8250: Allow using ports higher than S= ERIAL_8250_RUNTIME_UARTS") > > > > = > > > > the kernel can register uarts dynamically that are above the > > > > SERIAL_8250_RUNTIME_UARTS threshold. > > > > = > > > > Signed-off-by: Heiko Stuebner > > > = > > > There is a competing patch set from Francesco being submitted as well: > > > https://lore.kernel.org/all/20231201171544.1901-1-francesco@dolcini.i= t/ > > > > > > looks like some coordination is necessary. > = > Thanks Florian for catching this coincidence. > = > = > > Yep, thanks Florian. > > = > > Heiko: should I include your needs in my patch? It looks like these are= the > > days of the 8250 uart, I sent my patch just one day before yours. > = > yeah, I was surprised by the time overlap as well. > = > After reading up on NR_UARTS and NR_RUNTIME_UARTS I opted for going with > the maximum possible. > = > From what I understood, increasing the runtime-uart-number would incur > overhead in terms of prepared data structures. But the core NR_UARTS > only seems to limit the actual maximum number of uarts in the system. > = > With the somewhat recent patch named above, even those can still be > registered without bad effects, so I opted with increasing the NR_UARTS > to the maximum to expect at some point, least the next board then needs > yet another patch. > But left the runtime number alone to not create overhead. > = > = > So TL;DR: > I could live with the 8 from your original patch, but I guess would prefer > going with a safer value, so the 10 or your 12 from above. > = > Because I guess if a controller is present, someone will use it > eventually ;-). and looking at other rk3588 boards the indiedroid-nova actually uses the uart9 (aka the 10th uart) ;-) Also the turing-rk1 and orangepi-5-plus as well. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel