Rev 1866 | Rev 2071 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1866 | Rev 2015 | ||
---|---|---|---|
Line 38... | Line 38... | ||
38 | #include <stdio.h> |
38 | #include <stdio.h> |
39 | #include <arch/barrier.h> |
39 | #include <arch/barrier.h> |
40 | #include <unistd.h> |
40 | #include <unistd.h> |
41 | #include <atomic.h> |
41 | #include <atomic.h> |
42 | #include <futex.h> |
42 | #include <futex.h> |
- | 43 | #include <sysinfo.h> |
|
43 | #include <ipc/services.h> |
44 | #include <ipc/services.h> |
44 | 45 | ||
45 | #include <sysinfo.h> |
46 | #include <sysinfo.h> |
46 | #include <as.h> |
47 | #include <as.h> |
47 | #include <ddi.h> |
48 | #include <ddi.h> |
Line 69... | Line 70... | ||
69 | sysarg_t s1, s2; |
70 | sysarg_t s1, s2; |
70 | sysarg_t rights; |
71 | sysarg_t rights; |
71 | int res; |
72 | int res; |
72 | 73 | ||
73 | if (!ktime) { |
74 | if (!ktime) { |
74 | mapping = as_get_mappable_page(PAGE_SIZE); |
75 | mapping = as_get_mappable_page(PAGE_SIZE, (int) |
- | 76 | sysinfo_value("clock.fcolor")); |
|
75 | /* Get the mapping of kernel clock */ |
77 | /* Get the mapping of kernel clock */ |
76 | res = ipc_call_sync_3(PHONE_NS, IPC_M_AS_AREA_RECV, (sysarg_t) mapping, PAGE_SIZE, SERVICE_MEM_REALTIME, NULL, &rights, NULL); |
78 | res = ipc_call_sync_3(PHONE_NS, IPC_M_AS_AREA_RECV, (sysarg_t) |
- | 79 | mapping, PAGE_SIZE, SERVICE_MEM_REALTIME, NULL, &rights, |
|
- | 80 | NULL); |
|
77 | if (res) { |
81 | if (res) { |
78 | printf("Failed to initialize timeofday memarea\n"); |
82 | printf("Failed to initialize timeofday memarea\n"); |
79 | _exit(1); |
83 | _exit(1); |
80 | } |
84 | } |
81 | if (! (rights & AS_AREA_READ)) { |
85 | if (! (rights & AS_AREA_READ)) { |