Skip to content

Commit

Permalink
Merge branches 'pm-domains', 'pm-sleep' and 'pm-cpufreq'
Browse files Browse the repository at this point in the history
* pm-domains:
  PM / Domains: provide pm_genpd_poweroff_noirq() stub
  Revert "PM / Domains: Handle safely genpd_syscore_switch() call on non-genpd device"

* pm-sleep:
  PM / sleep: constify attribute_group structures

* pm-cpufreq:
  cpufreq: intel_pstate: constify attribute_group structures
  cpufreq: cpufreq_stats: constify attribute_group structures
  • Loading branch information
Rafael J. Wysocki committed Jul 10, 2017
4 parents 408c986 + af3eb27 + 1d0c6e5 + 106c9c7 commit 15d56b3
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
5 changes: 3 additions & 2 deletions drivers/base/power/domain.c
Original file line number Diff line number Diff line change
Expand Up @@ -1148,8 +1148,8 @@ static void genpd_syscore_switch(struct device *dev, bool suspend)
{
struct generic_pm_domain *genpd;

genpd = genpd_lookup_dev(dev);
if (!genpd)
genpd = dev_to_genpd(dev);
if (!pm_genpd_present(genpd))
return;

if (suspend) {
Expand Down Expand Up @@ -1180,6 +1180,7 @@ EXPORT_SYMBOL_GPL(pm_genpd_syscore_poweron);
#define pm_genpd_resume_noirq NULL
#define pm_genpd_freeze_noirq NULL
#define pm_genpd_thaw_noirq NULL
#define pm_genpd_poweroff_noirq NULL
#define pm_genpd_restore_noirq NULL
#define pm_genpd_complete NULL

Expand Down
2 changes: 1 addition & 1 deletion drivers/cpufreq/cpufreq_stats.c
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ static struct attribute *default_attrs[] = {
&trans_table.attr,
NULL
};
static struct attribute_group stats_attr_group = {
static const struct attribute_group stats_attr_group = {
.attrs = default_attrs,
.name = "stats"
};
Expand Down
2 changes: 1 addition & 1 deletion drivers/cpufreq/intel_pstate.c
Original file line number Diff line number Diff line change
Expand Up @@ -1214,7 +1214,7 @@ static struct attribute *intel_pstate_attributes[] = {
NULL
};

static struct attribute_group intel_pstate_attr_group = {
static const struct attribute_group intel_pstate_attr_group = {
.attrs = intel_pstate_attributes,
};

Expand Down
2 changes: 1 addition & 1 deletion kernel/power/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -705,7 +705,7 @@ static struct attribute * g[] = {
NULL,
};

static struct attribute_group attr_group = {
static const struct attribute_group attr_group = {
.attrs = g,
};

Expand Down

0 comments on commit 15d56b3

Please sign in to comment.