PERFORCE change 144249 for review
Andrew Turner
andrew at FreeBSD.org
Sun Jun 29 00:17:38 UTC 2008
http://perforce.freebsd.org/chv.cgi?CH=144249
Change 144249 by andrew at andrew_bender on 2008/06/29 00:17:25
Enter into idle mode when there is no work to be done
Affected files ...
.. //depot/projects/arm/src/sys/arm/s3c2xx0/neo1973_machdep.c#7 edit
.. //depot/projects/arm/src/sys/arm/s3c2xx0/s3c2410.c#15 edit
.. //depot/projects/arm/src/sys/arm/s3c2xx0/s3c24x0var.h#3 edit
Differences ...
==== //depot/projects/arm/src/sys/arm/s3c2xx0/neo1973_machdep.c#7 (text+ko) ====
@@ -91,6 +91,7 @@
#include <machine/bus.h>
#include <sys/reboot.h>
+#include <arm/s3c2xx0/s3c24x0var.h>
#include <arm/s3c2xx0/s3c2410reg.h>
#define KERNEL_PT_SYS 0 /* Page table for mapping proc0 zero page */
@@ -211,6 +212,7 @@
boothowto = RB_SINGLE;
set_cpufuncs();
+ cpufuncs.cf_sleep = s3c24x0_sleep;
lastaddr = fake_preload_metadata();
pcpu_init(pcpup, 0, sizeof(struct pcpu));
==== //depot/projects/arm/src/sys/arm/s3c2xx0/s3c2410.c#15 (text+ko) ====
@@ -400,6 +400,16 @@
for(;;);
}
+void
+s3c24x0_sleep(int mode __unused)
+{
+ int reg;
+
+ reg = bus_space_read_4(&s3c2xx0_bs_tag, s3c2xx0_softc->sc_clkman_ioh, CLKMAN_CLKCON);
+ bus_space_write_4(&s3c2xx0_bs_tag, s3c2xx0_softc->sc_clkman_ioh, CLKMAN_CLKCON, reg | CLKCON_IDLE);
+}
+
+
int
arm_get_next_irq(void)
{
==== //depot/projects/arm/src/sys/arm/s3c2xx0/s3c24x0var.h#3 (text+ko) ====
@@ -44,4 +44,6 @@
void s3c24x0_clock_freq(struct s3c2xx0_softc *);
void s3c24x0_clock_freq2(vm_offset_t, int *, int *, int *);
+void s3c24x0_sleep(int);
+
#endif /* _ARM_S3C24X0VAR_H_ */
More information about the p4-projects
mailing list