Dmitry V. Levin | 2795a5f | 2014-12-06 03:53:16 +0000 | [diff] [blame] | 1 | #include "defs.h" |
| 2 | |
Dmitry V. Levin | 52572b6 | 2014-12-11 19:21:54 +0000 | [diff] [blame] | 3 | #ifdef HAVE_LINUX_FALLOC_H |
| 4 | # include <linux/falloc.h> |
| 5 | #endif |
| 6 | |
| 7 | #include "xlat/falloc_flags.h" |
| 8 | |
Dmitry V. Levin | a0bd374 | 2015-04-07 01:36:50 +0000 | [diff] [blame] | 9 | SYS_FUNC(fallocate) |
Dmitry V. Levin | 2795a5f | 2014-12-06 03:53:16 +0000 | [diff] [blame] | 10 | { |
| 11 | if (entering(tcp)) { |
| 12 | int argn; |
Dmitry V. Levin | 52572b6 | 2014-12-11 19:21:54 +0000 | [diff] [blame] | 13 | |
| 14 | /* fd */ |
| 15 | printfd(tcp, tcp->u_arg[0]); |
| 16 | tprints(", "); |
| 17 | |
| 18 | /* mode */ |
| 19 | printflags(falloc_flags, tcp->u_arg[1], "FALLOC_FL_???"); |
| 20 | tprints(", "); |
| 21 | |
| 22 | /* offset */ |
| 23 | argn = printllval(tcp, "%llu, ", 2); |
| 24 | |
| 25 | /* len */ |
| 26 | printllval(tcp, "%llu", argn); |
Dmitry V. Levin | 2795a5f | 2014-12-06 03:53:16 +0000 | [diff] [blame] | 27 | } |
| 28 | return 0; |
| 29 | } |