From: John Stultz <john.stultz@linaro.org>
To: Eugene Syromiatnikov <esyr@redhat.com>
Cc: Sergey Organov <sorganov@gmail.com>,
Thomas Gleixner <tglx@linutronix.de>,
Stephen Boyd <sboyd@kernel.org>,
Frederic Weisbecker <frederic@kernel.org>,
Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
"Eric W. Biederman" <ebiederm@xmission.com>,
lkml <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2] uapi, posix-timers: provide clockid-related macros and functions to UAPI
Date: Tue, 12 May 2020 15:40:07 -0700 [thread overview]
Message-ID: <CALAqxLUGr=+UjYhQSN34fUMCqj1Ya85tbFKu685cN+XTWYfgXg@mail.gmail.com> (raw)
In-Reply-To: <20200512223103.GC1016@asgard.redhat.com>
On Tue, May 12, 2020 at 3:31 PM Eugene Syromiatnikov <esyr@redhat.com> wrote:
> On Tue, May 12, 2020 at 10:58:16PM +0300, Sergey Organov wrote:
> > Eugene Syromiatnikov <esyr@redhat.com> writes:
> >
> > > As of now, there is no interface exposed for converting pid/fd into
> > > clockid and vice versa; linuxptp, for example, has been carrying these
> > > definitions in missing.h header for quite some time[1].
> > >
> > > [1] https://sourceforge.net/p/linuxptp/code/ci/af380e86/tree/missing.h
> > >
> > > Signed-off-by: Eugene Syromiatnikov <esyr@redhat.com>
> > > ---
> > > Changes since v1[1]:
> > > * Actually tried to build with the patch and fixed the build error
> > > reported by kbuild test robot[2].
> > >
> > > [1] https://lkml.org/lkml/2019/9/20/698
> > > [2] https://lkml.org/lkml/2019/9/22/13
> > > ---
> > > include/linux/posix-timers.h | 47 +------------------------------------------
> > > include/uapi/linux/time.h | 48 ++++++++++++++++++++++++++++++++++++++++++++
> > > 2 files changed, 49 insertions(+), 46 deletions(-)
> >
> > Was this patch applied, rejected, lost?
> >
> > I can't find it in the current master.
>
> IIRC, it was ignored.
Overlooked. :) Not intentionally ignored.
I don't have any major objection with adding helpers, though I feel
like you're exporting a lot more to the uapi then applications likely
need.
Would it be better to add just the bits from the missing.h header you
pointed to:
#define CLOCKFD 3
#define FD_TO_CLOCKID(fd) ((~(clockid_t) (fd) << 3) | CLOCKFD)
#define CLOCKID_TO_FD(clk) ((unsigned int) ~((clk) >> 3))
to the uapi header?
thanks
-john
next prev parent reply other threads:[~2020-05-12 22:40 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-23 13:05 [PATCH v2] uapi, posix-timers: provide clockid-related macros and functions to UAPI Eugene Syromiatnikov
2020-05-12 19:58 ` Sergey Organov
2020-05-12 22:31 ` Eugene Syromiatnikov
2020-05-12 22:40 ` John Stultz [this message]
2020-05-13 9:13 ` Sergey Organov
2020-05-13 17:11 ` John Stultz
2020-05-13 20:28 ` Sergey Organov
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='CALAqxLUGr=+UjYhQSN34fUMCqj1Ya85tbFKu685cN+XTWYfgXg@mail.gmail.com' \
--to=john.stultz@linaro.org \
--cc=bigeasy@linutronix.de \
--cc=ebiederm@xmission.com \
--cc=esyr@redhat.com \
--cc=frederic@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sboyd@kernel.org \
--cc=sorganov@gmail.com \
--cc=tglx@linutronix.de \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).