Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp2137476iof; Tue, 7 Jun 2022 21:00:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz6ODiba7QxOWZsR5no5A0wajzBCKBJfiAutR9fjk+YPVCaV+UnNTwnHLd/REo+Xc1fcMl/ X-Received: by 2002:a63:d94b:0:b0:3fc:8486:2a6 with SMTP id e11-20020a63d94b000000b003fc848602a6mr27577821pgj.23.1654660853992; Tue, 07 Jun 2022 21:00:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654660853; cv=none; d=google.com; s=arc-20160816; b=sYnyKWfXNf9i2KC5Lyl0JrPQM80OOOwbG3/JHyoZs5izb4k14j5vEwnptpeP7H3oLf 0OHk5/Gh0o6rHNHYyV/VimBTjbzvX1A4vatHtVZbX5ALZadZ3rgzaie0b1cYsBMM4G1s kgg0//U3l81quA4EYPv/V9PYRNzuhiG91EwIqM8Y9QEMOs/HwKabU8ObzfNpEcyRcNmC 4VhcrMpG7GeLPvNKYFHMNlgWlO/y8MR6uUKY65IBHA6AUa9PXIwU2RYA5iMbUrzbL8RK n6+FjBmKBgiLEMZB6gxV3eRJUWwXlJEZ5hpF4yJeFH1qTZrPeZedqrwOovHc1tFJfNEn /ISg== 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:dkim-signature; bh=y6rYC/CnQIfkHcFZ5s1nOOIXYEtc5snTgHSN/9EO6X8=; b=gG+yC+NMhXWC96aH3fcctai/eyM0HDHrNvJ2hfdOK2NSUL7O3XPyWP3JwH3AX1cD7M 1wkhjsRkLb3PhBBsUNe8lFTqXnzkbGwrAwMsSwves281NTOqa2RMJ4FJ6fvAVrWQsxeE lsnMaq3WcW+SXD0T/Bmusu0ncVTIAnQsJhksyxGBeGc7RYPiieA4sS4qQ5XSpp4CM5Pc Z8xYwDy2CvAa6YC6DrE6aCMYJBmhdE//XOpg+qUa7SDBUAoN4/TL0ivOGGqUMqk7oI57 DSZuuWv0auaG6U7F2Cwy2Kr1iuaT/+ojc4pv7fmCRAaPCaxASXs3qDY9D9itv51WGPYR ++ww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=MlDWf9xx; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; 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 Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id z22-20020aa78896000000b0051c29c6571bsi8280899pfe.203.2022.06.07.21.00.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 21:00:53 -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=@suse.cz header.s=susede2_rsa header.b=MlDWf9xx; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; 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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 73FEE1B1754; Tue, 7 Jun 2022 20:37:30 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242050AbiFGKwa (ORCPT + 99 others); Tue, 7 Jun 2022 06:52:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42740 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242318AbiFGKuK (ORCPT ); Tue, 7 Jun 2022 06:50:10 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 82C94F5D37; Tue, 7 Jun 2022 03:49:54 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id A28E921AE4; Tue, 7 Jun 2022 10:49:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1654598992; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=y6rYC/CnQIfkHcFZ5s1nOOIXYEtc5snTgHSN/9EO6X8=; b=MlDWf9xx+1voFmpNAyLZFNYscerqOGUkUUZWVGG5ikkpe+aBHmCAwerktW4LZ8Gi/ovTZm jngLY3CJ8qwbco5HbGFaO1SEV15c0izvMKucGIa8KNFBzWazOfoYf9ewnVbUjcDZkCSLHJ 18zGgEbUcMFdVRk8Jeoe56rsKdl28dE= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1654598992; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=y6rYC/CnQIfkHcFZ5s1nOOIXYEtc5snTgHSN/9EO6X8=; b=KQHyuMVzSQB1ubNYs/Icy/HFPpdig+T1oRG4Hy559MBvNvzCXvELPDPzR9nOfLOmWsYGFR mpTC0rTKeoyBRACg== Received: from localhost.localdomain (unknown [10.100.201.122]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id 7B1E82C141; Tue, 7 Jun 2022 10:49:52 +0000 (UTC) From: Jiri Slaby To: gregkh@linuxfoundation.org Cc: linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, Jiri Slaby Subject: [PATCH 15/36] tty/vt: consolemap: make p1 increment less confusing in con_get_unimap() Date: Tue, 7 Jun 2022 12:49:25 +0200 Message-Id: <20220607104946.18710-15-jslaby@suse.cz> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220607104946.18710-1-jslaby@suse.cz> References: <20220607104946.18710-1-jslaby@suse.cz> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 p2 is already incremented like this few lines below, so do the same for p1. This makes the code easier to follow. Signed-off-by: Jiri Slaby --- drivers/tty/vt/consolemap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/tty/vt/consolemap.c b/drivers/tty/vt/consolemap.c index 84c8043a36d0..831450f2bfd1 100644 --- a/drivers/tty/vt/consolemap.c +++ b/drivers/tty/vt/consolemap.c @@ -793,8 +793,8 @@ int con_get_unimap(struct vc_data *vc, ushort ct, ushort __user *uct, if (!p1) continue; - for (j = 0; j < UNI_DIR_ROWS; j++) { - p2 = *(p1++); + for (j = 0; j < UNI_DIR_ROWS; j++, p1++) { + p2 = *p1; if (!p2) continue; -- 2.36.1