[LTP] [PATCH v2] posix_fadvise: Convert docs to docparse

Shiyang Ruan ruansy.fnst@fujitsu.com
Wed Feb 5 11:10:48 CET 2025


Hi

ping~


在 2025/1/16 16:46, Shiyang Ruan 写道:
> Signed-off-by: Shiyang Ruan <ruansy.fnst@fujitsu.com>
> ---
>   .../kernel/syscalls/fadvise/posix_fadvise01.c | 18 ++++--------------
>   .../kernel/syscalls/fadvise/posix_fadvise02.c | 18 ++++--------------
>   .../kernel/syscalls/fadvise/posix_fadvise03.c | 19 +++++--------------
>   .../kernel/syscalls/fadvise/posix_fadvise04.c | 18 ++++--------------
>   4 files changed, 17 insertions(+), 56 deletions(-)
> 
> diff --git a/testcases/kernel/syscalls/fadvise/posix_fadvise01.c b/testcases/kernel/syscalls/fadvise/posix_fadvise01.c
> index 71e6454d8..2c6d57941 100644
> --- a/testcases/kernel/syscalls/fadvise/posix_fadvise01.c
> +++ b/testcases/kernel/syscalls/fadvise/posix_fadvise01.c
> @@ -1,23 +1,13 @@
>   // SPDX-License-Identifier: GPL-2.0-or-later
>   /*
>    * Copyright (c) Red Hat Inc., 2007
> + * Author: Masatake YAMATO <yamato@redhat.com>
>    */
>   
> -/*
> - * NAME
> - *	posix_fadvise01.c
> - *
> - * DESCRIPTION
> - *	Check the value that posix_fadvise returns for wrong ADVISE value.
> - *
> - * USAGE
> - *	posix_fadvise01
> - *
> - * HISTORY
> - *	11/2007 Initial version by Masatake YAMATO <yamato@redhat.com>
> +/*\
> + * [Description]
>    *
> - * RESTRICTIONS
> - *	None
> + * Verify that posix_fadvise() returns 0 for permissible ADVISE value.
>    */
>   
>   #include <fcntl.h>
> diff --git a/testcases/kernel/syscalls/fadvise/posix_fadvise02.c b/testcases/kernel/syscalls/fadvise/posix_fadvise02.c
> index 303f776e4..bbfbd102e 100644
> --- a/testcases/kernel/syscalls/fadvise/posix_fadvise02.c
> +++ b/testcases/kernel/syscalls/fadvise/posix_fadvise02.c
> @@ -1,23 +1,13 @@
>   // SPDX-License-Identifier: GPL-2.0-or-later
>   /*
>    * Copyright (c) Red Hat Inc., 2007
> + * Author: Masatake YAMATO <yamato@redhat.com>
>    */
>   
> -/*
> - * NAME
> - *	posix_fadvise02.c
> - *
> - * DESCRIPTION
> - *	Check the value that posix_fadvise returns for wrong file descriptor.
> - *
> - * USAGE
> - *	posix_fadvise02
> - *
> - * HISTORY
> - *	11/2007 Initial version by Masatake YAMATO <yamato@redhat.com>
> +/*\
> + * [Description]
>    *
> - * RESTRICTIONS
> - *	None
> + * Verify that posix_fadvise() returns EBADF for wrong file descriptor.
>    */
>   
>   #include <fcntl.h>
> diff --git a/testcases/kernel/syscalls/fadvise/posix_fadvise03.c b/testcases/kernel/syscalls/fadvise/posix_fadvise03.c
> index 98d8d2930..7bf500a2b 100644
> --- a/testcases/kernel/syscalls/fadvise/posix_fadvise03.c
> +++ b/testcases/kernel/syscalls/fadvise/posix_fadvise03.c
> @@ -1,23 +1,14 @@
>   // SPDX-License-Identifier: GPL-2.0-or-later
>   /*
>    * Copyright (c) Red Hat Inc., 2007
> + * Author: Masatake YAMATO <yamato@redhat.com>
>    */
>   
> -/*
> - * NAME
> - *	posix_fadvise03.c
> - *
> - * DESCRIPTION
> - *	Check the value that posix_fadvise returns for wrong ADVISE value.
> - *
> - * USAGE
> - *	posix_fadvise03
> - *
> - * HISTORY
> - *	11/2007 Initial version by Masatake YAMATO <yamato@redhat.com>
> +/*\
> + * [Description]
>    *
> - * RESTRICTIONS
> - *	None
> + * Verify that posix_fadvise() returns EINVAL for the ADVISE value not
> + * permissible on the architecture.
>    */
>   
>   #include <fcntl.h>
> diff --git a/testcases/kernel/syscalls/fadvise/posix_fadvise04.c b/testcases/kernel/syscalls/fadvise/posix_fadvise04.c
> index 8baf91bb0..beece6410 100644
> --- a/testcases/kernel/syscalls/fadvise/posix_fadvise04.c
> +++ b/testcases/kernel/syscalls/fadvise/posix_fadvise04.c
> @@ -1,23 +1,13 @@
>   // SPDX-License-Identifier: GPL-2.0-or-later
>   /*
>    * Copyright (c) Red Hat Inc., 2007
> + * Author: Masatake YAMATO <yamato@redhat.com>
>    */
>   
> -/*
> - * NAME
> - *	posix_fadvise04.c
> - *
> - * DESCRIPTION
> - *	Check the value that posix_fadvise returns for pipe descriptor.
> - *
> - * USAGE
> - *	posix_fadvise04
> - *
> - * HISTORY
> - *	11/2007 Initial version by Masatake YAMATO <yamato@redhat.com>
> +/*\
> + * [Description]
>    *
> - * RESTRICTIONS
> - *	None
> + * Verify that posix_fadvise() returns ESPIPE for pipe descriptor.
>    */
>   
>   #include <fcntl.h>


More information about the ltp mailing list