From patchwork Fri Oct 8 12:24:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Dessenne X-Patchwork-Id: 12545187 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E6814C433F5 for ; Fri, 8 Oct 2021 12:26:54 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 B877360F48 for ; Fri, 8 Oct 2021 12:26:54 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org B877360F48 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=foss.st.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; 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=DEPvReargNJuu/VM57wKqoIHHgHyON3ABxe712eIV7E=; b=Q7gHyPAIksC6GX mxIsLbq2w5qMIvoPJojvjfAhHvIKDNJfm/YBK4GjZeTFLhmMPwpdB6Ttno1KxU0Ndklet5Ry4+5Hi 5ll4HG3hvJPcljSSjNrbMZ0Gor9bwh5KbMAVjA+Drx3S80okLUgdWGIcN+Ie9NDVaYfkOeMbb0odV cO0Es+zFxVGO9BM6u2Yvbp2cNiN7jYpUhTWoQuYJEZeWy5eJKeYoEt8jqdBUNrjSiewKMebeNCUHo v0UcopCSYWpo/gmG6T8ep7aU2S8eW5gJ4F+p0WIlZL4pjqU/dqLZ6D+10Dd4zaqQL+cVdmFGULUqs iRSEant2stRVYIdd5rsA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mYowB-002gl2-Lz; Fri, 08 Oct 2021 12:25:19 +0000 Received: from mx08-00178001.pphosted.com ([91.207.212.93] helo=mx07-00178001.pphosted.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mYow6-002giC-Ii for linux-arm-kernel@lists.infradead.org; Fri, 08 Oct 2021 12:25:16 +0000 Received: from pps.filterd (m0046661.ppops.net [127.0.0.1]) by mx07-00178001.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 1989g3K9023582; Fri, 8 Oct 2021 14:25:07 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foss.st.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding : content-type; s=selector1; bh=o5dnBVGOI0j0+u6Bn/o8WUIi3ZFLpUM04QJe3Cs6AOU=; b=CcP90rnzgOfMswdXew1Gty1D3hFwatW0LQWG+5gCTjZ/m3O0ZhKnsOIEJpheJqIjzAQ5 M7nR4HZK2hLbP3dBitNKsCjPr2XwnPgUkFCptyw4zf0OoktWVbFlWEaCzuus0raBRCEk AoouUv04z5CBISwMizuVIWshx1y0t7jksrcfvpozpEINdMQeuucatnhGsJCfms+HeVmB TGTX26htQbJO3RFnr4GJzUEU4sQ4IMkGtxBlQMEhpYntKk0X6tCAU16Mgh4ptII2Lr9t 62OVerJBsf0MMUoSsICXYgO8LwJi5i73kxxex73JiQ06+sn9qv0gCxmVqBnnqZxo7Zbd DQ== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 3bjkk78vnk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 08 Oct 2021 14:25:07 +0200 Received: from euls16034.sgp.st.com (euls16034.sgp.st.com [10.75.44.20]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id CDE2F10002A; Fri, 8 Oct 2021 14:25:04 +0200 (CEST) Received: from Webmail-eu.st.com (sfhdag2node2.st.com [10.75.127.5]) by euls16034.sgp.st.com (STMicroelectronics) with ESMTP id C1527229A85; Fri, 8 Oct 2021 14:25:04 +0200 (CEST) Received: from localhost (10.75.127.49) by SFHDAG2NODE2.st.com (10.75.127.5) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Fri, 8 Oct 2021 14:25:02 +0200 From: Fabien Dessenne To: Linus Walleij , Maxime Coquelin , Alexandre Torgue , , , , CC: Fabien Dessenne Subject: [PATCH] pinctrl: stm32: do not warn when 'st,package' is absent Date: Fri, 8 Oct 2021 14:24:54 +0200 Message-ID: <20211008122454.617556-1-fabien.dessenne@foss.st.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Originating-IP: [10.75.127.49] X-ClientProxiedBy: SFHDAG2NODE1.st.com (10.75.127.4) To SFHDAG2NODE2.st.com (10.75.127.5) X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.391,FMLib:17.0.607.475 definitions=2021-10-08_03,2021-10-07_02,2020-04-07_01 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211008_052515_144492_99601D47 X-CRM114-Status: GOOD ( 15.85 ) 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 Since the 'st,package' property is optional, outputting the "No package detected" warning-level log when the property is absent is unsuitable. Remove that log. Signed-off-by: Fabien Dessenne --- drivers/pinctrl/stm32/pinctrl-stm32.c | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/pinctrl-stm32.c index 68b3886f9f0f..ac82570e46be 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -1415,17 +1415,6 @@ static int stm32_pctrl_create_pins_tab(struct stm32_pinctrl *pctl, return 0; } -static void stm32_pctl_get_package(struct device_node *np, - struct stm32_pinctrl *pctl) -{ - if (of_property_read_u32(np, "st,package", &pctl->pkg)) { - pctl->pkg = 0; - dev_warn(pctl->dev, "No package detected, use default one\n"); - } else { - dev_dbg(pctl->dev, "package detected: %x\n", pctl->pkg); - } -} - int stm32_pctl_probe(struct platform_device *pdev) { struct device_node *np = pdev->dev.of_node; @@ -1473,8 +1462,9 @@ int stm32_pctl_probe(struct platform_device *pdev) pctl->dev = dev; pctl->match_data = match->data; - /* get package information */ - stm32_pctl_get_package(np, pctl); + /* get optional package information */ + if (!of_property_read_u32(np, "st,package", &pctl->pkg)) + dev_dbg(pctl->dev, "package detected: %x\n", pctl->pkg); pctl->pins = devm_kcalloc(pctl->dev, pctl->match_data->npins, sizeof(*pctl->pins), GFP_KERNEL);