* [LTP] [PATCH] lapi/tls.h: Cleanup ifdefs
@ 2026-01-22 17:53 Petr Vorel
2026-01-23 1:24 ` Li Wang via ltp
2026-01-26 8:47 ` Andrea Cervesato via ltp
0 siblings, 2 replies; 4+ messages in thread
From: Petr Vorel @ 2026-01-22 17:53 UTC (permalink / raw)
To: ltp
fe24196ce3 added .supported_archs into clone10. Therefore there is no
need to keep architecture check also in lapi/tls.h.
Moreover "Unsupported architecture for TLS" was misleading as it looked
as a missing arch support in kernel, but it's our allocate_tls_area()
implementation which does support only 3 architectures.
Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
Hi,
based on a recent discussion on ML
https://lore.kernel.org/ltp/20260122130634.GA71214@pevik/
Kind regards,
Petr
include/lapi/tls.h | 6 ------
1 file changed, 6 deletions(-)
diff --git a/include/lapi/tls.h b/include/lapi/tls.h
index f7e2f483fe..468fe3086d 100644
--- a/include/lapi/tls.h
+++ b/include/lapi/tls.h
@@ -52,22 +52,16 @@ static inline void *allocate_tls_area(void)
static inline void init_tls(void)
{
-#if defined(__x86_64__) || defined(__aarch64__) || defined(__s390x__)
tls_ptr = allocate_tls_area();
-#else
- tst_brk(TCONF, "Unsupported architecture for TLS");
-#endif
}
static inline void free_tls(void)
{
usleep(10000);
-#if defined(__x86_64__) || defined(__aarch64__) || defined(__s390x__)
if (tls_ptr) {
free(tls_ptr);
tls_ptr = NULL;
}
-#endif
}
#endif /* LAPI_TLS_H__ */
--
2.51.0
--
Mailing list info: https://lists.linux.it/listinfo/ltp
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [LTP] [PATCH] lapi/tls.h: Cleanup ifdefs
2026-01-22 17:53 [LTP] [PATCH] lapi/tls.h: Cleanup ifdefs Petr Vorel
@ 2026-01-23 1:24 ` Li Wang via ltp
2026-01-26 8:47 ` Andrea Cervesato via ltp
1 sibling, 0 replies; 4+ messages in thread
From: Li Wang via ltp @ 2026-01-23 1:24 UTC (permalink / raw)
To: Petr Vorel; +Cc: ltp
Reviewed-by: Li Wang <liwang@redhat.com>
--
Regards,
Li Wang
On Fri, Jan 23, 2026 at 1:54 AM Petr Vorel <pvorel@suse.cz> wrote:
>
> fe24196ce3 added .supported_archs into clone10. Therefore there is no
> need to keep architecture check also in lapi/tls.h.
>
> Moreover "Unsupported architecture for TLS" was misleading as it looked
> as a missing arch support in kernel, but it's our allocate_tls_area()
> implementation which does support only 3 architectures.
>
> Signed-off-by: Petr Vorel <pvorel@suse.cz>
> ---
> Hi,
>
> based on a recent discussion on ML
> https://lore.kernel.org/ltp/20260122130634.GA71214@pevik/
>
> Kind regards,
> Petr
>
> include/lapi/tls.h | 6 ------
> 1 file changed, 6 deletions(-)
>
> diff --git a/include/lapi/tls.h b/include/lapi/tls.h
> index f7e2f483fe..468fe3086d 100644
> --- a/include/lapi/tls.h
> +++ b/include/lapi/tls.h
> @@ -52,22 +52,16 @@ static inline void *allocate_tls_area(void)
>
> static inline void init_tls(void)
> {
> -#if defined(__x86_64__) || defined(__aarch64__) || defined(__s390x__)
> tls_ptr = allocate_tls_area();
> -#else
> - tst_brk(TCONF, "Unsupported architecture for TLS");
> -#endif
> }
>
> static inline void free_tls(void)
> {
> usleep(10000);
> -#if defined(__x86_64__) || defined(__aarch64__) || defined(__s390x__)
> if (tls_ptr) {
> free(tls_ptr);
> tls_ptr = NULL;
> }
> -#endif
> }
>
> #endif /* LAPI_TLS_H__ */
> --
> 2.51.0
>
--
Regards,
Li Wang
--
Mailing list info: https://lists.linux.it/listinfo/ltp
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [LTP] [PATCH] lapi/tls.h: Cleanup ifdefs
2026-01-22 17:53 [LTP] [PATCH] lapi/tls.h: Cleanup ifdefs Petr Vorel
2026-01-23 1:24 ` Li Wang via ltp
@ 2026-01-26 8:47 ` Andrea Cervesato via ltp
2026-01-27 12:56 ` Li Wang via ltp
1 sibling, 1 reply; 4+ messages in thread
From: Andrea Cervesato via ltp @ 2026-01-26 8:47 UTC (permalink / raw)
To: Petr Vorel, ltp
Hi!
Reviewed-by: Andrea Cervesato <andrea.cervesato@suse.com>
--
Andrea Cervesato
SUSE QE Automation Engineer Linux
andrea.cervesato@suse.com
--
Mailing list info: https://lists.linux.it/listinfo/ltp
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [LTP] [PATCH] lapi/tls.h: Cleanup ifdefs
2026-01-26 8:47 ` Andrea Cervesato via ltp
@ 2026-01-27 12:56 ` Li Wang via ltp
0 siblings, 0 replies; 4+ messages in thread
From: Li Wang via ltp @ 2026-01-27 12:56 UTC (permalink / raw)
To: Andrea Cervesato; +Cc: ltp
Merged, thanks!
--
Regards,
Li Wang
--
Mailing list info: https://lists.linux.it/listinfo/ltp
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-01-27 12:57 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-22 17:53 [LTP] [PATCH] lapi/tls.h: Cleanup ifdefs Petr Vorel
2026-01-23 1:24 ` Li Wang via ltp
2026-01-26 8:47 ` Andrea Cervesato via ltp
2026-01-27 12:56 ` Li Wang via ltp
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox