From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 C4D1736C0D6; Wed, 17 Jun 2026 23:44:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781739853; cv=none; b=BLLCWdmSDsAQpoTE8cqA9ZS3395DnNx/uS6CSNn4tOtlByN0PbKIg7Zqi00nCOO3eq5joEV8pn/WI2Rs+8nTM31h6dswe9YflXWrnbwKWOfW7NsreO2UZxlE6/A7SfCiAl+wbpr1kVM/O2LLCEhLWdR84R1enhCnBYc2d/WnKwY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781739853; c=relaxed/simple; bh=n+8cwEaVXErqF6WzIqE9szcvsqiSOD+DxUKRBL1NBno=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=Hmfa7IWJ0buIWul3J8NVNF9EvfgOrO520oenWqkIHI1yLL1O1Zp3eExgGkq7hXf0zXTflXYjx5k9S8XBRo06F1H9AIUUBsG+QnhPZ+MN2u4EPw5b/LTLtsDAMfxAJrOIRttXeH/oBuYyI/c156swJLY8fAil+GfMDk6HfZRfxOI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=HRUTaPcC; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="HRUTaPcC" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E00541F000E9; Wed, 17 Jun 2026 23:44:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1781739852; bh=qK7KTJY6sxQ3+gp4VQ4GNluoj9voS4ivxAftG1ha/mo=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=HRUTaPcCTQFXCUPAdzU+/hSYORtUOy9oojwpIUGiida4rjYe7LxBJOrlop/QcEUkU kZ0oWHvvm+zHCHkZA2KDxly+0WT3Ym2gU4IcMpT9C+QFK8pCgglSzPgrmeWVHlLr1u 4x8XFRo+0r4mSeQcnBzU6Z+alelYfXK4+84hRb1jRwmy500nUqBMgHm27EwLwmp/n+ tqTphNTgWa5UePVdzDz7hafFIJBOZ5tN9EM9U5v6S1ddr3rBotJxSFwe1dD8COkrjf TubvoNzGpizE2JUconbMp8QyWwCcmbf6rH4rI7XZZnLga5vFdCPO8bxPBK6jnSxCMs PbsVOnHaGE0JA== Date: Wed, 17 Jun 2026 16:44:11 -0700 From: Jakub Kicinski To: Andrew Lunn , Jiri Pirko Cc: Jacob Keller , Ziran Zhang , Andrew Lunn , "David S . Miller" , Eric Dumazet , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] rocker: Fix memory leak in ofdpa_port_fdb() Message-ID: <20260617164411.2a8a260e@kernel.org> In-Reply-To: <61892bd4-7368-4cd8-b360-0267e5c47156@lunn.ch> References: <20260616013245.7098-1-zhangcoder@yeah.net> <1446e974-0df0-4956-b2af-7a9403da3c8d@intel.com> <61892bd4-7368-4cd8-b360-0267e5c47156@lunn.ch> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Wed, 17 Jun 2026 11:26:46 +0200 Andrew Lunn wrote: > On Tue, Jun 16, 2026 at 04:29:59PM -0700, Jacob Keller wrote: > > On 6/15/2026 6:32 PM, Ziran Zhang wrote: > > > In ofdpa_port_fdb(), the hash_del() only unlinks the node from > > > hash table, but does not free it. > > > > > > Fix this by adding kfree(found) after the !found == removing check, > > > where the pointer value is no longer needed. > > > > > > Found by Coccinelle kfree script. > > Is rocker actually used any more? I'm not too sure of the history, but > was it not added as a way to develop the early switchdev code? There > was a qemu implementation of the 'hardware'? > > Is it still useful? Should we actually just remove the driver? I think it came up before but I don't remember the conclusion :S We should either add rocker to NIPA or delete it. Jiri, WDYT?