[PATCH V2 1/3] PM / Domains: Initial PM clock support for genpd
From: Ulf Hansson <hidden>
Date: 2014-11-28 07:26:28
Also in:
linux-pm, linux-samsung-soc
From: Ulf Hansson <hidden>
Date: 2014-11-28 07:26:28
Also in:
linux-pm, linux-samsung-soc
If you defined the flag as #define PM_DOMAIN_FLAGS_PM_CLK (1U << 0) (which is a kind of usual way to do that), you wouldn't need the bitops.h above. Moreover, I personally don't like #defines in struct definitions.quoted
@@ -76,6 +77,8 @@ struct generic_pm_domain { struct device *dev); void (*detach_dev)(struct generic_pm_domain *domain, struct device *dev); + unsigned int flags; /* Bit field of configs for genpd */ +#define PM_DOMAIN_PM_CLK BIT(0) /* PM domain uses PM clk */
While I fix your above comments, I wonder whether I actually also should change the prefix of the define as well.
From "PM_DOMAIN" to "GENPD". Cause I think it's a genpd specific
define and not a "PM domain" define. Please tell me if you have any objections to that.
quoted
}; static inline struct generic_pm_domain *pd_to_genpd(struct dev_pm_domain *pd)-- I speak only for myself. Rafael J. Wysocki, Intel Open Source Technology Center.
Thanks for review! Kind regards Uffe