Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp2808416pxb; Sun, 15 Nov 2020 19:05:28 -0800 (PST) X-Google-Smtp-Source: ABdhPJyOe1LA+wdILdta0tro469wD6fc3KPOVzRMlRMCsz84WPjpug3nn97iq8q/ev8eygGoMH4A X-Received: by 2002:a05:6402:3136:: with SMTP id dd22mr13274043edb.256.1605495928103; Sun, 15 Nov 2020 19:05:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605495928; cv=none; d=google.com; s=arc-20160816; b=u0vv7FmRXIqgLnnua6ifOv+4ml2RpmSr2GGbPCeCJlfrcLh9JS8h1GDCUxS68SL6QG Nhfwbsjg9Ud85Q7UnF7iWQLkMJgPWGVdx19OADB7OGrhjeRLOgSS7HiZxWDMCT17WS6R VFhdPMv8xYkaZr96OCHqHmD24JJ0lObLgwtjMN/KAYi4LSRx3I3OCzO7X6Lq9TrxDjrC Nf6xFJRxlDQsWyYNn3YLSI/uDWsUxVIWtrJ609vyLjes01x/HVzIl3wuCePq6AnZvkGO 0f+z0aIIm2jHFuuuaZcw+WKOaybLBfmJBH7Yr2beHcgQXw8HA0bOZu4pmqY9wIi2cc0P XmHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=5Lixo7STShzvL4Shbmq3YhowNswAkb873wBmSE1Y13w=; b=n16ZjApH/aimPzBMc54/NCknhJf+DZq63Mh++7APAR7QhO062TM51ZmtUM3oNb4BI9 RnZVN37baiegcDy3nXKiSOyZEI1KYJqAzWe0v7Tt0BDn+P1UvjOwehtCGjwREbTLrMnu AHCsO7C/vNGHQ1PHANW/krQz84MZ0gZy0m8DlH9vntsNKZ1/4AWEfUv7kvLGeJKNaFuU oZop25UDtdms8aXX59WN4JVMg10WM5TOU3cMqRVlzRqN1HFZksxBAPfWKDBUOpzHjkmQ fsEmdG6s0YJ1SMRcaUeVKedPCJZmQsOkF7fFbdipZjFC33zChH2+iKYtGlJ3FsPX4id+ ip7Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=dBRO2LdM; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g13si11299943edn.525.2020.11.15.19.05.05; Sun, 15 Nov 2020 19:05:28 -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=@gmail.com header.s=20161025 header.b=dBRO2LdM; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728298AbgKPAmd (ORCPT + 99 others); Sun, 15 Nov 2020 19:42:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58656 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728080AbgKPAmd (ORCPT ); Sun, 15 Nov 2020 19:42:33 -0500 Received: from mail-wr1-x442.google.com (mail-wr1-x442.google.com [IPv6:2a00:1450:4864:20::442]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EE197C0613CF; Sun, 15 Nov 2020 16:42:32 -0800 (PST) Received: by mail-wr1-x442.google.com with SMTP id p1so16884828wrf.12; Sun, 15 Nov 2020 16:42:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=5Lixo7STShzvL4Shbmq3YhowNswAkb873wBmSE1Y13w=; b=dBRO2LdMURQbXCYeOgDMFzwf9OpuawKxB98cUFbNWVMA+RAYjhHucrv3WRdwgwkRYP a/R5o7COE0K/39wPh4FgBCsPWhB5AQ3ehckhoM2XFIctfyLfvCg9zgNCyvcf9UhPWC4T 9Js530aun26joscwa9VQV5OiebElbvCgREXj6uNmIcnySJ+kNMerTe/LUYHEp6k18aoh pcqozalBW3KfH7xaOdWzramtIEhLdPN23YMjihoiWfU3Z+OumikPx2yvU5KSKKdXh5Qz Fl+gKv2iTWqfArr4izj/gNkVaz1NPQipG3gdGnFwSZD0gYYwXRIHzaAAnlz28zhzPfO+ +ujg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=5Lixo7STShzvL4Shbmq3YhowNswAkb873wBmSE1Y13w=; b=dB8sT4z2t0F0NT/xPVGwUTxRgIv5Ggw5EUsxpLqvxSGLDfTITN5GPKp3A68VwyBHEM g2lU+YAInDXvOhBsnTU4PqzTo0FtNYJVvIz37+HFB2BKU7AIzvXKsGEgleBrj6z9/ATn JkczXLCe2HuosEIXdMCUPGnoVqrDEBdAzrxjkMp/Fn5L5YnkhWO/RwdcKD33zNIjAH/S zbRjPumuFgnMyi1mU4/HVhaZcmvS6FaRTZ0dPGHyfGEoQXVelzZqmGyj0oo8K2DQElXh tumsQKje//BELOyyI83fJRGt77u3VRNj/4yAcz+Ibm8XShmwB9sXJtLHS7E4BXBqcMj1 LDkA== X-Gm-Message-State: AOAM533AnzaH6lGxdcIHjqeV+2pnwr2HGH0/pF4DXKNGa53gxKfc2bXC DhswNmPzZv4MD1Rw/as6HNiUw+FpHPu0bNXpt3M= X-Received: by 2002:adf:fd0d:: with SMTP id e13mr15636451wrr.85.1605487351726; Sun, 15 Nov 2020 16:42:31 -0800 (PST) MIME-Version: 1.0 References: <2518c14df2f16cc3c4fee35499895a32513c174b.1604646059.git.viresh.kumar@linaro.org> In-Reply-To: <2518c14df2f16cc3c4fee35499895a32513c174b.1604646059.git.viresh.kumar@linaro.org> From: Qiang Yu Date: Mon, 16 Nov 2020 08:42:20 +0800 Message-ID: Subject: Re: [PATCH 5/7] drm/lima: dev_pm_opp_put_*() accepts NULL argument To: Viresh Kumar Cc: David Airlie , Daniel Vetter , linux-pm@vger.kernel.org, Vincent Guittot , Rafael Wysocki , Stephen Boyd , Nishanth Menon , digetx@gmail.com, dri-devel , lima@lists.freedesktop.org, Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Looks good for me, patch is: Reviewed-by: Qiang Yu Regards, Qiang On Fri, Nov 6, 2020 at 3:05 PM Viresh Kumar wrote: > > The dev_pm_opp_put_*() APIs now accepts a NULL opp_table pointer and so > there is no need for us to carry the extra check. Drop them. > > Signed-off-by: Viresh Kumar > --- > drivers/gpu/drm/lima/lima_devfreq.c | 13 ++++--------- > 1 file changed, 4 insertions(+), 9 deletions(-) > > diff --git a/drivers/gpu/drm/lima/lima_devfreq.c b/drivers/gpu/drm/lima/lima_devfreq.c > index bbe02817721b..e7b7b8dfd792 100644 > --- a/drivers/gpu/drm/lima/lima_devfreq.c > +++ b/drivers/gpu/drm/lima/lima_devfreq.c > @@ -110,15 +110,10 @@ void lima_devfreq_fini(struct lima_device *ldev) > devfreq->opp_of_table_added = false; > } > > - if (devfreq->regulators_opp_table) { > - dev_pm_opp_put_regulators(devfreq->regulators_opp_table); > - devfreq->regulators_opp_table = NULL; > - } > - > - if (devfreq->clkname_opp_table) { > - dev_pm_opp_put_clkname(devfreq->clkname_opp_table); > - devfreq->clkname_opp_table = NULL; > - } > + dev_pm_opp_put_regulators(devfreq->regulators_opp_table); > + dev_pm_opp_put_clkname(devfreq->clkname_opp_table); > + devfreq->regulators_opp_table = NULL; > + devfreq->clkname_opp_table = NULL; > } > > int lima_devfreq_init(struct lima_device *ldev) > -- > 2.25.0.rc1.19.g042ed3e048af >