Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp1887849imj; Sun, 17 Feb 2019 17:38:14 -0800 (PST) X-Google-Smtp-Source: AHgI3IaivtBqRqVeBjhE2JCAG3xXNXBD6DI7Ju3myuIjqAaof0tIPlTPpPQ8LK/jPNU41NRNrEwO X-Received: by 2002:a63:1b49:: with SMTP id b9mr16553697pgm.112.1550453894104; Sun, 17 Feb 2019 17:38:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550453894; cv=none; d=google.com; s=arc-20160816; b=i3hzmbLHtFIRbM0hy98lrXuNqilJ4f/ZN3J2C9DJbFtiEpJB/VECQJTpscvTz7oPac 7Pt6+2x70T6+mJM4Xpxh1tkvi0g6O75oIyZ5cx9ENF373l8lwgs/lSqyWSMtU70oCY+/ q9YTxD584FG/XKoVTox5P4w2uTjI9XIz29ZKbXB9BibgeD++LNhUTEG2MkUenEAZdvDj vPQsDNI/dx5kw7YdIJVWVGevBXXtAorQ/oCT/TEsA1HEvTw6mO6aNjiI+mTTzLEuKXLN FFLa8GH/UuzG/aozD6jQFK+DFpoUTwtRKwFCtvENnYoDsdzGD+pWg9rVezaH+G+ZEWcz VQCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:subject:cc:to:from:message-id:date; bh=bTSZlsRt/Nd9D1f4efn7elxX+Lo2BjKx/75ddUeouKM=; b=BZtolbYY+p0X/keTfmTmvWMxuxjV/GFJpPNjCJtPphB9ofaY61F4rqtMGDDPG0zZo/ NxtFi6/0CvfpEbaq2NjJ/GPhmNaLVpzixvgGdDr7q46QFVmpRWpDiNmmNt9j94+rdMfR dJ0Mwt3LbszTaB14lC35qicm/6RYlTKOJrKkSwqO3Mg5opPK+ejQpG7yi/rsHN0OmTGV wVxkgWdO2ayO83CbOmJLRh2lMK081Jzcovj2XX37D9aw/ecZD9eIXyUl89wq3Txju7BN C/SwwFgEhJk+toVmEhjCME7I/Ipv2CKO4Dgn9RGKrRsKeRU60igbWlwXRDvOCbGBREuV dNIQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c10si11634446pgj.416.2019.02.17.17.37.58; Sun, 17 Feb 2019 17:38:14 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728122AbfBRBhj (ORCPT + 99 others); Sun, 17 Feb 2019 20:37:39 -0500 Received: from relmlor2.renesas.com ([210.160.252.172]:6442 "EHLO relmlie6.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726281AbfBRBhj (ORCPT ); Sun, 17 Feb 2019 20:37:39 -0500 Date: 18 Feb 2019 10:37:36 +0900 X-IronPort-AV: E=Sophos;i="5.58,382,1544454000"; d="scan'208";a="7900423" Received: from unknown (HELO relmlir6.idc.renesas.com) ([10.200.68.152]) by relmlie6.idc.renesas.com with ESMTP; 18 Feb 2019 10:37:36 +0900 Received: from morimoto-PC.renesas.com (unknown [10.166.18.140]) by relmlir6.idc.renesas.com (Postfix) with ESMTP id DA54241BDD93; Mon, 18 Feb 2019 10:37:36 +0900 (JST) Message-ID: <87lg2d51lv.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto To: Kuninori Morimoto Cc: Daniel Baluta , "broonie@kernel.org" , "vicencb@gmail.com" , "alsa-devel@alsa-project.org" , "tiwai@suse.com" , "lgirdwood@gmail.com" , "gregkh@linuxfoundation.org" , "linux-kernel@vger.kernel.org" , dl-linux-imx , "S.j. Wang" Subject: Re: [PATCH] ASoC: simple-card: Fix refcount underflow In-Reply-To: <87pnrp52jl.wl-kuninori.morimoto.gx@renesas.com> References: <20190216100927.10017-1-daniel.baluta@nxp.com> <87pnrp52jl.wl-kuninori.morimoto.gx@renesas.com> User-Agent: Wanderlust/2.15.9 Emacs/24.5 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Daniel, Mark, again > > of_get_child_by_name() takes a reference we'll need to drop > > later so when we substitute in top we need to take a reference > > as well as just assigning. > > > > Without this patch we hit the following error: > > > > [ 1.246852] OF: ERROR: Bad of_node_put() on /sound-wm8524 > > [ 1.262261] Hardware name: NXP i.MX8MQ EVK (DT) > > [ 1.266807] Workqueue: events deferred_probe_work_func > > [ 1.271950] Call trace: > > [ 1.274406] dump_backtrace+0x0/0x158 > > [ 1.278074] show_stack+0x14/0x20 > > [ 1.281396] dump_stack+0xa8/0xcc > > [ 1.284717] of_node_release+0xb0/0xc8 > > [ 1.288474] kobject_put+0x74/0xf0 > > [ 1.291879] of_node_put+0x14/0x28 > > [ 1.295286] __of_get_next_child+0x44/0x70 > > [ 1.299387] of_get_next_child+0x3c/0x60 > > [ 1.303315] simple_for_each_link+0x1dc/0x230 > > [ 1.307676] simple_probe+0x80/0x540 > > [ 1.311256] platform_drv_probe+0x50/0xa0 > > > > This patch is based on an earlier version posted by Kuninori Morimoto > > and commit message includes explanations from Mark Brown. > > > > https://patchwork.kernel.org/patch/10814255/ > > > > Reported-by: Vicente Bergas > > Signed-off-by: Daniel Baluta > > --- > > I'm not sure which one is correct in this case > > Signed-off-by: Kuninori Morimoto > > or > > Acked-by: Kuninori Morimoto And we want to add Fixes: commit da215354eb55c ("ASoC: simple-card: merge simple-scu-card")