Received: by 2002:a89:413:0:b0:1fd:dba5:e537 with SMTP id m19csp1712545lqs; Sun, 16 Jun 2024 01:00:27 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUlG/jHyhjeDPUrisuHUZ7/JBlNhKEdNXULkLeMf6wtHwi2B4CEYsdl+sM1IGPOjhHsBA1I57kif8FI0zdjVSWY63rg7U/xuV+zYHd5CA== X-Google-Smtp-Source: AGHT+IHmiu3/C1nBRWBh59eLMfuexgFbIJisQZiohYApy3P7/NKZbawderY/rC70EHl2bDn7Gb68 X-Received: by 2002:a05:6808:1410:b0:3d2:1cc7:6490 with SMTP id 5614622812f47-3d24e8ad5a2mr8808281b6e.11.1718524826856; Sun, 16 Jun 2024 01:00:26 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718524826; cv=pass; d=google.com; s=arc-20160816; b=EqCpaWAhG4VVUC9reZPpMWIQW6AlWkBYnHR/muqNbYVlN0RpmvlqJwtxtBAI0IUQmb JDukA+2kkYRpiZV5pahF9SkkbVvNxuVA/2HbxTSq6vL/Jd5LVooKA3yLVqnAD4R5QmI6 ChTcfkXvaBBXGBvoj+WR3ejEngj1zKKJKcSf/LwIQH3FXmRiFhly0vAKpM4XeaeMHRoN dqINK59K6d8srkXxQL/wWDunzl0eXFjwWnNp4xDtx7GPHLCctGHnm2d3yNdBlr7e9s2u eqs5BFv+ECB48zXhhJQU3IyCBGAMcE6B1UiEC2DfMliuX/YQg6nQAXNhlm9f1oJyYxAC vJrg== 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; bh=JLEuhC2updjeyj6C6/H8FM3q6Og+u3grGWIQdKvOyho=; fh=GKTx8bZTxxktPtJHOCqn0DEwubWWzblUWMU1PIrxjQg=; b=uPhh8JdHF9Q3SNCl56n1UTwHIFIdd1xvi5smcv19BaWk+B6alAoXv6dzC7Us9UACeu kIG7NRFcv4UN98S3is/+DgAY32IrdU+WtRdXTwBOKlICfukfxo3JLRSjNafD2MV4WMXJ vQkKwWf2TktD0pjvU3mJUwE+gtqRF2vKmhSVT9A0b9tKOn78te8IPhT7OFVx8euOdE6z Ymn9lmzXPClFS+P/Vh5qUxd0fAnPJ6cSmuIVvW578gVPyy/3JXlVE7KHoP/zjxGFm2SJ CHYHobXAyQjmUoMFl1XueG6oD1/gRxD2XS3W0BleYpeIGmW+yDUQ9rIhkrKRIEO3BLey 6kiQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=sntech.de dmarc=pass fromdomain=sntech.de); spf=pass (google.com: domain of linux-kernel+bounces-216184-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-216184-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=sntech.de Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id 41be03b00d2f7-70570683168si3089686a12.558.2024.06.16.01.00.26 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 16 Jun 2024 01:00:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-216184-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=sntech.de dmarc=pass fromdomain=sntech.de); spf=pass (google.com: domain of linux-kernel+bounces-216184-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-216184-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=sntech.de 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 6D58128289C for ; Sun, 16 Jun 2024 08:00:25 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5E6C718413D; Sun, 16 Jun 2024 08:00:18 +0000 (UTC) Received: from gloria.sntech.de (gloria.sntech.de [185.11.138.130]) (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 E7A8016D33E; Sun, 16 Jun 2024 08:00:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.11.138.130 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718524817; cv=none; b=jyooDlwRF8eR0j81/UZYngWkON1t5hR63is3igmqdJnTPPB1AFTMd7mtGPgYiQY0tcKo3iL0VBMdPIHCqvLt9F5sIQoerlqAsOMcsw0elN40glVMe1gkJGdF3Npm0up01ZUcXtB4ZtR+AK6GIJXoqFmW3drNbpRI+d0KOX5I5+g= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718524817; c=relaxed/simple; bh=Kx9wz1mFls9/uJS/vpae1QpuUfW4zPS3SusOm+sxWXQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=AlVi7tXSErSntSTOXazmeMH1UgkQKrjmYN9TeFh4bNosKH7tGpS8lU0+1NsW0qNMaXkgFGMrYaxsWEBJItqbS0T6OP2w+KkAracSDC1+UqGgLm4ifB49dl98/LXTaI1MtAc/fpVjIVbCbUHvgNRwWSoQ4pKHP29bZiseibxHao0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sntech.de; spf=pass smtp.mailfrom=sntech.de; arc=none smtp.client-ip=185.11.138.130 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sntech.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sntech.de Received: from 79-98-74-242.sys-data.com ([79.98.74.242] helo=phil.localnet) by gloria.sntech.de with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sIko5-0000Vp-S0; Sun, 16 Jun 2024 10:00:09 +0200 From: Heiko Stuebner To: Andy Shevchenko Cc: Sam Protsenko , Krzysztof Kozlowski , linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-samsung-soc@vger.kernel.org, Michael Turquette , Stephen Boyd , Krzysztof Kozlowski , Sylwester Nawrocki , Chanwoo Choi , Alim Akhtar , Nobuhiro Iwamatsu Subject: Re: [PATCH v1 2/4] clk: rockchip: Switch to use kmemdup_array() Date: Sun, 16 Jun 2024 10:00:07 +0200 Message-ID: <6087515.R56niFO833@phil> In-Reply-To: References: <20240606161028.2986587-1-andriy.shevchenko@linux.intel.com> <8182279.JRmrKFJ9eK@diego> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" Am Dienstag, 11. Juni 2024, 15:20:05 CEST schrieb Andy Shevchenko: > On Fri, Jun 07, 2024 at 10:13:04AM +0200, Heiko St=FCbner wrote: > > Am Donnerstag, 6. Juni 2024, 18:09:32 CEST schrieb Andy Shevchenko: >=20 > ... >=20 > > > - cpuclk->rate_table =3D kmemdup(rates, > > > - sizeof(*rates) * nrates, > > > - GFP_KERNEL); > > > + cpuclk->rate_table =3D kmemdup_array(rates, nrates, sizeof(*rates), > > > + GFP_KERNEL); > >=20 > > are you sure the param order is correct? > >=20 > > According to [0], it's (src, element_size, count, gfp), while above > > (and below) element_size and count seems switched in the > > kmemdup_array calls. >=20 > I'm glad you asked. The parameter order is going to be fixed [1]. >=20 > > [0] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/= tree/mm/util.c#n149 >=20 > [1]: 0ee14725471c ("mm/util: Swap kmemdup_array() arguments") ah that clears it up :-) Thanks for the pointer Heiko