From patchwork Sun Jul 10 15:03:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lino Sanfilippo X-Patchwork-Id: 590020 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 30A1ECCA480 for ; Sun, 10 Jul 2022 15:04:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229636AbiGJPEI (ORCPT ); Sun, 10 Jul 2022 11:04:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57536 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229563AbiGJPDz (ORCPT ); Sun, 10 Jul 2022 11:03:55 -0400 Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 694206552; Sun, 10 Jul 2022 08:03:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1657465412; bh=AdWDe6Q5QpRDiXyrdxp/60gdvK8IQ697veYdYB+5CPw=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=RpDQmP9YpKA3kZJbp2nBYOA8WtEtCb+ZCafnb3qhJttYtVM1UlLmyID40TdkH8BhM FOS78SiPO674Vz7f9FQvUBtc+hGE56XwCU++wYVYY3kjdnWW2vHCnWhvPmWv7YnIq4 5hYhtjHJTHlYF4z+5XQPFj/cGCEFnggMxAnBO9iM= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from localhost.localdomain ([46.223.3.243]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MSt8W-1nzzoL3KHO-00UKK3; Sun, 10 Jul 2022 17:03:31 +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 v3 6/8] dt_bindings: rs485: Correct delay values Date: Sun, 10 Jul 2022 17:03:20 +0200 Message-Id: <20220710150322.2846170-7-LinoSanfilippo@gmx.de> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220710150322.2846170-1-LinoSanfilippo@gmx.de> References: <20220710150322.2846170-1-LinoSanfilippo@gmx.de> MIME-Version: 1.0 X-Provags-ID: V03:K1:yJi8p2NgxKQ8FKq06j2HKJzfUCvFcCx+6G4JpaRdHQrk8vklqVq lFC1SiKRhr7xeyGLdAfLc95ybCifFXnM+72ScdGZueBY1rmd4DIkdfMnqTq3Ep+uFMD586X YFLV2NbYXbQBRPPbLheiHCyZ/PVjeAJ9eCY7DkrYv6rreMlnlqII/fEBlwM04Jkh+GtFbJk wtI3rzaRYGOMrHTr8l8yw== X-UI-Out-Filterresults: notjunk:1;V03:K0:5SmAIpv7yMk=:tEAeLMKY7NmT+XfzJj9Hu5 hwBVsIRn2eI7//D+ZOZ6ZmDO0dssPPpv3Phy8hEPIBdFquyv/ecR/zCZXRXFb7SyfkEyKoGV2 bLKE6X1YZxPCLi88ON/dituSvUjsN8yq48FJr5Q6ZXMYcpE41FYD0IWdhuLzDLQkTu0GrUYvF +qRV3nf0pYInsGbRVrbiuixWtck76W0VZmfeuF7nFARhr9r7k69pHQRT23CqYSzemJXEJdN+3 AOy3NCie05wzoLQlEPsBq17pIHRh1GeHwoB8wTsymb6EUGkYmFv9R8a6wO2RJemScdSmtOPfr S5BTzpeMCG5NCovFq9Ginr55mgvcn9qzZjV2XoI+zMBkB2/Y2PQYiqKkLX4cxEVyFyucXt2+z VVZI42+kzORSW01iCrW9mLgqKoO37lMjkbi6Fssq46Y9zStDFNHxowPHuy3dsctxBWw28YEHU tsAlO1UDSpwiTVyyq8oCb0xBa4ODtqfIB3XePu76Mgu8eq59ytDJiIK+O0K16xyi4bXH/nED9 10/3/eHmmCdUAUL5XGq9jbbpt8SsOTi1mYZsqVh7TISmOPNGqoFycm7CXO3RX5VBx2uwCUP1Y GMKbxzpwD/TySOUMe57zNsTZh/BwyhNGKcdYi19n203ZOo0TusIm70l3aANB1Vi6qguPwPQe9 JVg5dQ7JMjNp7U1Z/SLZmhsW1wiClEfRRwrrZNT1unfoOA1urKu6s6bdfKOkM+6LGqN7a5+ox P0eDRfDJwwk2wgdXxI5O7zP+dYAYJndD8Ym/eD/D/L8D6J/tsY9BKyF+Y5fAuBDQ3Ml6I33rX DMwUN9dhv24UvTH9oOLDtFCYPXdoYoFQZuSJr5soSdWSmkmd1VrVgw+HnHRa7DXjlRzcDmHU7 m2cBYrigKZy+cVEtDxjNCrW3GLlGhHCH8FxZHBwpZDm/9PEGOT99//9iRKt+Ik+hNxJBMfFHj KQ0lthjHs1O24SGddWAzqJhMtlBAVdXcbxOCpHs8FkZri2//ln5X0Pff2Fnvk8fpV32zibe9O WK1gKYj0CEz/GoN9pMWSSwiH0M4ig9QyNBIRl/Hi/UX0ygM/5cDOWpSHC9G+sPzVatYixPFa7 UGReiGg37X3D8DUx1HLKUKXT7Y3tbZS3Tagzxr1ivCHc1yC3z/2roAG+g== Precedence: bulk List-ID: X-Mailing-List: linux-serial@vger.kernel.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).