All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Bezdeka <florian.bezdeka@siemens.com>
To: xenomai@xenomai.org
Subject: [PATCH v5 4/5] y2038: lib/cobalt/mutex: dispatch mutex_timedlock
Date: Tue, 10 Aug 2021 12:23:43 +0200	[thread overview]
Message-ID: <20210810102344.49471-5-florian.bezdeka@siemens.com> (raw)
In-Reply-To: <20210810102344.49471-1-florian.bezdeka@siemens.com>

From: Song Chen <chensong_2000@189.cn>

In case the libc in use reports a 64 bit time_t dispacht
mutex_timedlock to the kernel entry point that accepts it.

Signed-off-by: Song Chen <chensong_2000@189.cn>
Signed-off-by: Florian Bezdeka <florian.bezdeka@siemens.com>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
 lib/cobalt/mutex.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/lib/cobalt/mutex.c b/lib/cobalt/mutex.c
index 29236c75a..73e45a1c4 100644
--- a/lib/cobalt/mutex.c
+++ b/lib/cobalt/mutex.c
@@ -479,7 +479,11 @@ slow_path:
 	}
 
 	do {
+#ifdef __USE_TIME_BITS64
+		ret = XENOMAI_SYSCALL2(sc_cobalt_mutex_timedlock64, _mutex, to);
+#else
 		ret = XENOMAI_SYSCALL2(sc_cobalt_mutex_timedlock, _mutex, to);
+#endif
 	} while (ret == -EINTR);
 
 	if (ret == 0)
-- 
2.30.2



  parent reply	other threads:[~2021-08-10 10:23 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-10 10:23 [PATCH v5 0/5] y2038: Add mutex_timedlock64() support Florian Bezdeka
2021-08-10 10:23 ` [PATCH v5 1/5] smokey: posix_mutex: Fix mutex/smokey_barrier leak Florian Bezdeka
2021-08-10 10:23 ` [PATCH v5 2/5] cobalt/posix/mutex: Harmonize pthread_mutex_timedlock() and sem_timedwait() Florian Bezdeka
2021-08-10 10:23 ` [PATCH v5 3/5] y2038: cobalt/posix/mutex: Adding mutex_timedlock64 Florian Bezdeka
2021-08-10 10:23 ` Florian Bezdeka [this message]
2021-08-10 10:23 ` [PATCH v5 5/5] y2038: testsuite/smokey/y2038: Adding test cases for mutex_timedlock64() Florian Bezdeka
2021-08-10 10:33 ` [PATCH v5 0/5] y2038: Add mutex_timedlock64() support Jan Kiszka
2021-08-10 10:38   ` Jan Kiszka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210810102344.49471-5-florian.bezdeka@siemens.com \
    --to=florian.bezdeka@siemens.com \
    --cc=xenomai@xenomai.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.