Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp2576595lqp; Mon, 25 Mar 2024 03:15:41 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXBgys4Cr1PW3GDr7XlGcpPAMo2QsvezUd/D952YidBu30KjEyTWBLy91u0ofGIbRJoDE4g94CpkRXYjMEL3Qh80lI13GnWZgp0DveKqw== X-Google-Smtp-Source: AGHT+IHnB+ZuXehuZsw3PhZ/M7fsLskqI0d4S/DDyoyj/Dtu/d9SvE0Fx6tXvp9EhkBCSXBYMmzB X-Received: by 2002:a05:6a00:2389:b0:6ea:91d2:98a6 with SMTP id f9-20020a056a00238900b006ea91d298a6mr7235366pfc.15.1711361741247; Mon, 25 Mar 2024 03:15:41 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711361741; cv=pass; d=google.com; s=arc-20160816; b=H8pLrPZzW1UcRdzpEwsF6i7ZYUxipW2Ua5eDWh+eQhUTAByHGErybNdpzQj8/+4sNJ PhSmReRqhtzJ5E+Tea7JRLCvz/7W5i6fBYrRo+yVSrq1Klmvq3/4gAQLOIrmL8RmeDyY BfPpUSsPFavgcu3p/PloYZVW96sK971yK46D0k1/HcDsixZqouavgSJ+4Da04Ny0kVJi 9xUwd3DxbdhOaAz8zzluewJFMvcdjdIL7oyxpylVgatYVaRvkuNSOLTLQLrYqhNZU5cv J9nVI2PbElr81VgTXBfnT/3h5a1+fUFP8FAT15JUn0t1h/IZvTnCyn5bgKw/5DWdNP8m 1WpA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=CvRs2fdY7LZ1e+cpcSsDKt8lGKEleMMEgAYnO7PggEc=; fh=sGGvDCVuHLj6W0CzBAhMIj8sJpT8H1sMYO4+Iy5nEWk=; b=cvaFkhKsp/ulWKJHrfKGDTiheCQ9xJ35HBKU9FL4exylgUqLTbufQaQTWONkDn+DNs 3bLK5x2aQjmvaoWlUoj/kTfHR9WnMNzJm1D84SInXa/eFsnURk+U0SYZMD9zWfFtNGgc hdakIN96Pu8rFWY+bz4N+REwXZOMR6xYOs+EOsfNUZzXF8cUv1lZY+Osem6chHGUD5sf p7CvdQa6Vp+FJJ3LQVRHBJuOrmktcyTl6kvpa4SrGoNY+JDzVXJA12oSDKdGV6aaxJlY X+lb7au183XtBdEHfitCNLiH+q8Qypw1WA7zurwAI1wf+RH+ONn/mc7gc1D5F50ZsbYg oPbw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=dVd5plhy; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-115991-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-115991-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id j24-20020aa78d18000000b006e65d654afbsi4783565pfe.32.2024.03.25.03.15.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Mar 2024 03:15:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-115991-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=dVd5plhy; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-115991-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-115991-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id F12C929D7EC for ; Mon, 25 Mar 2024 10:00:29 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 485A323658F; Mon, 25 Mar 2024 03:05:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="dVd5plhy" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A108215EFDD; Sun, 24 Mar 2024 23:18:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711322324; cv=none; b=FbWUPr5kX9GOZ7unFBI25W3f1thuIhvchmr4pJs3ugIYJtKeaFn9gNf5s3sclb/P3f8KikthO0QYqNKsG7dbLc4y9bcXLhAg+IXfYnHKhmef5TsV//6inAjPkECPKMKUyiRA84fcR8NYYXBzD8Q6+6iI0fnpcOj5AgSjcWgaNmg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711322324; c=relaxed/simple; bh=OwtCJvgFm1joD9dGpHgZjvWy/3NSqXfs5fo7EoGkYmw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=mFtLrGHvGhwI2z5X5EPt+83gq1W9iVDJb/dG1k0vsMdG2K+/NOTbHAI1SdUrG5x+/Ee72HMQikdjpPk5A81nuWjt4pFWAPMEkrmU7mOGI4Po9s1N3LnAnwe7tFRjhUx1nRYt3nnnvbvYMP8wz2rIJmUHEMehKz3CJSJqvBZuzo4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=dVd5plhy; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id E412FC433F1; Sun, 24 Mar 2024 23:18:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1711322324; bh=OwtCJvgFm1joD9dGpHgZjvWy/3NSqXfs5fo7EoGkYmw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=dVd5plhyWkF1TPH7GeQnlbvCqU3W8JnmTpXDSjVrvwnftjsPOoDZqRcPQZh+QYviA /KO10gpI3E2p011A95oCpSG68BiMzlerIF+O4SR2SMHosSeO4WBmn+9Et1Zu2AW+ZC fl0u4Ymxf/VQ/JCQGBLygWxDrcZuFEBgXHAeovswO+BG6X+WV/ETo2HfTY/ia/04NC uBHQ7lJ2BZC7vHRcMTk0BO8nNnYDcnEEF1tJaVzFl662DJdtZ9wcTaUHuyfMJD2J4r WFVsltnHiyVGQxf/OFMz5H/ED8vDn6XbkzbFhhzkcjN/K1gkVaWJX8VoFOvXwQ4f/c mTo18qKziaHEw== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Arnd Bergmann , Dmitry Antipov , Sasha Levin Subject: [PATCH 6.1 407/451] soc: fsl: dpio: fix kcalloc() argument order Date: Sun, 24 Mar 2024 19:11:23 -0400 Message-ID: <20240324231207.1351418-408-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240324231207.1351418-1-sashal@kernel.org> References: <20240324231207.1351418-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit From: Arnd Bergmann [ Upstream commit 72ebb41b88f9d7c10c5e159e0507074af0a22fe2 ] A previous bugfix added a call to kcalloc(), which starting in gcc-14 causes a harmless warning about the argument order: drivers/soc/fsl/dpio/dpio-service.c: In function 'dpaa2_io_service_enqueue_multiple_desc_fq': drivers/soc/fsl/dpio/dpio-service.c:526:29: error: 'kcalloc' sizes specified with 'sizeof' in the earlier argument and not in the later argument [-Werror=calloc-transposed-args] 526 | ed = kcalloc(sizeof(struct qbman_eq_desc), 32, GFP_KERNEL); | ^~~~~~ drivers/soc/fsl/dpio/dpio-service.c:526:29: note: earlier argument should specify number of elements, later size of each element Since the two are only multiplied, the order does not change the behavior, so just fix it now to shut up the compiler warning. Dmity independently came up with the same fix. Fixes: 5c4a5999b245 ("soc: fsl: dpio: avoid stack usage warning") Reported-by: Dmitry Antipov Signed-off-by: Arnd Bergmann Signed-off-by: Sasha Levin --- drivers/soc/fsl/dpio/dpio-service.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/soc/fsl/dpio/dpio-service.c b/drivers/soc/fsl/dpio/dpio-service.c index 1d2b27e3ea63f..b811446e0fa55 100644 --- a/drivers/soc/fsl/dpio/dpio-service.c +++ b/drivers/soc/fsl/dpio/dpio-service.c @@ -523,7 +523,7 @@ int dpaa2_io_service_enqueue_multiple_desc_fq(struct dpaa2_io *d, struct qbman_eq_desc *ed; int i, ret; - ed = kcalloc(sizeof(struct qbman_eq_desc), 32, GFP_KERNEL); + ed = kcalloc(32, sizeof(struct qbman_eq_desc), GFP_KERNEL); if (!ed) return -ENOMEM; -- 2.43.0