public inbox for linux-usb@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Dmitry Antipov <dmantipov@yandex.ru>
Cc: Michael Jamet <michael.jamet@intel.com>,
	linux-usb@vger.kernel.org, lvc-project@linuxtesting.org
Subject: Re: [PATCH] thunderbolt: handle possible NULL pointer from get_device()
Date: Fri, 9 Jun 2023 09:46:44 +0200	[thread overview]
Message-ID: <2023060903-unashamed-proactive-8bc9@gregkh> (raw)
In-Reply-To: <d68c759a-e44c-0c6f-03cc-1e07418424eb@yandex.ru>

On Fri, Jun 09, 2023 at 10:15:36AM +0300, Dmitry Antipov wrote:
> On 6/9/23 09:30, Greg KH wrote:
> 
> > Sorry, but how can that happen?
> 
> Hmmm.. there should be a complete mess in the device tree (e.g. passing
> root device with no parent where the regular device is expected). If
> you're sure that this doesn't worth checking then please disregard this.

Again, how did you test this?

And yes, the driver model guarantees that a child can never have a NULL
parent (except for the root device, but that's a different story...)

thanks,

greg k-h

  reply	other threads:[~2023-06-09  7:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-09  6:16 [PATCH] thunderbolt: handle possible NULL pointer from get_device() Dmitry Antipov
2023-06-09  6:30 ` Greg KH
2023-06-09  7:15   ` Dmitry Antipov
2023-06-09  7:46     ` Greg KH [this message]
2023-06-09  8:05       ` Dmitry Antipov
2023-06-09  8:20         ` Greg KH
2023-06-09  9:19           ` Dmitry Antipov
2023-06-09  9:30             ` Greg KH
2023-06-09  8:32         ` [lvc-project] " Alexey Khoroshilov

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=2023060903-unashamed-proactive-8bc9@gregkh \
    --to=gregkh@linuxfoundation.org \
    --cc=dmantipov@yandex.ru \
    --cc=linux-usb@vger.kernel.org \
    --cc=lvc-project@linuxtesting.org \
    --cc=michael.jamet@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox