[LTP] [PATCH v2] fork13: Fix the doc

Petr Vorel pvorel@suse.cz
Wed Feb 19 09:55:02 CET 2025


Hi Ma Xinjian,

...
> +++ b/testcases/kernel/syscalls/fork/fork13.c
> @@ -15,21 +15,22 @@
>   * implementation.  Furthermore, many shell scripts assume that pid
>   * numbers will not be used for some length of time.
>   *
> - * [Race Description]
> - * ---------------------------------------------------------------------
> - * A                                B
> + * [Race Description] ::
>   *
> - * // pid == offset == n            // pid == offset == n + 1
> - * test_and_set_bit(offset, map->page)
> - *                                  test_and_set_bit(offset, map->page);
> - *                                  pid_ns->last_pid = pid;
> - * pid_ns->last_pid = pid;
> - *                                  // pid == n + 1 is freed (wait())
> + *    ---------------------------------------------------------------------
I removed these --- lines (they were for asciidoc code formatting).

> + *    A                                B
>   *
> - *                                  // Next fork()...
> - *                                  last = pid_ns->last_pid; // == n
> - *                                  pid = last + 1;
> - * ---------------------------------------------------------------------
> + *    // pid == offset == n            // pid == offset == n + 1
> + *    test_and_set_bit(offset, map->page)
And increase indent on the right side.

Thanks, merged!

Kind regards,
Petr


More information about the ltp mailing list