Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp6090284pxu; Wed, 23 Dec 2020 13:14:07 -0800 (PST) X-Google-Smtp-Source: ABdhPJw6pWSSDeHnR29C8vjCg4rvUD8DLzLT2ZtzDhTHSDKmby9Yv9c5jG0RwYvwD6KLvaH+zZ7i X-Received: by 2002:a17:906:134f:: with SMTP id x15mr25792688ejb.278.1608758047234; Wed, 23 Dec 2020 13:14:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608758047; cv=none; d=google.com; s=arc-20160816; b=Fg9mHEzTULRJjw+Jk8ZcU8emR8ruQuya2/V2O7fsEJCYeiu20fF9WsQKbCTU2v8PHC QeVi6fq0oVqpt6Vu6VRd3dgNVXUvEhOiqJnU/CsleaColxBtY2O5JU9kSPdFpNBy/V1C Gj+zf6cVGevvtwycuYvGQCLSi5WwJtLOmwA2vVJn4Lgv6pJiS7M1mGDuR2BnqGvR9rty s3lZZ/aIOzMMSS6eps4ZjFcjsUr4dNoY9Ixe50ZsFl8xyoS/eRq5g+zdvn6sE64u/vFk /sa0BjuBlKtmAUyCfhBF2cdkAj6VlV4gJ/oCweGo0s3djsACndSlrSoJ5lTL/3mQf7iP M4mQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=q50TzHnXiMWvrNeC6K/yA9uOOIQSUZjSXQi5IJAXH+A=; b=gWzp+9AQg7Tf6Ql55Uva05a7cQd1DF1/7xQoldS4A4eGuty/18gLv1LSHslVe9Ae2U 1ci6sRcXnCt1Ljxxz2Zz9uoHyQtQMRVElEEzI9JsV4DlWudHGLu+4xZRHES6mVhv/3YX /VnB/HQtwhC/y3pDRXUAG5kwBPId1yakLXFdYTqDOMUnt17O2LU39buU2vWh8n3TwB4R KeBidBcr5zYVeT59dDft1SueB9MzyG3sh/TH1WDUUK2GV8BEU2/DVvpwNZSbBHKEB45L ZDsWa7kskZRYGUXkKlu6ksAJKYaNI9y9OVy7XI3HpTrk8mo2Bvm6C7jFncNDfvHCxB8J 7Smw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UtpPGvVi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dc4si13291071edb.417.2020.12.23.13.13.45; Wed, 23 Dec 2020 13:14:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UtpPGvVi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729231AbgLWVMb (ORCPT + 99 others); Wed, 23 Dec 2020 16:12:31 -0500 Received: from mail.kernel.org ([198.145.29.99]:49394 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726279AbgLWVMa (ORCPT ); Wed, 23 Dec 2020 16:12:30 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 10743223E4; Wed, 23 Dec 2020 21:11:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1608757910; bh=qA5zu6kLWTjMvdfo1scNBtwChRieVHSK00bO38S7dHw=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=UtpPGvViLwTfXb2WRIrZFzDgpGAAlvFQhp0ToOfInk0z7vRTpCO3nL4rrB8KmOcU+ 6lcVlCRZEITojcJe7OzxK7irYRpmHOnbvD0z7mGka73/xggWbzo42QKUUlZe+D6Nf5 B6TjMW8zwOQbiqxD4UDabaRkQa9egq/+np5ufB6/2KOUV5mOepOoCoSgPHxRMNy+Pn Ux+uNAtZRz3v0MpMwvEYbtqD5HSbuD2UZTZG3/70Vn6c+KRL8w1Zoew/FWVNvCm/nt 5nLdh7Zpqo1ka2bUcXKKcgo6REo000djrSVwyh8KdjznNpQVSt/+YB9Yc/QSoX+GIe iJwLTd4K3FIUA== Date: Wed, 23 Dec 2020 13:11:49 -0800 From: Jakub Kicinski To: Andrew Lunn Cc: Dinghao Liu , kjlu@umn.edu, "David S. Miller" , Jesse Brandeburg , Arnd Bergmann , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] net: ethernet: Fix memleak in ethoc_probe Message-ID: <20201223131149.15fff8d2@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> In-Reply-To: <20201223210044.GA3253993@lunn.ch> References: <20201223110615.31389-1-dinghao.liu@zju.edu.cn> <20201223153304.GD3198262@lunn.ch> <20201223123218.1cf7d9cb@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> <20201223210044.GA3253993@lunn.ch> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 23 Dec 2020 22:00:44 +0100 Andrew Lunn wrote: > On Wed, Dec 23, 2020 at 12:32:18PM -0800, Jakub Kicinski wrote: > > On Wed, 23 Dec 2020 16:33:04 +0100 Andrew Lunn wrote: > > > On Wed, Dec 23, 2020 at 07:06:12PM +0800, Dinghao Liu wrote: > > > > When mdiobus_register() fails, priv->mdio allocated > > > > by mdiobus_alloc() has not been freed, which leads > > > > to memleak. > > > > > > > > Signed-off-by: Dinghao Liu > > > > > > Fixes: bfa49cfc5262 ("net/ethoc: fix null dereference on error exit path") > > > > > > Reviewed-by: Andrew Lunn > > > > Ooof, I applied without looking at your email and I added: > > > > Fixes: e7f4dc3536a4 ("mdio: Move allocation of interrupts into core") > > [Goes and looks deeper] > > Yes, commit e7f4dc3536a4 looks like it introduced the original > problem. bfa49cfc5262 just moved to code around a bit. > > Does patchwork not automagically add Fixes: lines from full up emails? > That seems like a reasonable automation. Looks like it's been a TODO for 3 years now: https://github.com/getpatchwork/patchwork/issues/151 :(