Changeset 582a0b8 in mainline for uspace/lib/posix/source
- Timestamp:
- 2017-05-08T19:20:39Z (8 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- d2c8533
- Parents:
- 73db198
- Location:
- uspace/lib/posix/source
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/posix/source/fcntl.c
r73db198 r582a0b8 39 39 #include "posix/fcntl.h" 40 40 41 #include "libc/unistd.h"42 41 #include "libc/vfs/vfs.h" 43 42 #include "posix/errno.h" -
uspace/lib/posix/source/time.c
r73db198 r582a0b8 49 49 #include "libc/stats.h" 50 50 #include "libc/stdbool.h" 51 #include "libc/stddef.h" 52 #include "libc/thread.h" 51 53 #include "libc/sys/time.h" 52 54 … … 313 315 // TODO: interruptible sleep 314 316 if (rqtp->tv_sec != 0) { 315 sleep(rqtp->tv_sec);317 thread_sleep(rqtp->tv_sec); 316 318 } 317 319 if (rqtp->tv_nsec != 0) { 318 usleep(rqtp->tv_nsec / 1000);320 thread_usleep(rqtp->tv_nsec / 1000); 319 321 } 320 322 return 0; -
uspace/lib/posix/source/unistd.c
r73db198 r582a0b8 49 49 #include "libc/vfs/vfs.h" 50 50 51 #include <libarch/config.h> 52 51 53 aoff64_t posix_pos[MAX_OPEN_FILES]; 52 54 … … 134 136 int posix_getpagesize(void) 135 137 { 136 return getpagesize();138 return PAGE_SIZE; 137 139 } 138 140 … … 384 386 stats_physmem_t *mem_stats = stats_get_physmem(); 385 387 if (mem_stats) { 386 phys_pages = (long) (mem_stats->total / getpagesize());387 avphys_pages = (long) (mem_stats->free / getpagesize());388 phys_pages = (long) (mem_stats->total / posix_getpagesize()); 389 avphys_pages = (long) (mem_stats->free / posix_getpagesize()); 388 390 free(mem_stats); 389 391 mem_stats = 0; … … 396 398 return avphys_pages; 397 399 case _SC_PAGESIZE: 398 return getpagesize();400 return posix_getpagesize(); 399 401 case _SC_CLK_TCK: 400 402 return clk_tck;
Note:
See TracChangeset
for help on using the changeset viewer.