From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757544AbcIHRih (ORCPT ); Thu, 8 Sep 2016 13:38:37 -0400 Received: from mail-oi0-f47.google.com ([209.85.218.47]:33716 "EHLO mail-oi0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756331AbcIHRib (ORCPT ); Thu, 8 Sep 2016 13:38:31 -0400 From: Kevin Hilman To: Ulf Hansson Cc: Dave Gerlach , Nishanth Menon , "Rafael J. Wysocki" , Keerthy , Peter Ujfalusi , Tero Kristo , Russell King , Sudeep Holla , Santosh Shilimkar , "linux-kernel\@vger.kernel.org" , "devicetree\@vger.kernel.org" , "linux-arm-kernel\@lists.infradead.org" , "linux-pm\@vger.kernel.org" , Jon Hunter Subject: Re: [PATCH 3/3] soc: ti: Add ti_sci_pm_domains driver Organization: BayLibre References: <20160819235653.26355-1-nm@ti.com> <20160819235653.26355-4-nm@ti.com> <57C0D2C9.1030801@ti.com> <57C5E1DA.2040405@ti.com> <57CF26DB.4020807@ti.com> <7h4m5rv9kz.fsf@baylibre.com> Date: Thu, 08 Sep 2016 10:38:27 -0700 In-Reply-To: (Ulf Hansson's message of "Thu, 8 Sep 2016 11:27:52 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (darwin) MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Ulf Hansson writes: > [...] > >> >> One more idea... >> >> Since you don't really have a domain (a group of devices), what you >> really have is each device having an independent power switch, so as Ulf >> suggested, what you really need is for all the devices to share the same >> set of runtime PM callbacks that call SCI. The only difference is the >> unique ID. >> >> Rather than using all of genpd, you could also just use a pm_domain >> which is what genpd is built on top of (and also omap_device, which >> you're probably familiar with also.) > > Even if this would work as well, the downside would be that you need > to re-invent the parts related to the DT parsing, the probing/removal > and attaching/detaching of the device to the PM domain. > > You probably don't want to go there... :-) All you'd need to read from DT would be the device-specific ID for TI-SCI, and that could be done at bind time with a notifier. The, in that same notifier, if a TI-SCI ID exists, it would get added to the pm_domain. Anyways, your original proposal is much preferred if it can work. I'm just throwing out another option because I really don't like one genpd per device. Kevin