From: Kees Cook <keescook@chromium.org>
To: Mukesh Ojha <quic_mojha@quicinc.com>
Cc: Thomas Gleixner <tglx@linutronix.de>,
Johannes Berg <johannes@sipsolutions.net>,
linux-kernel@vger.kernel.org, sboyd@kernel.org,
rafael@kernel.org, gregkh@linuxfoundation.org
Subject: Re: [PATCH v2 ] devcoredump : Serialize devcd_del work
Date: Tue, 26 Apr 2022 14:25:57 -0700 [thread overview]
Message-ID: <202204261421.A58121A53E@keescook> (raw)
In-Reply-To: <13df1664-fc52-4772-afa1-4f75019b7830@quicinc.com>
On Tue, Apr 26, 2022 at 07:34:07PM +0530, Mukesh Ojha wrote:
>
>
> On 4/26/2022 1:07 AM, Thomas Gleixner wrote:
> > Cc+: Kees
> >
> > On Mon, Apr 25 2022 at 19:19, Johannes Berg wrote:
> > > On Mon, 2022-04-25 at 19:00 +0200, Thomas Gleixner wrote:
> > > >
> > > > Johannes, can you please explain whether this immediate flush in
> > > > disabled_store() is really required and if so, why?
> > > >
> > > I don't really know, as I remember that requirement (or maybe even code,
> > > not sure) came from Kees, who needed the lockdown.
> > >
> > > Given the use case (ChromeOS?) I'm not sure I see a need to flush all of
> > > them, since I guess a typical system would set the lockdown early in
> > > boot and hopefully not have a crash-dump around already.
> > >
> > > That said, I don't think the diagram you made works - fn() during the
> > > iteration is guaranteed to be invoked with a reference of its own, so
> > > the put_device() there can't be the last reference, only as fn() returns
> > > you'd put the last reference *there*, freeing it.
> >
> > Bah, you are right, it's magically protected by the klist ref, which
> > prevents devcd from going away. Damned obvious.
> >
> > This really needs comments why this all can magically "work".
> >
> > Thanks,
> >
> > tglx
> >
>
> Thanks you all for your time in reviewing this.
> I tried to address few comments in v3 here.
>
> https://lore.kernel.org/lkml/1650981343-11739-1-git-send-email-quic_mojha@quicinc.com/
>
> While, we would like to hear from Kees about reason of immediate flush from
> disabled_store().
This is lost to ancient history in my brain right now. Do you have any
references to past threads on this? The only thing I remember about
device memory dumping was just to make sure that lockdown's
CONFIDENTIALITY mode would block it.
--
Kees Cook
next prev parent reply other threads:[~2022-04-26 21:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-25 13:09 Mukesh Ojha
2022-04-25 14:06 ` Greg KH
2022-04-25 17:00 ` Thomas Gleixner
2022-04-25 17:19 ` Johannes Berg
2022-04-25 19:37 ` Thomas Gleixner
2022-04-26 14:04 ` Mukesh Ojha
2022-04-26 21:25 ` Kees Cook [this message]
2022-04-27 11:58 ` Johannes Berg
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=202204261421.A58121A53E@keescook \
--to=keescook@chromium.org \
--cc=gregkh@linuxfoundation.org \
--cc=johannes@sipsolutions.net \
--cc=linux-kernel@vger.kernel.org \
--cc=quic_mojha@quicinc.com \
--cc=rafael@kernel.org \
--cc=sboyd@kernel.org \
--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
all inboxes | Powered by JetHome®