#include <linux/clk/renesas.h>
#include <linux/console.h>
#include <linux/delay.h>
#include <linux/io.h>
#include <linux/iopoll.h>
#include <linux/of.h>
#include <linux/of_address.h>
#include <linux/pm.h>
#include <linux/pm_clock.h>
#include <linux/pm_domain.h>
#include <linux/slab.h>
#define SPDCR …
#define SWUCR …
#define PSTR …
#define PSTR_RETRIES …
#define PSTR_DELAY_US …
struct rmobile_pm_domain { … };
static inline
struct rmobile_pm_domain *to_rmobile_pd(struct generic_pm_domain *d)
{ … }
static int rmobile_pd_power_down(struct generic_pm_domain *genpd)
{ … }
static int __rmobile_pd_power_up(struct rmobile_pm_domain *rmobile_pd)
{ … }
static int rmobile_pd_power_up(struct generic_pm_domain *genpd)
{ … }
static void rmobile_init_pm_domain(struct rmobile_pm_domain *rmobile_pd)
{ … }
static int rmobile_pd_suspend_console(void)
{ … }
enum pd_types { … };
#define MAX_NUM_SPECIAL_PDS …
static struct special_pd { … } special_pds[MAX_NUM_SPECIAL_PDS] __initdata;
static unsigned int num_special_pds __initdata;
static const struct of_device_id special_ids[] __initconst = …;
static void __init add_special_pd(struct device_node *np, enum pd_types type)
{ … }
static void __init get_special_pds(void)
{ … }
static void __init put_special_pds(void)
{ … }
static enum pd_types __init pd_type(const struct device_node *pd)
{ … }
static void __init rmobile_setup_pm_domain(struct device_node *np,
struct rmobile_pm_domain *pd)
{ … }
static int __init rmobile_add_pm_domains(void __iomem *base,
struct device_node *parent,
struct generic_pm_domain *genpd_parent)
{ … }
static int __init rmobile_init_pm_domains(void)
{ … }
core_initcall(rmobile_init_pm_domains);