From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796140746; b=Kp3jqg+DdwhMys4CZAIBGfTnv7Nq+bEzHfhYzG6ejwmpW47Xb3hn2RRS+efDzFgpKHu5 n2H12a6VA6ZvYa+0TwQNhnIFVp1aBg0pWC95W9yyZuiw7NxJ6Xb7bixt1DFkDw95G4kCz 3sprWk9hJFIJj1TcjEYWiM1ufHD7sYRHHhEVO67eK9Ov78ouPdOMsu5ZInkOvfukPBn3R H4ZJacLPcqH2xvAMVjIfaO4EkJ9kAFeMQZS0dVYRfb4r+iPmw7Q8LXwgN+FsbCHGf8krE Nn/T0sX6mKqnpHTGsZcVT4um6ZZOe8YOK2zIJy8aj3VxG8h8onMWhkxkrcMHqMZXkxw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796140746; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=B8BdKAgxHzg+uSoaU6xyEC/JrNUhYygkctMm9gXmPIw=; b=psedr04Z00OEkE3kWi2BTeeCzezejf6yMwVra+x7iHaZtJKoN81P2RMFIkAaxKYTfGBZ lCSN5tkRYBHoB0jBBCV8AAeiLDlDC+pP6rh2co1KXbLlUOnBsNN2U2uN4yHSK62gvHixL 9Mfi8sgBwEKto3JYGoXWcb1dCeQTDbvEwpNxlrxoUcTb4NwyQYr11AFQUl5qvn+Yv0++c KWVluIVsc54A4RuiNR5qiHOFxxQvDjxylffsUmOrM/4Pcoafp0wUklbE9POQvJf/HNEeL 7RcmDav9r9hF+V+0jVjal+pI2rwE32/LrillesTLA9aWur2k1e7WIqqq81LnnXKMhHQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b="NCmmVaa/"; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 90E91606A320 for ; Tue, 1 Dec 2026 15:59:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=NCmmVaa/ Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4C99A1F000C1; Tue, 1 Dec 2026 15:59:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796140746; bh=B8BdKAgxHzg+uSoaU6xyEC/JrNUhYygkctMm9gXmPIw=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=NCmmVaa/v2GBhNwj1upRLmcwnqmv1CCmYiXevekamXX6/TuGrL7wHRykmSLmrOs5o I+Qs8QWDQ2mx3KbSi+g3CqD+iAbnbg5Z010ZMEUjXiiq7GLQG2ybdCtstR/iHwwdFi 664eNihwB6pYcVNBVzJ01YouJ0+MU3jDFZ1AfJg/y52OOnU/7dCqcJejlZcaxTP2Iu gkjr1aSLHblymVnJnGsOyJwWSgUTIAMAF8odSsAWqBrKXU9RtNlkilrmb9dZydb9Rl baQuZdFpgL9AIYck5cmIk8HhTk479h3gmBAZg+zd84VH+B2zYd1t7KvD6hMXFxutOW JVB56TrOpnDkg== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH linux-next] leds: netxbig: drop the second allocation of the leds array Reply-To: sashiko-reviews@lists.linux.dev To: "Sasha Levin" Cc: linux-leds@vger.kernel.org, lee@kernel.org In-Reply-To: <20261201155641.717600-1-sashal@kernel.org> References: <20261201155641.717600-1-sashal@kernel.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Tue, 01 Dec 2026 15:59:05 +0000 X-Mailing-List: linux-leds@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list > Since next-20261120 the merge of the leds-lj tree with the origin tree > allocates the leds array in netxbig_leds_get_of_pdata() twice: >=20 > leds =3D devm_kzalloc_objs(dev, *leds, num_leds); > leds =3D devm_kcalloc(dev, num_leds, sizeof(*leds), GFP_KERNEL); > if (!leds) > return -ENOMEM; >=20 > The first line is the origin side, from commit 4dd10fbbeb9c ("treewide: > Convert devm_kmalloc() family to the devm_kmalloc_obj() family"). The > second is the leds-lj side: commit 41ea2c75f886 ("leds: netxbig: Fix > platform device reference leak on successful probe") only changed the > error path below it. The first array is never used and stays allocated > until the device is unbound. >=20 > Keep the devm_kzalloc_objs() call and drop the devm_kcalloc() one, as > the merge does for the other allocations in this function. >=20 > Fixes: 7fa58f4b0c86 ("Merge branch 'for-leds-next' of https://git.kernel.= org/pub/scm/linux/kernel/git/lee/leds.git") > Link: https://lore.kernel.org/all/c05653b5-c8bd-46ca-aaf5-281e8d74f1e6@si= rena.org.uk/ > Signed-off-by: Sasha Levin Sashiko has reviewed this patch and found no issues. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261201155641.7176= 00-1-sashal@kernel.org?part=3D1