From patchwork Fri Jul 30 14:41:56 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 489703 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=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, 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 AF549C4338F for ; Fri, 30 Jul 2021 14:42:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8E0E860C3F for ; Fri, 30 Jul 2021 14:42:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239302AbhG3OmU (ORCPT ); Fri, 30 Jul 2021 10:42:20 -0400 Received: from smtp-relay-canonical-0.canonical.com ([185.125.188.120]:44744 "EHLO smtp-relay-canonical-0.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239200AbhG3OmS (ORCPT ); Fri, 30 Jul 2021 10:42:18 -0400 Received: from mail-ed1-f72.google.com (mail-ed1-f72.google.com [209.85.208.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPS id 158353F22A for ; Fri, 30 Jul 2021 14:42:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1627656133; bh=lpVZTJlpKGPodj4MHtc+rObtHPXyuiLkFrg5L18y8PI=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Um8cfwRwb4P7eWhWO7sYFJU1UF3AvYuziymLzZnEJH9xCvBXURp1bm8yzELOgGESC 6ybjUD4sWcfWYXAZfeBF2+WwrXOITZ+c0AoI4mZX6IiFApe+K7EvcqTZDXcInNodxe oTj2UVEf7rTsYdxb38RJ+YSgroqATHC/qzZEErA4RYPLBtY8E5TBETKNTKB2uf+9nx f8nFQa/wjEiuX6ZzQ2lJmnQp739DSQNHFuAOOJ0s38+UMBSiz6oI3BVecVO9qry6gX 1Skl22Ytejcsbm0xDdSFqzdqCLHtWmv+v5rnIsMwDHa32VW0SOA6HtMe5WkeMLK8HV XbgtE4W5hYgVg== Received: by mail-ed1-f72.google.com with SMTP id p2-20020a50c9420000b02903a12bbba1ebso4695986edh.6 for ; Fri, 30 Jul 2021 07:42:13 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=lpVZTJlpKGPodj4MHtc+rObtHPXyuiLkFrg5L18y8PI=; b=HCDWw65sWcswLWGrRYauZpLAJYxEc/HjGW3Z3jCdVD0udmg6Yn97WPUWWFtZzU2Uzo fIOvP8RR2gEL6roy+NPqTONLsJ4xXM4GbzZ9uWRrjiQHAxpwEZngrGayyL7JhyVeiVPL vn30ej5r/4s5EaVJW67QR4H8iOSeWVjRdXcY7zqVOYhE0ZzrGykZLKprm3LW47YgArJh osH3mGpqClCoE5ZXGYTW7BeJBHSQyieD0DxHz6tCCdD75yxRehA5iPB43h7tCHMd+wnp HzQ8+IykrEJdXhKJo8ztBLN5e7mzUyqE9KbNiPLdL3ZxbHEWk1NjeBEt20tXfEcgG3Rf k+Kg== X-Gm-Message-State: AOAM53308jApHGyGHWBgBDRK0WDbyZIJ21ibZFMUsBNVjU+ij9PeVxyy xuCbr2wL6PoG2I13r5RFv2aI45ifkUmr5taaw7kWEvMGU6aWyPu9QT3hVWfYNW0PINWzrK/HLYg DkjYWczgdTqgFengr8VpZrYYVX71jGnU2wg== X-Received: by 2002:a05:6402:1c19:: with SMTP id ck25mr3395015edb.128.1627656132803; Fri, 30 Jul 2021 07:42:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwEYNd2rGK8vmEVNFNmAp5fQBjwS6feWC8FOd6wG1bhDOFk//GYqhLi16ea5fwlunfc1R0zxw== X-Received: by 2002:a05:6402:1c19:: with SMTP id ck25mr3395003edb.128.1627656132665; Fri, 30 Jul 2021 07:42:12 -0700 (PDT) Received: from localhost.localdomain ([86.32.47.9]) by smtp.gmail.com with ESMTPSA id z8sm626325ejd.94.2021.07.30.07.42.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Jul 2021 07:42:12 -0700 (PDT) From: Krzysztof Kozlowski To: Krzysztof Kozlowski , "David S. Miller" , Jakub Kicinski , linux-nfc@lists.01.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 1/7] nfc: mrvl: correct nfcmrvl_spi_parse_dt() device_node argument Date: Fri, 30 Jul 2021 16:41:56 +0200 Message-Id: <20210730144202.255890-2-krzysztof.kozlowski@canonical.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> References: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org The device_node in nfcmrvl_spi_parse_dt() cannot be const as it is passed to OF functions which modify it. Signed-off-by: Krzysztof Kozlowski --- drivers/nfc/nfcmrvl/spi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/nfc/nfcmrvl/spi.c b/drivers/nfc/nfcmrvl/spi.c index d64abd0c4df3..b182ab2e03c0 100644 --- a/drivers/nfc/nfcmrvl/spi.c +++ b/drivers/nfc/nfcmrvl/spi.c @@ -106,7 +106,7 @@ static const struct nfcmrvl_if_ops spi_ops = { .nci_update_config = nfcmrvl_spi_nci_update_config, }; -static int nfcmrvl_spi_parse_dt(const struct device_node *node, +static int nfcmrvl_spi_parse_dt(struct device_node *node, struct nfcmrvl_platform_data *pdata) { int ret; From patchwork Fri Jul 30 14:41:58 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 489702 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=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, 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 C11DBC43214 for ; Fri, 30 Jul 2021 14:42:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id ABE4360C3F for ; Fri, 30 Jul 2021 14:42:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239405AbhG3OmY (ORCPT ); Fri, 30 Jul 2021 10:42:24 -0400 Received: from smtp-relay-canonical-0.canonical.com ([185.125.188.120]:44782 "EHLO smtp-relay-canonical-0.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239335AbhG3OmV (ORCPT ); Fri, 30 Jul 2021 10:42:21 -0400 Received: from mail-ed1-f72.google.com (mail-ed1-f72.google.com [209.85.208.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPS id 04A683F22C for ; Fri, 30 Jul 2021 14:42:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1627656136; bh=VTZKLd4Cikiu9JLg7PgN5ojxKk/zgZVaneS8eoEANNg=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=wG4q3F2QwIMWJeVKxe6/BaXgZlq4lh8fmwMXSqQ5qeo/j21FgAiWBC+m0AKZSa0RL Y5iS8JlzOzplGVG5GclJu01t5iyHzrqPXrMUKNQI8/ehW/iGCGUv6vOjiRk4K6NGML 7Uoq3GD2e29/eVXf8jiPax6YHIC7o5caMPQ7u2A3Qgak2rXIM+2eJaYV0AjPurSvdg gh20AOwPUkDyeaTGvLBxtRYHFKT3nE8Z1a8tPJsRwYIZIiQ+tvQRKe2GIVXfn5HV7T dZoB34Txu5X47HMnQw3NFYdx1idP657Mzfo8U249FsXtOoc39l7ScFcqofqV4rkq7O As0PM8hqaxZ+Q== Received: by mail-ed1-f72.google.com with SMTP id s8-20020a0564020148b02903948b71f25cso4713053edu.4 for ; Fri, 30 Jul 2021 07:42:16 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=VTZKLd4Cikiu9JLg7PgN5ojxKk/zgZVaneS8eoEANNg=; b=aez0X9QXMZv25rmlekhPkvOyzrNWE7Bu7SHBXXdplONAGV6XGUapA/vMPoPcknsp5Y St3Puz28r5RfiwqVT9YREn1yjTvseHUDTguINtid4HkFqeyPoo4v/iza3ig34Enu7eBr g+uDxumxYmvf+d9IkbCyy7AnCtTko53HodK3bBw6286dGRobECzu/n+/5oAqVWGZj40G CrcRpo6yydT/U7I11/ns+WLT2D1sgPZiSEhkyW/6hbz1S6OHu6kF2whZpV0w8gtwgUm7 tFeIN8vnuJue4FINuJyh5SyDyhjHb+q+XA13uLeilbTpEUaEXc9NE5XsT8piallUNAc6 Yx0w== X-Gm-Message-State: AOAM530eigO6xButQ3i/cGVC81L1w8urG0eRcAQ80snfiahw0zgjyI8s sVmlhDDqKEn9rwnVcPDH63KNzbNxUpA5px0813c1eeUHU1vjHP1Sk8LQZu/cEpn2LHuX7lqxK56 +Aiig+/3l3LCNvFFjELUQUhsXPciMTM8/8w== X-Received: by 2002:a05:6402:d5a:: with SMTP id ec26mr3436354edb.4.1627656135813; Fri, 30 Jul 2021 07:42:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxTklZlpNPU1+0JaWvnxKZnRAAAubw23rxdRY2xTtGKFHycvUIP2Hj5u3KPcqBIf0isib80/w== X-Received: by 2002:a05:6402:d5a:: with SMTP id ec26mr3436345edb.4.1627656135731; Fri, 30 Jul 2021 07:42:15 -0700 (PDT) Received: from localhost.localdomain ([86.32.47.9]) by smtp.gmail.com with ESMTPSA id z8sm626325ejd.94.2021.07.30.07.42.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Jul 2021 07:42:15 -0700 (PDT) From: Krzysztof Kozlowski To: Krzysztof Kozlowski , "David S. Miller" , Jakub Kicinski , linux-nfc@lists.01.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 3/7] nfc: hci: annotate nfc_llc_init() as __init Date: Fri, 30 Jul 2021 16:41:58 +0200 Message-Id: <20210730144202.255890-4-krzysztof.kozlowski@canonical.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> References: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org The nfc_llc_init() is used only in other __init annotated context. Signed-off-by: Krzysztof Kozlowski --- net/nfc/hci/llc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/nfc/hci/llc.c b/net/nfc/hci/llc.c index fc6b63de3462..2140f6724644 100644 --- a/net/nfc/hci/llc.c +++ b/net/nfc/hci/llc.c @@ -11,7 +11,7 @@ static LIST_HEAD(llc_engines); -int nfc_llc_init(void) +int __init nfc_llc_init(void) { int r; From patchwork Fri Jul 30 14:42:00 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 489701 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=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 97286C432BE for ; Fri, 30 Jul 2021 14:42:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8631360C3F for ; Fri, 30 Jul 2021 14:42:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239453AbhG3Oma (ORCPT ); Fri, 30 Jul 2021 10:42:30 -0400 Received: from smtp-relay-canonical-1.canonical.com ([185.125.188.121]:32818 "EHLO smtp-relay-canonical-1.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239389AbhG3OmY (ORCPT ); Fri, 30 Jul 2021 10:42:24 -0400 Received: from mail-ed1-f71.google.com (mail-ed1-f71.google.com [209.85.208.71]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-1.canonical.com (Postfix) with ESMTPS id 0954B3F24F for ; Fri, 30 Jul 2021 14:42:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1627656139; bh=y9Uo/os+3OziqdNdxRl0CGuCizZoyhHNVP1pooBGgac=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=SvmNlYfO1T9YpcWhHz55l6E2AKU5Vwq+wL3UTYyhBlzikGj5kii+hg/tRlTYDjrkZ 6hKIDXQoJ9a7he3I+i6tLykgAJIuTjCyJP9DWvnfFXD4ToVV532BUjPBmTakkF6ZIE IksZ1zAank8t0af1rS5vUzI17UopCLp2w+aRbWtL6K5PnivWZ/V3qt8BqFegZ21T18 k6qIoVLL0gUUj+QfFiT4KCe6DX69n2Ek+vIPBDEyaNK0DcY9l6pSxhK5UM1DIfqWoa FwgaphuTCu9Oy7wxnL642ibJ+M7E4hqCZ7ODKjwTGR64lM0P7ml10rBspcacZY7FmD Nrcc6RImxvCxg== Received: by mail-ed1-f71.google.com with SMTP id d12-20020a50fe8c0000b02903a4b519b413so4718124edt.9 for ; Fri, 30 Jul 2021 07:42:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=y9Uo/os+3OziqdNdxRl0CGuCizZoyhHNVP1pooBGgac=; b=HIGbYgLSWGgw6hWI/xB8BHB+xB43a8oY8+OGXQXaR6N87fXNBqbzFrPM4MOUpfs1kw OqOBf49Alsr/RLTrYowbX+C0tZ0ggsxSNmBDwYMNgAYXOLutcY9pkMSsOWMrn/HMHvmv pzvGiCgsLY6XLR1l9qp9qkQtFjgbCEttlmSyp6R/KUwWesmrel23B/QmYWSHbi5IigAV ijON4IRkktboHXguMAv5tMrnJUVirzEh7nGB90RlZfa5BlsohwMfFFBEII0XDqppuaG6 kx3HrluunzNkLOnkPGLBFqLOR3ikfccNsPePPe6OITITj1uQM0mnwGAm3lx5nGvN9pNV ktHw== X-Gm-Message-State: AOAM531xB25ysTBBCh5MdifTqDM4HGWj3/OtdIo6Wa+46X1lMg8Xtac2 FyZTnwk8aT2KnHxLrxZYPiXa3iWKPwASrTpczfMHllKWzt5v1+kNxaNHpExqLSgfg2MLoOMrxiv GzR3DbaVivJabzpeIyanaZ0joCuSgmkMTWw== X-Received: by 2002:a17:907:2d28:: with SMTP id gs40mr2904571ejc.193.1627656138735; Fri, 30 Jul 2021 07:42:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwYC1VofAfZY3hhBV10+K4sh3QRT8py2x7b+JMzQrNK6xJ2n3VaOY7deB9lkFNxeE52DKW/7g== X-Received: by 2002:a17:907:2d28:: with SMTP id gs40mr2904558ejc.193.1627656138597; Fri, 30 Jul 2021 07:42:18 -0700 (PDT) Received: from localhost.localdomain ([86.32.47.9]) by smtp.gmail.com with ESMTPSA id z8sm626325ejd.94.2021.07.30.07.42.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Jul 2021 07:42:18 -0700 (PDT) From: Krzysztof Kozlowski To: Krzysztof Kozlowski , "David S. Miller" , Jakub Kicinski , linux-nfc@lists.01.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 5/7] nfc: constify local pointer variables Date: Fri, 30 Jul 2021 16:42:00 +0200 Message-Id: <20210730144202.255890-6-krzysztof.kozlowski@canonical.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> References: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Few pointers to struct nfc_target and struct nfc_se can be made const. Signed-off-by: Krzysztof Kozlowski --- drivers/nfc/pn544/pn544.c | 4 ++-- net/nfc/core.c | 2 +- net/nfc/hci/core.c | 8 ++++---- net/nfc/netlink.c | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/nfc/pn544/pn544.c b/drivers/nfc/pn544/pn544.c index c2b4555ab4b7..092f03b80a78 100644 --- a/drivers/nfc/pn544/pn544.c +++ b/drivers/nfc/pn544/pn544.c @@ -809,7 +809,7 @@ static int pn544_hci_discover_se(struct nfc_hci_dev *hdev) #define PN544_SE_MODE_ON 0x01 static int pn544_hci_enable_se(struct nfc_hci_dev *hdev, u32 se_idx) { - struct nfc_se *se; + const struct nfc_se *se; u8 enable = PN544_SE_MODE_ON; static struct uicc_gatelist { u8 head; @@ -864,7 +864,7 @@ static int pn544_hci_enable_se(struct nfc_hci_dev *hdev, u32 se_idx) static int pn544_hci_disable_se(struct nfc_hci_dev *hdev, u32 se_idx) { - struct nfc_se *se; + const struct nfc_se *se; u8 disable = PN544_SE_MODE_OFF; se = nfc_find_se(hdev->ndev, se_idx); diff --git a/net/nfc/core.c b/net/nfc/core.c index 08182e209144..3c645c1d99c9 100644 --- a/net/nfc/core.c +++ b/net/nfc/core.c @@ -824,7 +824,7 @@ EXPORT_SYMBOL(nfc_targets_found); */ int nfc_target_lost(struct nfc_dev *dev, u32 target_idx) { - struct nfc_target *tg; + const struct nfc_target *tg; int i; pr_debug("dev_name %s n_target %d\n", dev_name(&dev->dev), target_idx); diff --git a/net/nfc/hci/core.c b/net/nfc/hci/core.c index ff94ac774937..ceb87db57cdb 100644 --- a/net/nfc/hci/core.c +++ b/net/nfc/hci/core.c @@ -128,7 +128,7 @@ static void nfc_hci_msg_rx_work(struct work_struct *work) struct nfc_hci_dev *hdev = container_of(work, struct nfc_hci_dev, msg_rx_work); struct sk_buff *skb; - struct hcp_message *message; + const struct hcp_message *message; u8 pipe; u8 type; u8 instruction; @@ -182,9 +182,9 @@ void nfc_hci_cmd_received(struct nfc_hci_dev *hdev, u8 pipe, u8 cmd, struct sk_buff *skb) { u8 status = NFC_HCI_ANY_OK; - struct hci_create_pipe_resp *create_info; - struct hci_delete_pipe_noti *delete_info; - struct hci_all_pipe_cleared_noti *cleared_info; + const struct hci_create_pipe_resp *create_info; + const struct hci_delete_pipe_noti *delete_info; + const struct hci_all_pipe_cleared_noti *cleared_info; u8 gate; pr_debug("from pipe %x cmd %x\n", pipe, cmd); diff --git a/net/nfc/netlink.c b/net/nfc/netlink.c index 70467a82be8f..49089c50872e 100644 --- a/net/nfc/netlink.c +++ b/net/nfc/netlink.c @@ -530,7 +530,7 @@ int nfc_genl_se_transaction(struct nfc_dev *dev, u8 se_idx, int nfc_genl_se_connectivity(struct nfc_dev *dev, u8 se_idx) { - struct nfc_se *se; + const struct nfc_se *se; struct sk_buff *msg; void *hdr; From patchwork Fri Jul 30 14:42:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 489700 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=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 7F155C4320E for ; Fri, 30 Jul 2021 14:42:33 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 6B19960F46 for ; Fri, 30 Jul 2021 14:42:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239529AbhG3Ome (ORCPT ); Fri, 30 Jul 2021 10:42:34 -0400 Received: from smtp-relay-canonical-0.canonical.com ([185.125.188.120]:44814 "EHLO smtp-relay-canonical-0.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239430AbhG3Om1 (ORCPT ); Fri, 30 Jul 2021 10:42:27 -0400 Received: from mail-ej1-f70.google.com (mail-ej1-f70.google.com [209.85.218.70]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPS id 4ED233F047 for ; Fri, 30 Jul 2021 14:42:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1627656142; bh=1znQCNoqUlEMI5poOw0ZjBZ5wK7z3hvmMB9nUaNmREA=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=rlHTXiGDL9LMViLWwjwt6z96Sp11g2NhErRoYpNsCRh4hWfEVGDrVCSZBugwl9MLa KIZhz3XNnaxHIaI+red80L7uAf8ajsM6gnW6dQmSp/Kf3bCLHj4HAiYUkO2o9jZKvG VPYwzQk8OorYBemeKBDhm9q+qd/76QaIO1HbeEU7+dOhNm0jYn2x2hKC3ff1TxliJo CdXw+8exC9VasWKjS5ZxJIzPnOBZeLVerrCgXZo89dyg1Be2LlUOExWvO7/FbxdQ4c 1QB9wAkffy5ElqtjucI0agpU+F83dERyvYSFn2/RZYyThDmO+wIiAh4L9q3UAEtwKg 1JRUszS2I0zrA== Received: by mail-ej1-f70.google.com with SMTP id qf6-20020a1709077f06b029057e66b6665aso3192910ejc.18 for ; Fri, 30 Jul 2021 07:42:22 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=1znQCNoqUlEMI5poOw0ZjBZ5wK7z3hvmMB9nUaNmREA=; b=sNzQve4MqBZx2LvL1dWLR06jEG8LnYUosH+xEwwSAiM2Rsqa1RGB/8HLKTlxUt4CPn F4ibi4rdXCJTrcNp6kExCLLZAWHSUdBAejwg40GNi1nnQRNp8qESzZQFiLuv0Um9Nz4k h/0ZWAeJMaTUJzksjmk+oeOHO9OaHL0IsPJl/f0Zzfs6zpLZ8kS2Fa3MiWntpk3MvBoj +E/O3TuMLfaTWb+4SBjA2626Zkw7way9lS3h2o8kO/4fKF7zJHEYkcztpTrcPXJIA3RJ +TwGgqn065QmgDrXKbynlD+TfNv3tHSIuNDp1bBPqqdvtm0FG10RJwZ3pFcwo6eVyfLa 0IjQ== X-Gm-Message-State: AOAM5327r7vy9a07LFKF0OU2YjiLygSjRw20xX5nc19CiV1uedDKajNg GIhELpFyt3n1cyxLcUNdacqJRnB71Oq73idxP1fr/zdTUeyZlZdVknIYf6owLVISG9to4FpXfoy G0E4uU4kYQ91/EpwpKtXxwVfPNLzL4c9cow== X-Received: by 2002:a50:d698:: with SMTP id r24mr3405021edi.316.1627656141873; Fri, 30 Jul 2021 07:42:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyR7m5xILM6A60J/5SHUYH5rQvCwRRECUJKkYnyp+ryMs1/2V3FrotgTyAKsGYvnx0cVFsAUQ== X-Received: by 2002:a50:d698:: with SMTP id r24mr3405014edi.316.1627656141770; Fri, 30 Jul 2021 07:42:21 -0700 (PDT) Received: from localhost.localdomain ([86.32.47.9]) by smtp.gmail.com with ESMTPSA id z8sm626325ejd.94.2021.07.30.07.42.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Jul 2021 07:42:20 -0700 (PDT) From: Krzysztof Kozlowski To: Krzysztof Kozlowski , "David S. Miller" , Jakub Kicinski , linux-nfc@lists.01.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 7/7] nfc: hci: cleanup unneeded spaces Date: Fri, 30 Jul 2021 16:42:02 +0200 Message-Id: <20210730144202.255890-8-krzysztof.kozlowski@canonical.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> References: <20210730144202.255890-1-krzysztof.kozlowski@canonical.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org No need for multiple spaces in variable declaration (the code does not use them in other places). No functional change. Signed-off-by: Krzysztof Kozlowski --- net/nfc/nci/core.c | 8 ++++---- net/nfc/nci/hci.c | 14 +++++++------- net/nfc/nci/ntf.c | 4 ++-- net/nfc/nci/rsp.c | 2 +- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/net/nfc/nci/core.c b/net/nfc/nci/core.c index 774ddf957388..80a5c2a8e9fa 100644 --- a/net/nfc/nci/core.c +++ b/net/nfc/nci/core.c @@ -409,7 +409,7 @@ static void nci_send_data_req(struct nci_dev *ndev, unsigned long opt) static void nci_nfcc_loopback_cb(void *context, struct sk_buff *skb, int err) { struct nci_dev *ndev = (struct nci_dev *)context; - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; conn_info = nci_get_conn_info_by_conn_id(ndev, ndev->cur_conn_id); if (!conn_info) { @@ -1006,7 +1006,7 @@ static int nci_transceive(struct nfc_dev *nfc_dev, struct nfc_target *target, { struct nci_dev *ndev = nfc_get_drvdata(nfc_dev); int rc; - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; conn_info = ndev->rf_conn_info; if (!conn_info) @@ -1271,7 +1271,7 @@ EXPORT_SYMBOL(nci_register_device); */ void nci_unregister_device(struct nci_dev *ndev) { - struct nci_conn_info *conn_info, *n; + struct nci_conn_info *conn_info, *n; nci_close_device(ndev); @@ -1443,7 +1443,7 @@ int nci_core_ntf_packet(struct nci_dev *ndev, __u16 opcode, static void nci_tx_work(struct work_struct *work) { struct nci_dev *ndev = container_of(work, struct nci_dev, tx_work); - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; struct sk_buff *skb; conn_info = nci_get_conn_info_by_conn_id(ndev, ndev->cur_conn_id); diff --git a/net/nfc/nci/hci.c b/net/nfc/nci/hci.c index 71a306b29735..a8ff794a8084 100644 --- a/net/nfc/nci/hci.c +++ b/net/nfc/nci/hci.c @@ -16,11 +16,11 @@ #include struct nci_data { - u8 conn_id; - u8 pipe; - u8 cmd; - const u8 *data; - u32 data_len; + u8 conn_id; + u8 pipe; + u8 cmd; + const u8 *data; + u32 data_len; } __packed; struct nci_hci_create_pipe_params { @@ -363,7 +363,7 @@ static void nci_hci_cmd_received(struct nci_dev *ndev, u8 pipe, static void nci_hci_resp_received(struct nci_dev *ndev, u8 pipe, struct sk_buff *skb) { - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; conn_info = ndev->hci_dev->conn_info; if (!conn_info) @@ -714,7 +714,7 @@ static int nci_hci_dev_connect_gates(struct nci_dev *ndev, int nci_hci_dev_session_init(struct nci_dev *ndev) { - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; struct sk_buff *skb; int r; diff --git a/net/nfc/nci/ntf.c b/net/nfc/nci/ntf.c index d6251363b72b..c5eacaac41ae 100644 --- a/net/nfc/nci/ntf.c +++ b/net/nfc/nci/ntf.c @@ -48,7 +48,7 @@ static void nci_core_conn_credits_ntf_packet(struct nci_dev *ndev, struct sk_buff *skb) { struct nci_core_conn_credit_ntf *ntf = (void *) skb->data; - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; int i; pr_debug("num_entries %d\n", ntf->num_entries); @@ -528,7 +528,7 @@ static int nci_store_general_bytes_nfc_dep(struct nci_dev *ndev, static void nci_rf_intf_activated_ntf_packet(struct nci_dev *ndev, const struct sk_buff *skb) { - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; struct nci_rf_intf_activated_ntf ntf; const __u8 *data = skb->data; int err = NCI_STATUS_OK; diff --git a/net/nfc/nci/rsp.c b/net/nfc/nci/rsp.c index dbb0b55a1757..a2e72c003805 100644 --- a/net/nfc/nci/rsp.c +++ b/net/nfc/nci/rsp.c @@ -185,7 +185,7 @@ static void nci_rf_disc_map_rsp_packet(struct nci_dev *ndev, static void nci_rf_disc_rsp_packet(struct nci_dev *ndev, const struct sk_buff *skb) { - struct nci_conn_info *conn_info; + struct nci_conn_info *conn_info; __u8 status = skb->data[0]; pr_debug("status 0x%x\n", status);