From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934342AbcIUOhe (ORCPT ); Wed, 21 Sep 2016 10:37:34 -0400 Received: from hqemgate16.nvidia.com ([216.228.121.65]:18172 "EHLO hqemgate16.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933318AbcIUOha (ORCPT ); Wed, 21 Sep 2016 10:37:30 -0400 X-PGP-Universal: processed; by hqnvupgp08.nvidia.com on Wed, 21 Sep 2016 07:31:47 -0700 Subject: Re: [RFC PATCH 2/3] PM / Domains: Add support for devices with multiple domains To: Geert Uytterhoeven References: <1474367287-10402-1-git-send-email-jonathanh@nvidia.com> <1474367287-10402-3-git-send-email-jonathanh@nvidia.com> CC: "Rafael J. Wysocki" , Kevin Hilman , Ulf Hansson , Linux PM list , "linux-kernel@vger.kernel.org" , , Linux-Renesas From: Jon Hunter Message-ID: <658004af-e4f4-8b0c-cdc1-43661d331d70@nvidia.com> Date: Wed, 21 Sep 2016 15:37:14 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: X-Originating-IP: [10.21.132.118] X-ClientProxiedBy: DRUKMAIL101.nvidia.com (10.25.59.19) To UKMAIL101.nvidia.com (10.26.138.13) Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Geert, On 21/09/16 09:53, Geert Uytterhoeven wrote: > Hi Jon, > > On Tue, Sep 20, 2016 at 12:28 PM, Jon Hunter wrote: >> Some devices may require more than one PM domain to operate and this is >> not currently by the PM domain framework. Furthermore, the current Linux >> 'device' structure only allows devices to be associated with a single PM >> domain and so cannot easily be associated with more than one. To allow >> devices to be associated with more than one PM domain, if multiple >> domains are defined for a given device (eg. via device-tree), then: >> 1. Create a new PM domain for this device. The name of the new PM domain >> created matches the device name for which it was created for. >> 2. Register the new PM domain as a sub-domain for all PM domains >> required by the device. >> 3. Attach the device to the new PM domain. > > This looks a suboptimal to me: if you have n devices sharing the same PM > domains, you would add n new subdomains? BTW, would this be the case today for some renesas devices or are you just pointing this out as something that could be optimised/improved? Cheers Jon -- nvpublic