File tree Expand file tree Collapse file tree 3 files changed +23
-31
lines changed
testcases/kernel/syscalls/pwritev Expand file tree Collapse file tree 3 files changed +23
-31
lines changed Original file line number Diff line number Diff line change 44* Author: Xiao Yang <[email protected] > 55*/
66
7- /*
8- * Test Name: pwritev01
9- *
10- * Test Description:
11- * Testcase to check the basic functionality of the pwritev(2).
12- * pwritev(2) should succeed to write the expected content of data
13- * and after writing the file, the file offset is not changed.
14- */
7+ /*\
8+ * [Description]
9+ *
10+ * Testcase to check the basic functionality of the pwritev(2).
11+ *
12+ * pwritev(2) should succeed to write the expected content of data
13+ * and after writing the file, the file offset is not changed.
14+ */
1515
1616#define _GNU_SOURCE
1717#include <string.h>
Original file line number Diff line number Diff line change 44* Author: Xiao Yang <[email protected] > 55*/
66
7- /*
8- * Test Name: pwritev02
9- *
10- * Description:
11- * 1) pwritev(2) fails if iov_len is invalid.
12- * 2) pwritev(2) fails if the vector count iovcnt is less than zero.
13- * 3) pwritev(2) fails if offset is negative.
14- * 4) pwritev(2) fails when attempts to write from a invalid address
15- * 5) pwritev(2) fails if file descriptor is invalid.
16- * 6) pwritev(2) fails if file descriptor is not open for writing.
17- * 7) pwritev(2) fails if fd is associated with a pipe.
18- *
19- * Expected Result:
20- * 1) pwritev(2) should return -1 and set errno to EINVAL.
21- * 2) pwritev(2) should return -1 and set errno to EINVAL.
22- * 3) pwritev(2) should return -1 and set errno to EINVAL.
23- * 4) pwritev(2) should return -1 and set errno to EFAULT.
24- * 5) pwritev(2) should return -1 and set errno to EBADF.
25- * 6) pwritev(2) should return -1 and set errno to EBADF.
26- * 7) pwritev(2) should return -1 and set errno to ESPIPE.
27- */
7+ /*\
8+ * [Description]
9+ *
10+ * - EINVAL when iov_len is invalid.
11+ * - EINVAL when the vector count iovcnt is less than zero.
12+ * - EINVAL when offset is negative.
13+ * - EFAULT when attempts to write from a invalid address
14+ * - EBADF when file descriptor is invalid.
15+ * - EBADF when file descriptor is not open for writing.
16+ * - ESPIPE when fd is associated with a pipe.
17+ */
2818
2919#define _GNU_SOURCE
3020
Original file line number Diff line number Diff line change 44 * Author: Xiao Yang <[email protected] > 55 */
66
7- /*
8- * Description:
7+ /*\
8+ * [Description]
9+ *
910 * Check the basic functionality of the pwritev(2) for the file
1011 * opened with O_DIRECT in all filesystem.
12+ *
1113 * pwritev(2) should succeed to write the expected content of data
1214 * and after writing the file, the file offset is not changed.
1315 */
You can’t perform that action at this time.
0 commit comments