Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp286446iof; Mon, 6 Jun 2022 03:33:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwO7jzv6+ZEOLWy9qTCXxN1ugs4Gnemci8kW9Xvb8IHh8VU+5TIReVnBKMu5qL8RRFnGmBW X-Received: by 2002:a17:903:110e:b0:167:8847:5d9d with SMTP id n14-20020a170903110e00b0016788475d9dmr1782847plh.3.1654511607344; Mon, 06 Jun 2022 03:33:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654511607; cv=none; d=google.com; s=arc-20160816; b=VhbldBPPFLJwI4Cv9YfogFb9e3Zu9DBeUm7i0Ga4yhBX1ZcF6JyAguWKvG1zIWONHZ i1+gM62gfEY/Reg2FvefN9zjWYvTkVkJcii9XffDreU3P+UqcXblq8kCw6AZX0s8QaBc DnPLX3LM5zfZC6STJ/8USO21Qy/dm1b6Rl0Xz1u6A1hMvzM+pN0rm8PcieEEWd30rhqq 2UAOi6I0Hpvg0pJSgVSynyzzMBO/SY6GuWbn6E7Y/LyXr48S1e5Nwc7KlPbEIjhL/VFp xIbJnIkTH/37QNmWpfAEq2fLWO/MOIfRDTv8Vowjpe/dSSKQtbTD+l+eHjah8BpPPUW1 D5HQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=uHL1djXILTuBL3WMgTrE1NQqdRhhXCnprdLlAsX2nDA=; b=Zh/dReQa1jyx40BHF+1NyHLzCMfT5oMTUfS8kbXyv3C4B9yzXFBBIZZ5pMmuxIqbDb k0xMuFHFhteaPvPHG2bTfk532qt4UG4WWc2aLMaUfXQMPPe/D002lndSfoG9r+4gRg6Y xj+CAiV7BxBTv1btIa9uagA4lAB44Bgyiq2uMxkeh0bNAJ0b5jw6+hZkSXQ/qzRG/ukL 4LO9KCsjoPXMJVuFPGVohJKGNbKlzzKQucjnB4DC+Wv5BTae6BH9Au5RZmIzSeeseIxx yOFtqhaPI7pJhYuD1WpTujhnowU8Vdrs7ze8ktXBecDFoP3IiPLsw39l74Jxt4O35B9+ eLXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=GOzShFeE; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id g11-20020a170902d5cb00b001608b341d2csi6693578plh.124.2022.06.06.03.33.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jun 2022 03:33:27 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=GOzShFeE; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 887551E82B1; Mon, 6 Jun 2022 03:12:29 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233553AbiFFKJE (ORCPT + 99 others); Mon, 6 Jun 2022 06:09:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43002 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233351AbiFFKGJ (ORCPT ); Mon, 6 Jun 2022 06:06:09 -0400 Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9DFC3139C8A; Mon, 6 Jun 2022 03:06:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1654509968; x=1686045968; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=geGI3l4XWU1FlWu8pGiJvI1eL9aFCA+g7U3rNUsB2m0=; b=GOzShFeEAkEXygPApyTG3Yzr2buvwh6HsyVDwFalOcYb/ZJY82G8eAQg ue1XpHFEFyfP4jQfCHl3TurdK8rMNvXHWBXLKd2ZF5+nTyTIhH2avg+c4 bfJS+awo40LMRJawjK6IdG20BDBXct6GPYPTzi81FBvIIPCZRYkRLfA+H EQNaKYSj/b6SIQE8dACa0ith24dNxXMyKEjwjbyw7RB2IEvJljWp399Cs pDTYiIqZs/OOGo3gSx5yMZnYrbtkFW+6908YvJNDqRAH/+iqe7Uf/gcI6 RLMlrZ+4k8cU7R9512vbdNizJSke6wrDCh/LtdQtEJu3u2Xc9afzzH5UU w==; X-IronPort-AV: E=McAfee;i="6400,9594,10369"; a="362987081" X-IronPort-AV: E=Sophos;i="5.91,280,1647327600"; d="scan'208";a="362987081" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Jun 2022 03:06:08 -0700 X-IronPort-AV: E=Sophos;i="5.91,280,1647327600"; d="scan'208";a="635523839" Received: from amkossek-mobl1.ger.corp.intel.com (HELO ijarvine-MOBL2.ger.corp.intel.com) ([10.252.57.11]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Jun 2022 03:06:06 -0700 From: =?UTF-8?q?Ilpo=20J=C3=A4rvinen?= To: linux-serial@vger.kernel.org, Greg KH , Jiri Slaby , linux-kernel@vger.kernel.org Cc: =?UTF-8?q?Ilpo=20J=C3=A4rvinen?= Subject: [PATCH 26/36] serial: 8250_fintek: Remove serial_rs485 sanitization Date: Mon, 6 Jun 2022 13:04:23 +0300 Message-Id: <20220606100433.13793-27-ilpo.jarvinen@linux.intel.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220606100433.13793-1-ilpo.jarvinen@linux.intel.com> References: <20220606100433.13793-1-ilpo.jarvinen@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Serial core handles serial_rs485 sanitization and copying rs485 struct. Signed-off-by: Ilpo Järvinen --- drivers/tty/serial/8250/8250_fintek.c | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/drivers/tty/serial/8250/8250_fintek.c b/drivers/tty/serial/8250/8250_fintek.c index 6e98c376e082..1fb86c73786c 100644 --- a/drivers/tty/serial/8250/8250_fintek.c +++ b/drivers/tty/serial/8250/8250_fintek.c @@ -206,19 +206,7 @@ static int fintek_8250_rs485_config(struct uart_port *port, if (!(rs485->flags & SER_RS485_RTS_ON_SEND) == !(rs485->flags & SER_RS485_RTS_AFTER_SEND)) return -EINVAL; - memset(rs485->padding, 0, sizeof(rs485->padding)); config |= RS485_URA; - } else { - memset(rs485, 0, sizeof(*rs485)); - } - - rs485->flags &= SER_RS485_ENABLED | SER_RS485_RTS_ON_SEND | - SER_RS485_RTS_AFTER_SEND; - - /* Only the first port supports delays */ - if (pdata->index) { - rs485->delay_rts_before_send = 0; - rs485->delay_rts_after_send = 0; } if (rs485->delay_rts_before_send) { @@ -241,8 +229,6 @@ static int fintek_8250_rs485_config(struct uart_port *port, sio_write_reg(pdata, RS485, config); fintek_8250_exit_key(pdata->base_port); - port->rs485 = *rs485; - return 0; } -- 2.30.2