From patchwork Fri Mar 19 15:21:30 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hawa, Hanna" X-Patchwork-Id: 12151271 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-11.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_ADSP_ALL,DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4DEA4C433DB for ; Fri, 19 Mar 2021 15:23:50 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id DA01A6192B for ; Fri, 19 Mar 2021 15:23:49 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DA01A6192B Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=amazon.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=P42b9C1QttzO/GLK9gtTyVEX0f8tpTgkQFyzZMTJIwc=; b=IkOtB9cPDgzUE2B9orMNOqwVP/ cJRalTb7/heuynL4CGa7YjWgwewZpNQMVofA5N595yV+MHdlWL/lg1yg4C+qRzFU0g/At8EYreDk+ B25/8BmRPYW+Z+r9rf+qkgYDlxPaLYPNYBH4AbXzWSdLqFYb4OalznTgZFABZKQ/xLQ+X/tKeLasV 5WEmsfNpePj7Gkn0o116mdVGJz5aS6VZNnRvIzUvPM7pPlY40O2MQJ102vRMGAivTba8AcNr5VX/O CVYzwhkmi9a5OoJf5j3mhjJI4VfOMhpFABYFNpgC/BwNyhsf2yYPYkV8uq3ZcqT/rmy92cV723RFX u+qI1Lrw==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lNGx2-007cev-Hn; Fri, 19 Mar 2021 15:22:12 +0000 Received: from smtp-fw-9102.amazon.com ([207.171.184.29]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lNGwx-007ceU-PL for linux-arm-kernel@lists.infradead.org; Fri, 19 Mar 2021 15:22:09 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1616167328; x=1647703328; h=from:to:cc:subject:date:message-id:mime-version; bh=EyrxdYGskd5nndv9DffBff17H/pW8ipDLECkcAeVTfk=; b=YQHkUDKt53AQrDb8oyHVkMtNvUC9lsh8Nx1tU2BlrSL/PsLi9ihEJHn+ TrsA0VBJXRHSYA9A6jivBWBpj1/WB3BEVymvvyy4mZtL3dGTn2CE3iou0 8+/W/toBL7LP3WsTjf6oNRMebcqOH7V6phVVgJfGGPetHdqysn28IYaIw g=; X-IronPort-AV: E=Sophos;i="5.81,262,1610409600"; d="scan'208";a="121703728" Received: from iad12-co-svc-p1-lb1-vlan2.amazon.com (HELO email-inbound-relay-2a-53356bf6.us-west-2.amazon.com) ([10.43.8.2]) by smtp-border-fw-out-9102.sea19.amazon.com with ESMTP; 19 Mar 2021 15:21:57 +0000 Received: from EX13D19EUB003.ant.amazon.com (pdx1-ws-svc-p6-lb9-vlan2.pdx.amazon.com [10.236.137.194]) by email-inbound-relay-2a-53356bf6.us-west-2.amazon.com (Postfix) with ESMTPS id A6DAFA1D50; Fri, 19 Mar 2021 15:21:55 +0000 (UTC) Received: from u8a88181e7b2355.ant.amazon.com (10.43.161.244) by EX13D19EUB003.ant.amazon.com (10.43.166.69) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 19 Mar 2021 15:21:49 +0000 From: Hanna Hawa To: , , , CC: , , , , , , , , , , , Subject: [PATCH v4 0/3] Fix pinctrl-single pcs_pin_dbg_show() Date: Fri, 19 Mar 2021 17:21:30 +0200 Message-ID: <20210319152133.28705-1-hhhawa@amazon.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-Originating-IP: [10.43.161.244] X-ClientProxiedBy: EX13D37UWA004.ant.amazon.com (10.43.160.23) To EX13D19EUB003.ant.amazon.com (10.43.166.69) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210319_152208_276426_F9B0F38E X-CRM114-Status: UNSURE ( 9.99 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org These patches fix the pcs_pin_dbg_show() function for the scenario where a single register controls multiple pins (i.e. bits_per_mux is not zero) Additionally, the common formula is moved to a separate function to allow reuse. Changes since v3: ----------------- - define and set variable 'mux_bytes' in one line - update commit message Changes since v2: ----------------- - move read() register to be outside of if condition (as it common read()). - Remove extra parentheses - replace offset variable by direct return statements Changes since v1: ----------------- - remove unused variable in In function 'pcs_allocate_pin_table' (Reported-by: kernel test robot ) Hanna Hawa (3): pinctrl: pinctrl-single: remove unused variable pinctrl: pinctrl-single: remove unused parameter pinctrl: pinctrl-single: fix pcs_pin_dbg_show() when bits_per_mux is not zero drivers/pinctrl/pinctrl-single.c | 65 ++++++++++++++++++-------------- 1 file changed, 37 insertions(+), 28 deletions(-) Reviewed-by: Drew Fustini