linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@rjwysocki.net>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Linux PM <linux-pm@vger.kernel.org>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	Daniel Vetter <daniel@ffwll.ch>, Lukas Wunner <lukas@wunner.de>,
	Andrzej Hajda <a.hajda@samsung.com>,
	Russell King - ARM Linux <linux@armlinux.org.uk>,
	Lucas Stach <l.stach@pengutronix.de>,
	Linus Walleij <linus.walleij@linaro.org>,
	Thierry Reding <thierry.reding@gmail.com>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Subject: Re: [PATCH 0/6] driver core: Fix some issues related to device links
Date: Fri, 01 Feb 2019 01:20:38 +0100	[thread overview]
Message-ID: <3707536.KyOczrGQdC@aspire.rjw.lan> (raw)
In-Reply-To: <20190201001231.GA4886@kroah.com>

On Friday, February 1, 2019 1:12:31 AM CET Greg Kroah-Hartman wrote:
> On Fri, Feb 01, 2019 at 12:50:58AM +0100, Rafael J. Wysocki wrote:
> > On Thursday, January 31, 2019 7:24:07 PM CET Greg Kroah-Hartman wrote:
> > > On Thu, Jan 31, 2019 at 05:02:05PM +0100, Rafael J. Wysocki wrote:
> > > > On Thu, Jan 31, 2019 at 2:24 PM Greg Kroah-Hartman
> > > > <gregkh@linuxfoundation.org> wrote:
> > > > >
> > > > > On Thu, Jan 31, 2019 at 02:22:47PM +0100, Greg Kroah-Hartman wrote:
> > > > > > On Thu, Jan 31, 2019 at 11:09:51AM +0100, Rafael J. Wysocki wrote:
> > > > > > > On Thu, Jan 24, 2019 at 12:25 PM Rafael J. Wysocki <rjw@rjwysocki.net> wrote:
> > > > > > > >
> > > > > > > > Hi Greg at al,
> > > > > > > >
> > > > > > > > Recently I have been looking at the device links code because of the
> > > > > > > > recent discussion on possibly using them in the DRM subsystem (see for
> > > > > > > > example https://marc.info/?l=linux-pm&m=154832771905309&w=2) and I have
> > > > > > > > found a few issues in that code which should be addressed by this patch
> > > > > > > > series.  Please refer to the patch changelogs for details.
> > > > > > > >
> > > > > > > > None of the problems addressed here should be manifesting themselves in
> > > > > > > > mainline kernel today, but if there are more device links users in the
> > > > > > > > future, they most likely will be encountered sooner or later.  Also they
> > > > > > > > need to be fixed for the DRM use case to be supported IMO.
> > > > > > > >
> > > > > > > > This series does not fix all issues in device links that have become
> > > > > > > > apparent (generally speaking, the idea of returning an existing link
> > > > > > > > in case there is one already for the given consumer-supplier pair
> > > > > > > > doesn't play well with stateful links and their flags), so there will
> > > > > > > > be a follow-up series of patches to clean that up.  Still, I don't see
> > > > > > > > a reason to sit on these fixes while working on the other patches, so
> > > > > > > > here they go.
> > > > > > >
> > > > > > > Any concerns regarding this lot?
> > > > > > >
> > > > > > > [Please note that patch 5 in the series was replaced with the v2 at
> > > > > > > https://patchwork.kernel.org/patch/10781205/]
> > > > > > >
> > > > > > > If not, and if you don't mind, I would like to queue it up next week,
> > > > > > > possibly along with the follow-up material posted on Monday
> > > > > > > (https://lore.kernel.org/lkml/2405639.4es7pRLqn0@aspire.rjw.lan/) if
> > > > > > > that is not problematic, so it gets some linux-next coverage before
> > > > > > > the next merge window.
> > > > > >
> > > > > > Can I queue it up in my tree, given that I have a number of other driver
> > > > > > core patches in there, and I don't know how the merge issues will be if
> > > > > > we start to diverge.
> > > > > >
> > > > > > Or do you need this for some other work?
> > > > >
> > > > > To make this clearer, I have no objection to take this through my tree
> > > > > now, along with your second set of patches.  Is that ok?
> > > > 
> > > > Yes, it is, AFAICS.  Thank you!
> > > > 
> > > > Do you need me to resend all of this as one series?
> > > 
> > > Yes, can you please do that.  Also, can you rebase it against my
> > > driver-core-next branch as right now, patch 1/6 has conflicts due to
> > > other patches that are in my tree :(
> > 
> > So commit 0fe6f7874d467 in your driver-core-next branch, which is the source
> > of this conflict and I can't recall seeing that patch, if missing a Fixes: tag.
> 
> It was sent on the 1st, and seems to have come from this thread:
> 	https://lore.kernel.org/lkml/1546318276-18993-3-git-send-email-yong.wu@mediatek.com/
> 
> I'll gladly revert it if you do not think it is correct.

It is not entirely correct, but that's not going to matter after my series
(and I've already rebased it on top of that commit, so please hold on to it :-)).

> Hm, in looking at that closer, it does feel odd that the reference count
> is being ignored, that doesn't seem right, and might be a driver bug...

This is a device links code issue which was introduced along with the reference
counting that was kind of an afterthought and not really well thought through
IMO.

> Let me look at it again in the morning...

So one of the goals of my series is to clean up that mess (and sorry about
letting it in in the first place).

Cheers,
Rafael


  reply	other threads:[~2019-02-01  0:21 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-24 11:13 [PATCH 0/6] driver core: Fix some issues related to device links Rafael J. Wysocki
2019-01-24 11:15 ` [PATCH 1/6] driver core: Fix DL_FLAG_AUTOREMOVE_SUPPLIER device link flag handling Rafael J. Wysocki
2019-01-24 11:16 ` [PATCH 2/6] driver core: Reorder actions in __device_links_no_driver() Rafael J. Wysocki
2019-01-24 11:18 ` [PATCH 3/6] driver core: Avoid careless re-use of existing device links Rafael J. Wysocki
2019-01-24 11:19 ` [PATCH 4/6] driver core: Do not resume suppliers under device_links_write_lock() Rafael J. Wysocki
2019-01-24 11:21 ` [PATCH 5/6] driver core: Fix handling of runtime PM flags in device_link_add() Rafael J. Wysocki
2019-01-25 11:18   ` [PATCH v2 " Rafael J. Wysocki
2019-01-24 11:23 ` [PATCH 6/6] driver core: Fix adding device links to probing suppliers Rafael J. Wysocki
2019-01-24 14:58 ` [PATCH 0/6] driver core: Fix some issues related to device links Russell King - ARM Linux admin
2019-01-24 23:08   ` Rafael J. Wysocki
2019-01-31 10:09 ` Rafael J. Wysocki
2019-01-31 13:22   ` Greg Kroah-Hartman
2019-01-31 13:24     ` Greg Kroah-Hartman
2019-01-31 16:02       ` Rafael J. Wysocki
2019-01-31 18:24         ` Greg Kroah-Hartman
2019-01-31 18:36           ` Rafael J. Wysocki
2019-01-31 23:50           ` Rafael J. Wysocki
2019-02-01  0:12             ` Greg Kroah-Hartman
2019-02-01  0:20               ` Rafael J. Wysocki [this message]
2019-01-31 16:03       ` Ulf Hansson

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=3707536.KyOczrGQdC@aspire.rjw.lan \
    --to=rjw@rjwysocki.net \
    --cc=a.hajda@samsung.com \
    --cc=daniel@ffwll.ch \
    --cc=gregkh@linuxfoundation.org \
    --cc=l.stach@pengutronix.de \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=lukas@wunner.de \
    --cc=rafael@kernel.org \
    --cc=thierry.reding@gmail.com \
    --cc=ulf.hansson@linaro.org \
    /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;
as well as URLs for NNTP newsgroup(s).