From patchwork Sun Jul 10 16:44:40 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lino Sanfilippo X-Patchwork-Id: 12912576 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 64316C43334 for ; Sun, 10 Jul 2022 16:46:56 +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=SHNk3YN3xC69S58a0FFskEjqqOkG9tw+J4wScR/+06s=; b=lpquOxOwKEf1GY yeCDakDbiTEr4VvwlRG+swvpRUsiGM5WfC2hd6kZMHEb7nVZQ8IS7WGkM5tgn650vktcN5nGYpf5T RfLueWXYuQ1V0zbfKNw/IQ0IRZzGtQ/KtIPz9QKOnxoH6JvfguXygwCeQcnwcfC8fk6YaFtMUiXTK M6OgyeNn7XhOsvV5au7zVqTsgEFc7FUIllfwbrrpZpB7k3r/n7NoohOSCjr8SMbrbDXamXpggOTCG HQovB4noo0fRH/X6A5wWTwH+Vy0tFIE4zR0aU15mcitmYDZbgEt+r9920akDzVQbIQ3IzGhI1o0Rg 9Nwim8/6AqQLeQU/uHYA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oAa45-00CXXE-P8; Sun, 10 Jul 2022 16:45:49 +0000 Received: from mout.gmx.net ([212.227.17.21]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oAa3P-00CXCZ-FX for linux-arm-kernel@lists.infradead.org; Sun, 10 Jul 2022 16:45:11 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1657471498; bh=MsWxBaLlxA4ELwYXkzuPt+y1986U/Jbrt8tDYt6WPtU=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=ePqk3UCYbWhcEREOfn2BmyXgqSXhiA4giff//b8To8GFdDdl7w/8Li5xm6UorodsM WlGlY+UqoPiVpp9pASd3SI4y9ppyA/WhYgXpc+9y/iytVZMA+EzP3dYDENd9IGK0Eq NSP43hhHPlV+8Pi2JsQDoauZC/n6QVP8S5Tz2RHM= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from localhost.localdomain ([46.223.3.243]) by mail.gmx.net (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MvbBu-1nKXjL3YcY-00sehu; Sun, 10 Jul 2022 18:44:57 +0200 From: Lino Sanfilippo To: gregkh@linuxfoundation.org, jirislaby@kernel.org Cc: ilpo.jarvinen@linux.intel.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, andriy.shevchenko@linux.intel.com, vz@mleia.com, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, lukas@wunner.de, p.rosenberger@kunbus.com, Lino Sanfilippo , Rob Herring Subject: [PATCH v4 6/8] dt_bindings: rs485: Correct delay values Date: Sun, 10 Jul 2022 18:44:40 +0200 Message-Id: <20220710164442.2958979-7-LinoSanfilippo@gmx.de> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220710164442.2958979-1-LinoSanfilippo@gmx.de> References: <20220710164442.2958979-1-LinoSanfilipp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BwhcwD595bR3NfPZ1aBpTJ26rv4BHvEAC80YEOQHoCeJ N3zROmEhqwwHiSRSikJyMe5L+/fCeyRrZuAzU3hNCZtAHMzQ9gz2Z2CkRo7OjRyPL3LIBPFVg wYOMY8K5DgIsUFGgdxoiS4d6Q6fbavyXLMDTcSA8gOI4cXsBWrQTe8g9yasmDH9KY/KuoGkGi UjRWZ1lPhrvBNpaDbeD+qfpMRPw23KnHHOIhLwbzXCvFUoctH0TiDRjwD3ZcnHlf9evGuK7cN UZr01oen8zpTL7RgFaP1oCt6l84DjBp/xUZWSCmLraGrWI7o/aZfY2fRhsHffqKaQlZHHh01Z D/TlArsNIXMrLY8BKMumZfi84Aj+7zzY1Ql4rtOoMfVENeOwg2WK7shFQ== X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220710_094508_189939_FD486170 X-CRM114-Status: GOOD ( 12.50 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Lino Sanfilippo Currently the documentation claims that a maximum of 1000 msecs is allowed for RTS delays. However nothing actually checks the values read from device tree/ACPI and so it is possible to set much higher values. There is already a maximum of 100 ms enforced for RTS delays that are set via the UART TIOCSRS485 ioctl. To be consistent with that use the same limit for DT/ACPI values. Although this change is visible to userspace the risk of breaking anything when reducing the max delays from 1000 to 100 ms should be very low, since 100 ms is already a very high maximum for delays that are usually rather in the usecs range. Signed-off-by: Lino Sanfilippo Acked-by: Rob Herring --- Documentation/devicetree/bindings/serial/rs485.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/serial/rs485.yaml b/Documentation/devicetree/bindings/serial/rs485.yaml index f2c9c9fe6aa7..90a1bab40f05 100644 --- a/Documentation/devicetree/bindings/serial/rs485.yaml +++ b/Documentation/devicetree/bindings/serial/rs485.yaml @@ -22,12 +22,12 @@ properties: - description: Delay between rts signal and beginning of data sent in milliseconds. It corresponds to the delay before sending data. default: 0 - maximum: 1000 + maximum: 100 - description: Delay between end of data sent and rts signal in milliseconds. It corresponds to the delay after sending data and actual release of the line. default: 0 - maximum: 1000 + maximum: 100 rs485-rts-active-low: description: drive RTS low when sending (default is high).