linux: Return unsupported if procfs can not be mount on tst-ttyname-namespace
commitd35fbd3e684e6bb5e5ec452ad8dac6ada8424bdd
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>
Mon, 12 Jun 2023 18:30:14 +0000 (12 15:30 -0300)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Wed, 28 Jun 2023 12:19:11 +0000 (28 09:19 -0300)
tree2d7d7c1b39f09e1ab59fb96740c5969401e1ec7d
parenta9fed5ea811c3fe3d5186d260494710d424786ef
linux: Return unsupported if procfs can not be mount on tst-ttyname-namespace

Trying to mount procfs can fail due multiples reasons: proc is locked
due the container configuration, mount syscall is filtered by a
Linux Secuirty Module, or any other security or hardening mechanism
that Linux might eventually add.

The tests does require a new procfs without binding to parent, and
to fully fix it would require to change how the container was created
(which is out of the scope of the test itself).  Instead of trying to
foresee any possible scenario, if procfs can not be mount fail with
unsupported.

Checked on aarch64-linux-gnu.
Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
sysdeps/unix/sysv/linux/tst-ttyname-namespace.c