Received: by 2002:a25:b323:0:0:0:0:0 with SMTP id l35csp1458170ybj; Fri, 20 Sep 2019 10:46:51 -0700 (PDT) X-Google-Smtp-Source: APXvYqwCvw0EBlf9rU1WorL4mVACj/h0mI5/3Aic31NTepyPA2whlrEQpBdguznuAET63A482XpJ X-Received: by 2002:a50:c351:: with SMTP id q17mr23322944edb.123.1569001611491; Fri, 20 Sep 2019 10:46:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569001611; cv=none; d=google.com; s=arc-20160816; b=n4ebccx38paMC8EDjl2gkRuo/E6I6Tf/vZ5LqqhoL2CMmW77vgXPAG2KJvWY1ZMTJs 2ilrdU7U9ygk6Rr3xgzTIHYOTCnJTC+eNzk+WmLsmnXeU6JM/UzD6I/MKCpVJtEWugg4 hza7PqcOjLxMMjdNmIjL3fJeaiVkOKOXE/NguTwkNp6PqI3s8nTvt5KwuagE4UDNrJA1 B8twChvcONaG9A3VjBNYv2uVyKf8Ue/OfywPrwj4egrb3ZXuJHICZKgouW5ioevbHrg4 CLthxr/42p7DtTtDEw34M71UcMVi3vl3sUFCgfA1FoU4K6M5fTswas2rIXu7pjzW+Q32 EFBQ== 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; bh=VWDis/zr7oKH8oIbhnKimRtX6SrwRwwmk275GS8fnN0=; b=lCV/sdYh7TfjL5J9Q3ER71lUt/ogntgvrHLGboCywgaHVpIE2vAN+4ky/i1qjaQsLm sU+Sk7I0+pp0hWA8p7WAQz97SoSqt45OUO0pfELcbTs7M6Ynu4ZK00Jhi/RvBI6W4Xkn iheG8xZMgEGUYmoPPjvJ09tFTFadC1ViZ2tW6/QA/Pq3qtBlRoHZv0ne3H6QX1wSY8H+ KEACq7Rl/8Pdg6WeTHjZMewwWuUj0pIPPTkuK4d8vtnC0KccC1trX5JK+q3MsjBUVr7N baODQ/qi/Ok8xtCpZgFdLi0pts+EiBF+glzVO8oxvQPppL8a+cvUnwRbZFriKODGBS2K 1bFA== 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 e14si1886503eda.104.2019.09.20.10.46.27; Fri, 20 Sep 2019 10:46:51 -0700 (PDT) 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 S2405018AbfITH5q (ORCPT + 99 others); Fri, 20 Sep 2019 03:57:46 -0400 Received: from mail-sh.amlogic.com ([58.32.228.43]:41549 "EHLO mail-sh.amlogic.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388411AbfITH5q (ORCPT ); Fri, 20 Sep 2019 03:57:46 -0400 Received: from [10.18.29.226] (10.18.29.226) by mail-sh.amlogic.com (10.18.11.5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1591.10; Fri, 20 Sep 2019 15:58:41 +0800 Subject: Re: [PATCH 2/3] soc: amlogic: Add support for Secure power domains controller To: Martin Blumenstingl CC: Kevin Hilman , , Zhiqiang Liang , Rob Herring , Neil Armstrong , Jerome Brunet , , , , , Jian Hu , Hanjie Lin , Victor Wan , Xingyu Chen References: <1568895064-4116-1-git-send-email-jianxin.pan@amlogic.com> <1568895064-4116-3-git-send-email-jianxin.pan@amlogic.com> From: Jianxin Pan Message-ID: Date: Fri, 20 Sep 2019 15:58:40 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.18.29.226] X-ClientProxiedBy: mail-sh.amlogic.com (10.18.11.5) To mail-sh.amlogic.com (10.18.11.5) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Martin, On 2019/9/20 4:03, Martin Blumenstingl wrote: > Hi Jianxin, > > I added three comments below from a quick glance at this driver (I > didn't have time for a complete review) > > On Thu, Sep 19, 2019 at 2:11 PM Jianxin Pan wrote: > [...] >> + pm_genpd_init(&dom->base, NULL, >> + (match->domains[i].get_power ? >> + match->domains[i].get_power(dom) : true)); > .get_power is never NULL in this driver so the ": true" part is > effectively a no-op > OK, I will remove it. Thanks for your time. > [...] >> +static const struct of_device_id meson_secure_pwrc_match_table[] = { >> + { >> + .compatible = "amlogic,meson-a1-pwrc", >> + .data = &meson_secure_a1_pwrc_data, >> + }, >> + { } > many drivers use a /* sentinel */ comment inside { } > OK, I will add this comment line. > [...] >> +arch_initcall_sync(meson_secure_pwrc_init); > why arch_initcall_sync instead of builtin_platform_driver? > $ grep -R arch_initcall_sync drivers/soc/ > $ > > > Martin > The power-domain is depended by many other drivers, arch_initcall_sync is used to make power-domain probe earlier. Maybe I need to switch back to builtin_platform_driver when use APIs from meson_sm.c. > . >