All of lore.kernel.org
 help / color / mirror / Atom feed
From: Halil Pasic <pasic@linux.ibm.com>
To: Alex Williamson <alex.williamson@redhat.com>
Cc: Anthony Krowiak <akrowiak@linux.ibm.com>,
	Rorie Reyes <rreyes@linux.ibm.com>,
	linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org,
	kvm@vger.kernel.org, hca@linux.ibm.com, borntraeger@de.ibm.com,
	agordeev@linux.ibm.com, gor@linux.ibm.com, jjherne@linux.ibm.com,
	Halil Pasic <pasic@linux.ibm.com>
Subject: Re: [PATCH v1] s390/vfio-ap: Signal eventfd when guest AP configuration is changed
Date: Thu, 16 Jan 2025 20:18:58 +0100	[thread overview]
Message-ID: <20250116201858.1a5f7e7f.pasic@linux.ibm.com> (raw)
In-Reply-To: <20250116115228.10eeb510.alex.williamson@redhat.com>

On Thu, 16 Jan 2025 11:52:28 -0500
Alex Williamson <alex.williamson@redhat.com> wrote:

> > > Alex, does the above answer your question on what guards against UAF (the
> > > short answer is: matrix_dev->mdevs_lock)?    
> 
> Yes, that answers my question, thanks for untangling it.  We might
> consider a lockdep_assert_held() in the new
> signal_guest_ap_cfg_changed() since it does get called from a variety
> of paths and we need that lock to prevent the UAF.

Yes I second that! I was thinking about it myself yesterday. And there
are also a couple of other functions that expect to be called with
certain locks held. I would love to see lockdep_assert_held() there
as well.

Since I went through that code last night I could spin a patch that
catches some of these at least. But if I don't within two weeks, I
won't be grumpy if somebody else picks that up.

Regards,
Halil

  reply	other threads:[~2025-01-16 19:19 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-07 18:36 [PATCH v1] s390/vfio-ap: Signal eventfd when guest AP configuration is changed Rorie Reyes
2025-01-13 16:08 ` Alexander Gordeev
2025-02-05 17:33   ` Rorie Reyes
2025-02-05 17:47     ` Anthony Krowiak
2025-02-06  7:40       ` Alexander Gordeev
2025-02-06 14:12         ` Rorie Reyes
2025-02-11  7:58           ` Alexander Gordeev
2025-02-11 15:02             ` Rorie Reyes
2025-02-11 20:24               ` Anthony Krowiak
2025-02-12 10:55                 ` Vasily Gorbik
2025-01-14  9:03 ` Harald Freudenberger
2025-01-16 16:46   ` Anthony Krowiak
2025-01-17  8:30     ` Harald Freudenberger
2025-01-17 12:42       ` Anthony Krowiak
2025-01-14 20:05 ` Alex Williamson
2025-01-15 19:35   ` Anthony Krowiak
2025-01-16  0:17     ` Halil Pasic
2025-01-16 15:38       ` Anthony Krowiak
2025-01-16 16:52         ` Alex Williamson
2025-01-16 19:18           ` Halil Pasic [this message]
2025-01-17 12:50             ` Anthony Krowiak
2025-01-17 12:55           ` Anthony Krowiak
2025-01-16 19:30         ` Halil Pasic
2025-01-17 12:53           ` Anthony Krowiak

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=20250116201858.1a5f7e7f.pasic@linux.ibm.com \
    --to=pasic@linux.ibm.com \
    --cc=agordeev@linux.ibm.com \
    --cc=akrowiak@linux.ibm.com \
    --cc=alex.williamson@redhat.com \
    --cc=borntraeger@de.ibm.com \
    --cc=gor@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=jjherne@linux.ibm.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-s390@vger.kernel.org \
    --cc=rreyes@linux.ibm.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.