Received: by 2002:a05:6358:51dd:b0:131:369:b2a3 with SMTP id 29csp884610rwl; Thu, 10 Aug 2023 03:14:26 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFswLvmZZ7pjkBwSAQh1o3l7Ut2N1Wie8MaMvoA2QKCIZihHnMpmL971eZbIhg5L+b7E3pX X-Received: by 2002:a17:903:182:b0:1b2:1b22:196 with SMTP id z2-20020a170903018200b001b21b220196mr2052191plg.48.1691662465690; Thu, 10 Aug 2023 03:14:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691662465; cv=none; d=google.com; s=arc-20160816; b=cKWh4UrHhgDfckCi2Lt+dtarE4bvbHMxqUjuWNUL82U3DUDz5GPIbhNUUjhX5Fvgxb JDpn6fOCS135RirlYqzao9iR0ilXK3BUTCZpN/PfViFuxarkVafWBXhXwjd9k01UlhnK CXdD1UbwjQc3QBQSeM0s1vu5IqC5LTnybOJbkdpFv52THewznpyHx+hkYDi2LARfycv0 HtKTeMjBKfuluCCLwbhzmP0GjPwg/TVEmJJv4dkxi/TSMNKU+LGYK+ZfBwqJOvkHKNfr Wq09VDAsp6kLaYWmhjDVZzv/cTAi0RHdPVMUXfaUBGo/APVXuFAZcgqkZOIo9KH9LCAT kuog== 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=3QmTgLkfQxZeAfr1GTyP9IONdmCDZln1oW6d4uGANZw=; fh=k7XzfpyqnKqnwxpqVF0NftrWa2FIpeAcHVbykF5xarA=; b=iaZ/IeA/eEnmR8uxGjkMhWIGTYWnH2wIVVr4I7FMWSz2COchblB2Kn4xRDvt6hY0qO K4oYHz4n4KOBygeVyzkhPw4GKxgTzSaeVDdd0dZvRRQd9kBuafLXsj0c0rYff1N6dVi4 KjAOA7AiEH64jzFB+N+b3np4yokWSx/J+cQPp4DBcqs98Gh0ka6uyWqwdf/QGwxazXOX 0ahLTuU8N7ScUHOdVKZJkarVVYItO8z9TV/vEJjNuRIislJEGXRhk1yXxacEkXqGo+z0 0ULeiAOdVR2qAtRaX/6JgHJsKnL51wEp+SwM2k06yeHDELMFOc60sLw8iHKGnrt4S+pz xIDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=RzPv3J2J; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a8-20020a170902ecc800b001b39e50bfdasi1248235plh.638.2023.08.10.03.14.13; Thu, 10 Aug 2023 03:14:25 -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=pass header.i=@kernel.org header.s=k20201202 header.b=RzPv3J2J; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234764AbjHJJP6 (ORCPT + 99 others); Thu, 10 Aug 2023 05:15:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44252 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233139AbjHJJP0 (ORCPT ); Thu, 10 Aug 2023 05:15:26 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F15F6268C; Thu, 10 Aug 2023 02:15:25 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 8697F60BEF; Thu, 10 Aug 2023 09:15:25 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DBB10C433C9; Thu, 10 Aug 2023 09:15:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1691658925; bh=zzD47U2fiJ7atwg2ABdKRzZ/x41eZ5wq4Z5hTh7sf/I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RzPv3J2JOYMcq4zEIe3BKCs5R10ADkxsGRMhTIx4oOoK53k9NQLmKM3x5eAtPg260 EMQZKGvv4KfXvl6bD/5J/sJPiULlEElLfDb3JwIgDgThwUBZs+wdwhPccr3hhnF89w Jjb3BKw9wJAAf0tS4EFZkuLSJVI7dST/7EW2eHPgpeWaJjLF5d09olRtG/fU8SNEmh 56jne+kgCUfhbRMvcDn9vFcZBblyVeFMbUCmLDBtLM8y6aF41gtmIQ6cggdD7Qs5ty uxK6Y7pSWTfrYWHPQmRtfz5aOROPmlEsEdabN4OiHUmtf6Zk0oc304jl4HiiNtp/4K pJmJflvio4ZMw== From: "Jiri Slaby (SUSE)" To: gregkh@linuxfoundation.org Cc: linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, "Jiri Slaby (SUSE)" Subject: [PATCH 06/36] tty: tty_port: rename 'disc' to 'ld' Date: Thu, 10 Aug 2023 11:14:40 +0200 Message-ID: <20230810091510.13006-7-jirislaby@kernel.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230810091510.13006-1-jirislaby@kernel.org> References: <20230810091510.13006-1-jirislaby@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 Line discipline variables are named 'ld' all over the tty code. Rename these in tty_port, so that it is easier to grep for the code (namely for "ld->ops"). Signed-off-by: Jiri Slaby (SUSE) --- drivers/tty/tty_port.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/drivers/tty/tty_port.c b/drivers/tty/tty_port.c index a788a6bf487d..cda33dec73c3 100644 --- a/drivers/tty/tty_port.c +++ b/drivers/tty/tty_port.c @@ -26,19 +26,19 @@ static int tty_port_default_receive_buf(struct tty_port *port, { int ret; struct tty_struct *tty; - struct tty_ldisc *disc; + struct tty_ldisc *ld; tty = READ_ONCE(port->itty); if (!tty) return 0; - disc = tty_ldisc_ref(tty); - if (!disc) + ld = tty_ldisc_ref(tty); + if (!ld) return 0; - ret = tty_ldisc_receive_buf(disc, p, (char *)f, count); + ret = tty_ldisc_receive_buf(ld, p, (char *)f, count); - tty_ldisc_deref(disc); + tty_ldisc_deref(ld); return ret; } @@ -47,20 +47,20 @@ static void tty_port_default_lookahead_buf(struct tty_port *port, const unsigned const unsigned char *f, unsigned int count) { struct tty_struct *tty; - struct tty_ldisc *disc; + struct tty_ldisc *ld; tty = READ_ONCE(port->itty); if (!tty) return; - disc = tty_ldisc_ref(tty); - if (!disc) + ld = tty_ldisc_ref(tty); + if (!ld) return; - if (disc->ops->lookahead_buf) - disc->ops->lookahead_buf(disc->tty, p, f, count); + if (ld->ops->lookahead_buf) + ld->ops->lookahead_buf(ld->tty, p, f, count); - tty_ldisc_deref(disc); + tty_ldisc_deref(ld); } static void tty_port_default_wakeup(struct tty_port *port) -- 2.41.0