diff options
| author | Louis Burda <quent.burda@gmail.com> | 2022-08-13 16:44:04 +0200 |
|---|---|---|
| committer | Louis Burda <quent.burda@gmail.com> | 2022-08-13 16:45:08 +0200 |
| commit | 98babf91dcf166bc7644a3d70a90dac272f12a75 (patch) | |
| tree | 529acab95367ae6ed35eddf0731ee82f73c94842 /access.c | |
| parent | 88d598bc2894c28d8dd9c2259c5c8cbe2ec7ce55 (diff) | |
| download | cachepc-98babf91dcf166bc7644a3d70a90dac272f12a75.tar.gz cachepc-98babf91dcf166bc7644a3d70a90dac272f12a75.zip | |
Reorder repo into module and tests
Diffstat (limited to 'access.c')
| -rw-r--r-- | access.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/access.c b/access.c deleted file mode 100644 index 1f16552..0000000 --- a/access.c +++ /dev/null @@ -1,29 +0,0 @@ -#include <stdlib.h> -#include <stdio.h> -#include <fcntl.h> -#include <stdint.h> -#include <err.h> -#include <fcntl.h> -#include <unistd.h> -#include <stropts.h> - -#include "cachepc_user.h" - -int -main(int argc, const char **argv) -{ - size_t i, len; - int fd, ret; - int count; - - fd = open("/proc/cachepc", O_RDONLY); - if (fd < 0) err(1, "open"); - - for (i = 0; i < 50; i++) { - ret = ioctl(fd, CACHEPC_IOCTL_ACCESS_TEST, &count); - if (ret == -1) err(1, "ioctl fail"); - printf("%i\n", count); - } - - close(fd); -} |
