From patchwork Wed Jul 15 12:35:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 11665229 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 46F426C1 for ; Wed, 15 Jul 2020 12:37:27 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 2081A20658 for ; Wed, 15 Jul 2020 12:37:27 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="EZJn9KOn"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="L0uMl8Hb" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2081A20658 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject: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=7klQcslmbH6/IU/CQhFSN2PQwjl1Sij4xrd4V4C5Oks=; b=EZJn9KOnGahzgimH1GPy0EZ/rm MQRDi70E5Yro6moDvBvun/qni8i8ku2qj1pXno0pTr+px1g2VpCNhE3Ccbx/TsfNtieP5eq1WeDmM jtmAzW4FGu2nLCLNGKmi1mCnGzAESPXy4VUMrLkMhDRgZorfW0+J1XlW+8oMZMgCTFjdfCuIQbNlH 2yRJfHlr3Rsotqm6Am3srvkFdAcj3vebNfsljelnBNg/wzWbX5m4FEJbInT3ER+PzavAfdKIANGAI FE/IvPpNPq8zwow0JtVGpNsyeOPuINtwt/Qn8OqLuogQRd0xiVMZis2s1Cf0BGbaZjy79mlBbbLp8 8HvfPoBw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jvgdi-0001dk-Dt; Wed, 15 Jul 2020 12:35:58 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jvgdf-0001cm-7L for linux-arm-kernel@lists.infradead.org; Wed, 15 Jul 2020 12:35:56 +0000 Received: by mail-wr1-x442.google.com with SMTP id z15so2471521wrl.8 for ; Wed, 15 Jul 2020 05:35:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=DwZZAmt/+Jz9Ze538UBZf8fHuD08d99YrWh/wrfJAWU=; b=L0uMl8HbXnpQfc9D0kHtJqKTEoYngjcolOXuOvBSeh0DbOwCcJUBau5Ul1Mupv7s48 TzyTfD0t9pvG2iozvCFa+dEAnPJRpDSraNA/UR2XjUIBv80yDwlAQSK4crN3lPK5Y/9F VkECEIn8BsJU4kSAViBwnIix7A3wb2nf1X6o+VJrh5rAzu5miVylRlV34bAmqYJviWBQ t4QPxGTuwAgku2AvuDsHFzaEpVvWqSFsWWxwnl8tFqr0LUzldQ7igT1gPVM2uQVVF2eo ytNOcOrn/GH1LB38xJHnvxoOvz15d6Ib5BDcZkhidr51uXFp4vKeKi3vKEDwIxbf3ihr UP/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=DwZZAmt/+Jz9Ze538UBZf8fHuD08d99YrWh/wrfJAWU=; b=Oo0otl+9NCPefD3mpeg65kmam/ONUwmja+45vlkaIr1EGlKNU1UdYnWx74+JjcIYvs ky2Bw5MIIx4TbOzhYbO4ayWIJ0ft+2POx96x/RRTJLVNKKRFBVZnikDB+ymreaJo367V shWI9mf0IDjdCwDsVwZYg6dAbyeGY7Ir/9ZA1HClZxwq766pYnLbsgz8Uw0Vl3jFzgyM sjS++fRPl1NGFQndv9QasM4NVOGCYJ1z+TYqwh3j/aE5AhovRCPsIIB6wWFBoeGncf1a QkxuLE9LeO+1LeadfXIMBuo+bmYQ94U4a7awaeWshr/qll8ImV8I9FdeIbmeujlVBJQ+ bdJg== X-Gm-Message-State: AOAM531DSQRdWYkAc6Mlw7fgKq4LmeNoNlQ3wDICJun8Pva2sg63gmaJ yx1D/1+GG6es0t2vccITdRSMlw== X-Google-Smtp-Source: ABdhPJwrCFjQohsoalzLJDLPFkqYz+bRjaXZ9uDdPDSoUWAvn3wmzZKAnWLUqs4aEejfr8Gt+f4OpA== X-Received: by 2002:a5d:6651:: with SMTP id f17mr11991374wrw.29.1594816554292; Wed, 15 Jul 2020 05:35:54 -0700 (PDT) Received: from localhost.localdomain ([2.31.163.61]) by smtp.gmail.com with ESMTPSA id h14sm3298985wrt.36.2020.07.15.05.35.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 Jul 2020 05:35:53 -0700 (PDT) From: Lee Jones To: bjorn.andersson@linaro.org, ohad@wizery.com Subject: [PATCH 1/2] remoteproc: remoteproc_core: Use 'gnu_printf' format notation Date: Wed, 15 Jul 2020 13:35:50 +0100 Message-Id: <20200715123551.4011154-1-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200715_083555_320579_04D0F3F5 X-CRM114-Status: GOOD ( 10.91 ) X-Spam-Score: -0.2 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (-0.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:442 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Robert Tivy , Guzman Lugo , Brian Swetland , De Leon , linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org, Lee Jones , Mark Grosen , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Fixes the following W=1 kernel build warning(s): drivers/remoteproc/remoteproc_core.c: In function ‘rproc_find_carveout_by_name’: drivers/remoteproc/remoteproc_core.c:257:2: warning: function ‘rproc_find_carveout_by_name’ might be a candidate for ‘gnu_printf’ format attribute [-Wsuggest-attribute=format] 257 | vsnprintf(_name, sizeof(_name), name, args); | ^~~~~~~~~ drivers/remoteproc/remoteproc_core.c: In function ‘rproc_mem_entry_init’: drivers/remoteproc/remoteproc_core.c:993:2: warning: function ‘rproc_mem_entry_init’ might be a candidate for ‘gnu_printf’ format attribute [-Wsuggest-attribute=format] 993 | vsnprintf(mem->name, sizeof(mem->name), name, args); | ^~~~~~~~~ drivers/remoteproc/remoteproc_core.c: In function ‘rproc_of_resm_mem_entry_init’: drivers/remoteproc/remoteproc_core.c:1029:2: warning: function ‘rproc_of_resm_mem_entry_init’ might be a candidate for ‘gnu_printf’ format attribute [-Wsuggest-attribute=format] 1029 | vsnprintf(mem->name, sizeof(mem->name), name, args); | ^~~~~~~~~ Cc: Brian Swetland Cc: Mark Grosen Cc: Guzman Lugo Cc: Suman Anna Cc: Robert Tivy Cc: De Leon Signed-off-by: Lee Jones --- drivers/remoteproc/remoteproc_core.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_core.c index 0f95e025ba030..e00dff425c96e 100644 --- a/drivers/remoteproc/remoteproc_core.c +++ b/drivers/remoteproc/remoteproc_core.c @@ -243,6 +243,7 @@ EXPORT_SYMBOL(rproc_da_to_va); * * Return: a valid pointer on carveout entry on success or NULL on failure. */ +__printf(2, 3) struct rproc_mem_entry * rproc_find_carveout_by_name(struct rproc *rproc, const char *name, ...) { @@ -966,6 +967,7 @@ EXPORT_SYMBOL(rproc_add_carveout); * This function allocates a rproc_mem_entry struct and fill it with parameters * provided by client. */ +__printf(8, 9) struct rproc_mem_entry * rproc_mem_entry_init(struct device *dev, void *va, dma_addr_t dma, size_t len, u32 da, @@ -1009,6 +1011,7 @@ EXPORT_SYMBOL(rproc_mem_entry_init); * This function allocates a rproc_mem_entry struct and fill it with parameters * provided by client. */ +__printf(5, 6) struct rproc_mem_entry * rproc_of_resm_mem_entry_init(struct device *dev, u32 of_resm_idx, size_t len, u32 da, const char *name, ...)