Received: by 10.223.176.46 with SMTP id f43csp303113wra; Tue, 23 Jan 2018 21:27:38 -0800 (PST) X-Google-Smtp-Source: AH8x227Py82vZmXpbfTnUEuEaqTs31EAnBdwa1h0Qt3+B7GL/gGFw8z2RVialNYQ2Xdk2tZ3lCyv X-Received: by 2002:a17:902:e81:: with SMTP id 1-v6mr6927379plx.235.1516771658640; Tue, 23 Jan 2018 21:27:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516771658; cv=none; d=google.com; s=arc-20160816; b=oeA/jckT0e8gxiA4R7zHk2BKnocAURdNf+UnOrILs3eyLH/+s1ya96nyjTl7wJQvbb A3yFCzzVGUPku3xKIJLs6n5Gui/uLEhlkZA2i93E0ZKdXY6Ri62Ju5Q26DRG9A3zm0cA rfqV/kNNqlnbjRlNGgw68tNi5ptRKoMgvCuUgkxDfwkk0BN70c1qrP/rydf3Fg8lVE0G hZupKC/8QxWIJDVY+EcsZF6oyos9R6iQhna8HySEJyXTVnSEudjT7DCO3TF1Kh7o5IMC COgPWlUEJJPEmQ1tQ3M9vhm+FFLwEmYrtWsHDeQkXpq7YdXjt86SnxPOmdCK+K/OqtlG pG6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=SD0MnEVXu2uc7IUkbsk4koDB5MDecPPUh9VvrNqdA8k=; b=MDs6gTdwDWzXK0bxfFheY+MLFA0JEHhKyPlhJEauruffoBjx3Nbzi2tvs3wziV3Hjj D417o/t4FxmY7fVIQqrgC1QiEGWye01/b3+qAab/wrxP0KrzI/c0p3+pnGNmm6hjWpr0 zXvF2QcHTwZuuCq7K70ggy0OWyRIaQz1gA3i5rfr3aNaksWEdoIu7bHRv5D2K/z0YKMO q/i5T2CS4M4S7a4Vp2vKyoduo4dmV2sA9/gTq1ChtUFxELXf0Jq14Uc889Ul2pA/NyUz q+K/Whdugp+RuWexLSGEsx2HMMufcR7VxUcuoSw2997tVamgIYdoqr9TjwLWOm/L+qYm EXug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=H1/o8mrd; 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; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c16si2334099pfe.336.2018.01.23.21.27.24; Tue, 23 Jan 2018 21:27:38 -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; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=H1/o8mrd; 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; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752394AbeAXF04 (ORCPT + 99 others); Wed, 24 Jan 2018 00:26:56 -0500 Received: from lelnx193.ext.ti.com ([198.47.27.77]:63856 "EHLO lelnx193.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751488AbeAXF0y (ORCPT ); Wed, 24 Jan 2018 00:26:54 -0500 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by lelnx193.ext.ti.com (8.15.1/8.15.1) with ESMTP id w0O5QDgK018959; Tue, 23 Jan 2018 23:26:13 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1516771573; bh=11VtPtQBL5RmgHauOSe3FA9fQeMlWeQdXX3avOUFzjg=; h=Subject:To:CC:References:From:Date:In-Reply-To; b=H1/o8mrdTDZfwV3i1wQbs43OdnpPUoauUwG+Ir+1nEmQpmiqmO9p3Z6G5Yq77UgQZ prF+Jvt2b++41DqSdJKcATuWu3TcPqHKKu4nlzkLw+b9uska5SI5VnAq9kB0oTqxKu Nt9Sa2f2L+W9RnZBOCF/E2LxChuEGeXoreRtmkKw= Received: from DLEE101.ent.ti.com (dlee101.ent.ti.com [157.170.170.31]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id w0O5QD70019346; Tue, 23 Jan 2018 23:26:13 -0600 Received: from DLEE108.ent.ti.com (157.170.170.38) by DLEE101.ent.ti.com (157.170.170.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1261.35; Tue, 23 Jan 2018 23:26:12 -0600 Received: from dflp33.itg.ti.com (10.64.6.16) by DLEE108.ent.ti.com (157.170.170.38) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1261.35 via Frontend Transport; Tue, 23 Jan 2018 23:26:12 -0600 Received: from [172.24.191.45] (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id w0O5Q7YD016901; Tue, 23 Jan 2018 23:26:08 -0600 Subject: Re: [PATCH 2/3] pwm: pwm-omap-dmtimer: Fix frequency when using prescaler To: Ladislav Michl , Claudiu Beznea CC: , , , , , , , , , , , , References: <20180117214629.GA11952@lenoch> <20180117214737.GC11952@lenoch> <3e00e721-984c-e8db-49f7-046d7b335404@microchip.com> <20180122105331.GA21159@lenoch> From: Keerthy Message-ID: Date: Wed, 24 Jan 2018 10:56:07 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <20180122105331.GA21159@lenoch> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Monday 22 January 2018 04:23 PM, Ladislav Michl wrote: > Dear Claudiu, > > On Mon, Jan 22, 2018 at 11:17:08AM +0200, Claudiu Beznea wrote: >> On 17.01.2018 23:47, Ladislav Michl wrote: >>> @@ -334,18 +348,18 @@ static int pwm_omap_dmtimer_probe(struct platform_device *pdev) >>> >>> mutex_init(&omap->mutex); >>> >>> - status = pwmchip_add(&omap->chip); >>> - if (status < 0) { >>> + ret = pwmchip_add(&omap->chip); >>> + if (ret < 0) { >>> dev_err(&pdev->dev, "failed to register PWM\n"); >>> - omap->pdata->free(omap->dm_timer); >>> - ret = status; >>> - goto put; >>> + goto free; >>> } >>> >>> platform_set_drvdata(pdev, omap); >> >From documentation: "of_parse_phandle(): Returns the device_node pointer with refcount >> incremented. Use of_node_put() on it when done." >> In case of success the of_node_put() should also be called as I see. > > Based on you previous suggestions found here: > https://patchwork.kernel.org/patch/10140209/ > I'd say this fix belongs to patch which introduces of_node_put() in the error > path. I'll then rebase this patches on top of the fix. Agreed. I missed the success path as i assumed only error paths needed te of_node_put(). I will post v8 of this patch alone as other patches can be left untouched. Hope that is okay. Regards, Keerthy > > Thank you, > ladis >