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 3B38CC072A2 for ; Wed, 22 Nov 2023 08:43:16 +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:Cc:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=yNqhW7FsPNX72XpUYwdPFCWf0E8lnEEgwNzrXLN6OHo=; b=D0uecIrIGRhoUr Sk5Vhr6chN3aEy0pF78zL51XlsMAeNN/Z7fC1g1yoNiBV+MJR7rtYUbmaNO6pqfKSQckPZ4+LojOq FmTFbnOrHEbCAM4TfRTxLRtvPYmK+/nSTeoUmsqTH4oZVCyDv4jn9EVTdlfKkqRM8uH45l0iLVInc y5g1KTt6MlAe0zsuQEiMMXuDWktxwU7KLKZKdf/ONu5VKxIhA1uSQ9hvz5jmdlidCnAdliCoqc5/D 8REl6V1K0u0a9Utswvrvz0GwA8ff7ryUEb57XDTPn/L0Xu3DDACSaOkxb/doSvRyDgi3KzrbwJzHQ cCMqnZG9W/o00kY5MmDg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1r5iov-0015jD-2l; Wed, 22 Nov 2023 08:42:53 +0000 Received: from mail-qv1-xf29.google.com ([2607:f8b0:4864:20::f29]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1r5iot-0015ih-2J for linux-arm-kernel@lists.infradead.org; Wed, 22 Nov 2023 08:42:53 +0000 Received: by mail-qv1-xf29.google.com with SMTP id 6a1803df08f44-678013cc22bso24997376d6.2 for ; Wed, 22 Nov 2023 00:42:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1700642570; x=1701247370; darn=lists.infradead.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=xJJJ00lRDiFcS8bTCcGfNaw9iOLVdZbPikVW1utuBzM=; b=wjyX+ZCUOXxpahrHAwrBMK4Uuo+Ee5fN+no2GIdwyqksHINZ6aTHw0ViynIWn5c9pK kzgZB4hGtvO9E2TlMLmPXq6LzhxlG5bTFTJOWnLBr8nzTIRwWRlyE4KCLorFeBlvvhMK ifIbYqvzHkxn27XnbzBANGn4P9pZEpN5S1Eng/RnrIkiY0tvvm+CchEfI/sZCl/x80fU 2F+QFTY6mbUukvgEn2ljTF8dkutjpffvlrxe/37aksb9/3qnvAAwNlpCQcamN5nEBICp zdIrqj+xbVBSTzuDDF+QK8WzCLQt4Kx/LjvwkTe1dhRHiklo+kTaYbuCN8lmn2AtsWM1 DbUA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700642570; x=1701247370; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=xJJJ00lRDiFcS8bTCcGfNaw9iOLVdZbPikVW1utuBzM=; b=ICW0qlxlzGmONZ0f9mkZ1nnMxhecmhbwFA1j4hu9gwXYd94zg8y/xTBhRPByjyvH1s Br4CwfzqTcpttUZlJqdIsbZG9TYoQm5k9zcKvb6CUkjA9UznkmFMJJCdUEWd0PWfFsiT 8++Ar4AvWyLAUytj8sPZ6mqu7+JmSaGusEmduacc5gITnGZddTvxso7p0dD63OR4eJHa +gj+KdCBcs/diUzh7tM2Zcr4cPMZWCFvysBYL92ojBZ5qZuRwO379cabHnStmVLjoYMp V93nCzZNAsygAXv5UknB1kb84BHEz4+BvWWuJuxwrDaLoeKFv04PbEmJUWSZEWGp4/T4 Gf2g== X-Gm-Message-State: AOJu0Yym+6o6Ln2wL2qHQCZTVWoytdNMLbVKBmMIF7bzjyIjcbVu4xtI BxFYGc3q9a7vp/kPt2xS8i4e5Q6F8fqyBw5uKJh6nA== X-Google-Smtp-Source: AGHT+IGuE4s7BTtl86J4aY1Nuyr+QChlQ+/ghmDxMJ+Qpji0VOMTRWww7BDliDBXUH4jhsBEXFzcxCwrF5hxCi4U9KY= X-Received: by 2002:a05:6214:f6c:b0:64f:92af:9080 with SMTP id iy12-20020a0562140f6c00b0064f92af9080mr1950970qvb.21.1700642569839; Wed, 22 Nov 2023 00:42:49 -0800 (PST) MIME-Version: 1.0 References: <20231120212037.911774-1-peter.griffin@linaro.org> <20231120212037.911774-10-peter.griffin@linaro.org> <20231121151630.GA1692178-robh@kernel.org> <35990cd2-a4d3-473e-893e-aa16c1c63289@linaro.org> In-Reply-To: <35990cd2-a4d3-473e-893e-aa16c1c63289@linaro.org> From: Peter Griffin Date: Wed, 22 Nov 2023 08:42:37 +0000 Message-ID: Subject: Re: [PATCH v4 09/19] dt-bindings: serial: samsung: Make samsung,uart-fifosize required property To: Krzysztof Kozlowski Cc: Rob Herring , krzysztof.kozlowski+dt@linaro.org, mturquette@baylibre.com, conor+dt@kernel.org, sboyd@kernel.org, tomasz.figa@gmail.com, s.nawrocki@samsung.com, linus.walleij@linaro.org, wim@linux-watchdog.org, linux@roeck-us.net, catalin.marinas@arm.com, will@kernel.org, arnd@arndb.de, olof@lixom.net, gregkh@linuxfoundation.org, jirislaby@kernel.org, cw00.choi@samsung.com, alim.akhtar@samsung.com, tudor.ambarus@linaro.org, andre.draszik@linaro.org, semen.protsenko@linaro.org, saravanak@google.com, willmcvicker@google.com, soc@kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-clk@vger.kernel.org, linux-gpio@vger.kernel.org, linux-watchdog@vger.kernel.org, kernel-team@android.com, linux-serial@vger.kernel.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231122_004251_757603_A816110A X-CRM114-Status: GOOD ( 43.23 ) 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="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 Krzysztof, On Wed, 22 Nov 2023 at 07:49, Krzysztof Kozlowski wrote: > > On 21/11/2023 18:15, Peter Griffin wrote: > > Hi Rob, > > > > Thanks for your review. > > > > On Tue, 21 Nov 2023 at 15:16, Rob Herring wrote: > >> > >> On Mon, Nov 20, 2023 at 09:20:27PM +0000, Peter Griffin wrote: > >>> Specifying samsung,uart-fifosize in both DT and driver static data is error > >>> prone and relies on driver probe order and dt aliases to be correct. > >>> > >>> Additionally on many Exynos platforms these are (USI) universal serial > >>> interfaces which can be uart, spi or i2c, so it can change per board. > >>> > >>> For google,gs101-uart and exynosautov9-uart make samsung,uart-fifosize a > >>> required property. For these platforms fifosize now *only* comes from DT. > >>> > >>> It is hoped other Exynos platforms will also switch over time. > >> > >> Then allow the property on them. > > > > Not sure I fully understand your comment. Can you elaborate? Do you > > mean leave the 'samsung,uart-fifosize' as an optional property like it > > is currently even for the platforms that now require it to be present > > to function correctly? > > > > I deliberately restricted the yaml change to only require this > > property for the SoCs that already set the 'samsung,uart-fifosize' dt > > property. As setting the property and having the driver use what is > > specified in DT also requires a corresponding driver update (otherwise > > fifosize gets overwritten by the driver static data, and then becomes > > dependent on probe order, dt aliases etc). The rationale was drivers > > 'opt in' and add themselves to the compatibles in this patch as they > > migrate away from obtaining fifo size from driver static data to > > obtaining it from DT. > > Your code diff looks like you are adding the property only to these models. OK, I intended to only make it a required DT property for these models. Presumably there is a better way to achieve that. > > > > >> > >>> > >>> Signed-off-by: Peter Griffin > >>> --- > >>> .../bindings/serial/samsung_uart.yaml | 17 +++++++++++++++++ > >>> 1 file changed, 17 insertions(+) > >>> > >>> diff --git a/Documentation/devicetree/bindings/serial/samsung_uart.yaml b/Documentation/devicetree/bindings/serial/samsung_uart.yaml > >>> index ccc3626779d9..22a1edadc4fe 100644 > >>> --- a/Documentation/devicetree/bindings/serial/samsung_uart.yaml > >>> +++ b/Documentation/devicetree/bindings/serial/samsung_uart.yaml > >>> @@ -133,6 +133,23 @@ allOf: > >>> - const: uart > >>> - const: clk_uart_baud0 > >>> > >>> + - if: > >>> + properties: > >>> + compatible: > >>> + contains: > >>> + enum: > >>> + - google,gs101-uart > >>> + - samsung,exynosautov9-uart > >>> + then: > >>> + properties: > >>> + samsung,uart-fifosize: > >>> + description: The fifo size supported by the UART channel. > >>> + $ref: /schemas/types.yaml#/definitions/uint32 > >>> + enum: [16, 64, 256] > >> > >> We already have 'fifo-size' in several drivers. Use that. Please move > >> its type/description definitions to serial.yaml and make drivers just do > >> 'fifo-size: true' if they use it. > > > > What do you suggest we do for the samsung,uart-fifosize property that > > is being used upstream? > > Nothing, your diff is just wrong. Or at least nothing needed. Just drop > all this properties: here and only make it required for Google GS101. OK, so your happy with the approach just not the implementation/patch and you don't want it updated to use fifo-size instead of samsung,uart-fifosize > > > > > >> > >>> + > >>> + required: > >>> + - samsung,uart-fifosize > >> > >> A new required property is an ABI break. Please explain why that is okay > >> in the commit message. > >> > > > > I can update the commit message to make clear there is an ABI break. > > As mentioned above the platforms where this is now required are either > > already setting the property or are new in this series. Is that > > sufficient justification? > Yes, but only first case. You need to order your patches correctly - > first is ABI break expecting ExynopsAutov9 to provide FIFO size in DTS > with its explanation. Second commit is adding GS101 where there is no > ABI break. OK, I'll drop the ExynopsAutov9 part then. I don't want to complicate this series by introducing an ABI breakage on some other unrelated Exynos platform. Peter _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel