public inbox for [email protected]
 help / color / mirror / Atom feed
From: Grzegorz Jaszczyk <[email protected]>
To: Christian Brauner <[email protected]>,
	Alex Williamson <[email protected]>
Cc: [email protected], [email protected],
	[email protected],
	Matthew Rosato <[email protected]>,
	Paul Durrant <[email protected]>, Tom Rix <[email protected]>,
	Jason Wang <[email protected]>,
	[email protected], Michal Hocko <[email protected]>,
	[email protected], Kirti Wankhede <[email protected]>,
	Paolo Bonzini <[email protected]>, Jens Axboe <[email protected]>,
	Vineeth Vijayan <[email protected]>,
	Diana Craciun <[email protected]>,
	Alexander Gordeev <[email protected]>,
	Xuan Zhuo <[email protected]>,
	Shakeel Butt <[email protected]>,
	Vasily Gorbik <[email protected]>,
	Leon Romanovsky <[email protected]>,
	Harald Freudenberger <[email protected]>,
	Fei Li <[email protected]>,
	[email protected], Roman Gushchin <[email protected]>,
	Halil Pasic <[email protected]>, Jason Gunthorpe <[email protected]>,
	Ingo Molnar <[email protected]>,
	[email protected],
	Christian Borntraeger <[email protected]>,
	[email protected], Zhi Wang <[email protected]>,
	Wu Hao <[email protected]>, Jason Herne <[email protected]>,
	Eric Farman <[email protected]>,
	Dave Hansen <[email protected]>,
	Andrew Donnellan <[email protected]>,
	Arnd Bergmann <[email protected]>,
	[email protected], Heiko Carstens <[email protected]>,
	Johannes Weiner <[email protected]>,
	[email protected], Eric Auger <[email protected]>,
	Borislav Petkov <[email protected]>,
	[email protected], Rodrigo Vivi <[email protected]>,
	[email protected], Thomas Gleixner <[email protected]>,
	[email protected],
	[email protected], [email protected],
	[email protected], Tony Krowiak <[email protected]>,
	Tvrtko Ursulin <[email protected]>,
	Pavel Begunkov <[email protected]>,
	Sean Christopherson <[email protected]>,
	Oded Gabbay <[email protected]>,
	Muchun Song <[email protected]>,
	Peter Oberparleiter <[email protected]>,
	[email protected], [email protected],
	Benjamin LaHaise <[email protected]>,
	"Michael S. Tsirkin" <[email protected]>,
	Sven Schnelle <[email protected]>,
	Greg Kroah-Hartman <[email protected]>,
	Frederic Barrat <[email protected]>,
	Moritz Fischer <[email protected]>,
	Vitaly Kuznetsov <[email protected]>,
	David Woodhouse <[email protected]>,
	Xu Yilun <[email protected]>, Dominik Behr <[email protected]>,
	Marcin Wojtas <[email protected]>
Subject: Re: [PATCH 0/2] eventfd: simplify signal helpers
Date: Mon, 17 Jul 2023 10:29:34 +0200	[thread overview]
Message-ID: <CAH76GKPF4BjJLrzLBW8k12ATaAGADeMYc2NQ9+j0KgRa0pomUw@mail.gmail.com> (raw)
In-Reply-To: <20230714-gauner-unsolidarisch-fc51f96c61e8@brauner>

pt., 14 lip 2023 o 09:05 Christian Brauner <[email protected]> napisał(a):
>
> On Thu, Jul 13, 2023 at 11:10:54AM -0600, Alex Williamson wrote:
> > On Thu, 13 Jul 2023 12:05:36 +0200
> > Christian Brauner <[email protected]> wrote:
> >
> > > Hey everyone,
> > >
> > > This simplifies the eventfd_signal() and eventfd_signal_mask() helpers
> > > by removing the count argument which is effectively unused.
> >
> > We have a patch under review which does in fact make use of the
> > signaling value:
> >
> > https://lore.kernel.org/all/[email protected]/
>
> Huh, thanks for the link.
>
> Quoting from
> https://patchwork.kernel.org/project/kvm/patch/[email protected]/#25266856
>
> > Reading an eventfd returns an 8-byte value, we generally only use it
> > as a counter, but it's been discussed previously and IIRC, it's possible
> > to use that value as a notification value.
>
> So the goal is to pipe a specific value through eventfd? But it is
> explicitly a counter. The whole thing is written around a counter and
> each write and signal adds to the counter.
>
> The consequences are pretty well described in the cover letter of
> v6 https://lore.kernel.org/all/[email protected]/
>
> > Since the eventfd counter is used as ACPI notification value
> > placeholder, the eventfd signaling needs to be serialized in order to
> > not end up with notification values being coalesced. Therefore ACPI
> > notification values are buffered and signalized one by one, when the
> > previous notification value has been consumed.
>
> But isn't this a good indication that you really don't want an eventfd
> but something that's explicitly designed to associate specific data with
> a notification? Using eventfd in that manner requires serialization,
> buffering, and enforces ordering.
>
> I have no skin in the game aside from having to drop this conversion
> which I'm fine to do if there are actually users for this btu really,
> that looks a lot like abusing an api that really wasn't designed for
> this.

https://patchwork.kernel.org/project/kvm/patch/[email protected]/
was posted at the beginig of March and one of the main things we've
discussed was the mechanism for propagating acpi notification value.
We've endup with eventfd as the best mechanism and have actually been
using it from v2. I really do not want to waste this effort, I think
we are quite advanced with v6 now. Additionally we didn't actually
modify any part of eventfd support that was in place, we only used it
in a specific (and discussed beforehand) way.

  parent reply	other threads:[~2023-07-17  8:29 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <[email protected]>
2023-07-14  7:05 ` [PATCH 0/2] eventfd: simplify signal helpers Christian Brauner
2023-07-14 15:24   ` Jason Gunthorpe
2023-07-17  8:29   ` Grzegorz Jaszczyk [this message]
2023-07-17 19:08     ` Alex Williamson
2023-07-17 22:12       ` Jason Gunthorpe
2023-07-17 22:52         ` Alex Williamson
2023-07-18 15:56           ` Jason Gunthorpe
2023-07-13 10:05 Christian Brauner
2023-07-13 17:10 ` Alex Williamson

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=CAH76GKPF4BjJLrzLBW8k12ATaAGADeMYc2NQ9+j0KgRa0pomUw@mail.gmail.com \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    /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