diff options
author | Paul Walmsley <paul@pwsan.com> | 2009-12-08 18:33:11 -0500 |
---|---|---|
committer | paul <paul@twilight.(none)> | 2009-12-11 19:00:41 -0500 |
commit | 6a06fa6863f190a0ed72f273a2ae5fedc89973ff (patch) | |
tree | 52a7ce94322be3024d3289542316f562505baa92 /arch/arm | |
parent | 33903eb55ae2a7f7cd980da619ae63d93c6530f3 (diff) |
OMAP clockdomain/powerdomain: optimize out sleepdep code on OMAP24xx
OMAP24xx chips don't support software-configurable sleep dependencies.
Test early for this so the compiler can redact the entire function body
on OMAP24xx.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-omap2/powerdomain.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/arm/mach-omap2/powerdomain.c b/arch/arm/mach-omap2/powerdomain.c index 9708f12bb8a0..41472670e4b4 100644 --- a/arch/arm/mach-omap2/powerdomain.c +++ b/arch/arm/mach-omap2/powerdomain.c | |||
@@ -571,10 +571,10 @@ int pwrdm_add_sleepdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) | |||
571 | { | 571 | { |
572 | struct powerdomain *p; | 572 | struct powerdomain *p; |
573 | 573 | ||
574 | if (!pwrdm1) | 574 | if (!cpu_is_omap34xx()) |
575 | return -EINVAL; | 575 | return -EINVAL; |
576 | 576 | ||
577 | if (!cpu_is_omap34xx()) | 577 | if (!pwrdm1) |
578 | return -EINVAL; | 578 | return -EINVAL; |
579 | 579 | ||
580 | p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); | 580 | p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); |
@@ -610,10 +610,10 @@ int pwrdm_del_sleepdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) | |||
610 | { | 610 | { |
611 | struct powerdomain *p; | 611 | struct powerdomain *p; |
612 | 612 | ||
613 | if (!pwrdm1) | 613 | if (!cpu_is_omap34xx()) |
614 | return -EINVAL; | 614 | return -EINVAL; |
615 | 615 | ||
616 | if (!cpu_is_omap34xx()) | 616 | if (!pwrdm1) |
617 | return -EINVAL; | 617 | return -EINVAL; |
618 | 618 | ||
619 | p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); | 619 | p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); |
@@ -653,10 +653,10 @@ int pwrdm_read_sleepdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) | |||
653 | { | 653 | { |
654 | struct powerdomain *p; | 654 | struct powerdomain *p; |
655 | 655 | ||
656 | if (!pwrdm1) | 656 | if (!cpu_is_omap34xx()) |
657 | return -EINVAL; | 657 | return -EINVAL; |
658 | 658 | ||
659 | if (!cpu_is_omap34xx()) | 659 | if (!pwrdm1) |
660 | return -EINVAL; | 660 | return -EINVAL; |
661 | 661 | ||
662 | p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); | 662 | p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); |