From: Martin Wilck <mwilck@suse.com>
To: Benjamin Marzinski <bmarzins@redhat.com>
Cc: Bart Van Assche <Bart.VanAssche@wdc.com>,
device-mapper development <dm-devel@redhat.com>
Subject: Re: [PATCH] multipathd: use nanosleep for sleeping
Date: Wed, 07 Mar 2018 15:26:30 +0100 [thread overview]
Message-ID: <1520432790.11340.14.camel@suse.com> (raw)
In-Reply-To: <20180307012109.GP14513@octiron.msp.redhat.com>
On Tue, 2018-03-06 at 19:21 -0600, Benjamin Marzinski wrote:
> On Tue, Mar 06, 2018 at 09:37:13PM +0100, Martin Wilck wrote:
> >
> > I'm sure this works, but have you considered achieving the same
> > result
> > simply by using create_timer with a different signal than SIGALRM?
> > Thinking about it, I'm sure the strict_timing code can be
> > drastically
> > simplified by using an interval timer and a realtime signal.
>
> I don't see how it could get much simpler, and all things being
> equal,
> I'd rather that multipathd did less with signals. But if you want to
> redo this with a timer, I don't haven any strong feelings against it.
I just sent it with the subject "[RFC PATCH] multipathd: strict_timing
without signals". Please have a look. The patch actually does two
different things - a) convert the current setitimer-based code to a
custom timer that works without SIGALRM (without any explicit signal,
actually), and b) use the it_interval field to wakeup automatically at
fixed intervals, rather than re-calculate the wait time from tick to
tick.
Whether or not this is simpler than the current code (or your approach,
for that matter) is up to personal judgement. My patch has a positive
line count, but it requires less code inside the checkerloop itself.
Cheers,
Martin
--
Dr. Martin Wilck <mwilck@suse.com>, Tel. +49 (0)911 74053 2107
SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
prev parent reply other threads:[~2018-03-07 14:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-06 1:20 [PATCH] multipathd: use nanosleep for sleeping Benjamin Marzinski
2018-03-06 20:37 ` Martin Wilck
2018-03-07 1:21 ` Benjamin Marzinski
2018-03-07 14:26 ` Martin Wilck [this message]
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=1520432790.11340.14.camel@suse.com \
--to=mwilck@suse.com \
--cc=Bart.VanAssche@wdc.com \
--cc=bmarzins@redhat.com \
--cc=dm-devel@redhat.com \
/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.