Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp3216930rwd; Mon, 29 May 2023 07:18:54 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7DYuNzrFLx6cWWP9+sc2e/AXXC8jlA4w5tTYc4nQluXk0xJiZYwINDeNYAnioFctgD1M5K X-Received: by 2002:a17:902:c94a:b0:1af:e2f2:1cce with SMTP id i10-20020a170902c94a00b001afe2f21ccemr14748356pla.38.1685369934104; Mon, 29 May 2023 07:18:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685369934; cv=none; d=google.com; s=arc-20160816; b=psnjvdoRs0QoG0ogvk5uHClwO0BlLlF9hFzlR/3MAwaYx0kQ9MiGoyBQDkzeuTZ6OW We3qcFGiwUxlgTGht8+d6j4UMMU89bIOaIRQVRaZQPpiLoTPyFpBLhJGeCbxF3VsK6qu l+mFepGqQbTAV3h737ArSNytnBECryNuJFLhkHFENLqRTlsDh2AADNufxg22HeHyPy4G SY4HFgWyaPu8Si7dGcn5gEXx3GQJ691TegYQPwlvnLM1nbAeBLxHbeSxcriMwrAT7cmt FV9Kw8t+bnIskGy+uG9WngGHMTmSTrxPgF6krBm2pnSUQVHzcor4BbQFGYRdQJf04oWg qAyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:subject:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:cc:to:from:dkim-signature; bh=fc4FhhujNpwaqbn8hNhuyb4eRPa/1T5Kc38omDT24E8=; b=iUj5OdrJPNFRuxizhmYLJp831lFP+0fchn8egrZPJisNMmkq7w+NYcohOfb/mvWwjj H81itAmkSEOh6LYGGPSkwgRIRAt3SajmdKWOQrUdyJiDScCGtK+TEWNBNWznawPO7yd2 97MXUOhw5Ns2AGs7fxBcFlLjAU92zeRRhyZLMOKXeHePAw4SjldtPY7xIVoNnVt8Jke4 hhOCU57gkDjgVbFAt2firM0FLGSjhtoE/p5CdN92YIscjoIWjL7mTBVY7javEvv6XVb/ 9+1Yrc08UvH1NoFEkfb5wU1tbs6rDNdi/1dcO6yX0a87rKxazZ4wmXJ45VsJSzbBmbfo wDuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@hugovil.com header.s=x header.b=CEdfqXUy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a18-20020a170902b59200b001a64fa4eb27si9462035pls.230.2023.05.29.07.18.38; Mon, 29 May 2023 07:18:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@hugovil.com header.s=x header.b=CEdfqXUy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230315AbjE2OIS (ORCPT + 99 others); Mon, 29 May 2023 10:08:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49762 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230341AbjE2OH7 (ORCPT ); Mon, 29 May 2023 10:07:59 -0400 Received: from mail.hugovil.com (mail.hugovil.com [162.243.120.170]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E19E212A; Mon, 29 May 2023 07:07:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=hugovil.com ; s=x; h=Subject:Content-Transfer-Encoding:Content-Type:MIME-Version: References:In-Reply-To:Message-Id:Date:Cc:To:From:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=fc4FhhujNpwaqbn8hNhuyb4eRPa/1T5Kc38omDT24E8=; b=CEdfqXUyP58G/d5VWU4r+OLwDb HmIyUfNkMT81zJuJxXOQ1Q1fcwq4HwGUez9ovSOfMpuGp20WeK6jOYrY1hHVIuzjUZSDMlbDrTo7n dN/1nLOMLBMHb/tynStuFkZcbkTEF9AxwejIDooH64PSLKxIo0HYDIiIMBchJywN9tFc=; Received: from modemcable168.174-80-70.mc.videotron.ca ([70.80.174.168]:50024 helo=pettiford.lan) by mail.hugovil.com with esmtpa (Exim 4.92) (envelope-from ) id 1q3dX4-0004Ht-UK; Mon, 29 May 2023 10:07:35 -0400 From: Hugo Villeneuve To: gregkh@linuxfoundation.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, jirislaby@kernel.org, jringle@gridpoint.com, l.perczak@camlintechnologies.com, tomasz.mon@camlingroup.com Cc: linux-serial@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, hugo@hugovil.com, linux-gpio@vger.kernel.org, Hugo Villeneuve , =?UTF-8?q?Ilpo=20J=C3=A4rvinen?= Date: Mon, 29 May 2023 10:07:10 -0400 Message-Id: <20230529140711.896830-9-hugo@hugovil.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230529140711.896830-1-hugo@hugovil.com> References: <20230529140711.896830-1-hugo@hugovil.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 70.80.174.168 X-SA-Exim-Mail-From: hugo@hugovil.com X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 Subject: [PATCH v4 8/9] serial: sc16is7xx: add call to get rs485 DT flags and properties X-SA-Exim-Version: 4.2.1 (built Wed, 08 May 2019 21:11:16 +0000) X-SA-Exim-Scanned: Yes (on mail.hugovil.com) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hugo Villeneuve Add call to uart_get_rs485_mode() to probe for RS485 flags and properties from device tree. Reviewed-by: Ilpo Järvinen Signed-off-by: Hugo Villeneuve --- drivers/tty/serial/sc16is7xx.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/tty/serial/sc16is7xx.c b/drivers/tty/serial/sc16is7xx.c index 34739b31b44b..b305142e9e9c 100644 --- a/drivers/tty/serial/sc16is7xx.c +++ b/drivers/tty/serial/sc16is7xx.c @@ -1513,6 +1513,10 @@ static int sc16is7xx_probe(struct device *dev, goto out_ports; } + ret = uart_get_rs485_mode(&s->p[i].port); + if (ret) + goto out_ports; + /* Disable all interrupts */ sc16is7xx_port_write(&s->p[i].port, SC16IS7XX_IER_REG, 0); /* Disable TX/RX */ -- 2.30.2