Changeset bf9afa07 in mainline for libc/generic/time.c
- Timestamp:
- 2006-06-02T11:35:05Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2d22049
- Parents:
- 49d072e
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libc/generic/time.c
r49d072e rbf9afa07 57 57 * sequence of subsequent gettimeofday calls is ordered. 58 58 */ 59 #define TMAREA (100*1024*1024)60 59 int gettimeofday(struct timeval *tv, struct timezone *tz) 61 60 { … … 66 65 67 66 if (!ktime) { 68 /* TODO: specify better, where to map the area */67 mapping = as_get_mappable_page(PAGE_SIZE); 69 68 /* Get the mapping of kernel clock */ 70 69 res = ipc_call_sync_3(PHONE_NS, IPC_M_AS_AREA_RECV, 71 TMAREA, 72 PAGE_SIZE, 73 0, 70 mapping, PAGE_SIZE, 0, 74 71 NULL,&rights,NULL); 75 72 if (res) { … … 80 77 printf("Received bad rights on time area: %X\n", 81 78 rights); 82 as_area_destroy( TMAREA);79 as_area_destroy(mapping); 83 80 _exit(1); 84 81 } 85 ktime = (void *) (TMAREA);82 ktime = mapping; 86 83 } 87 84 if (tz) {
Note:
See TracChangeset
for help on using the changeset viewer.