All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alex Chiang <achiang@hp.com>
To: Trent Piepho <xyzzy@speakeasy.org>
Cc: "Darrick J. Wong" <djwong@us.ibm.com>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Jesse Barnes <jbarnes@virtuousgeek.org>,
	linux-pci <linux-pci@vger.kernel.org>,
	Matthew Wilcox <matthew@wil.cx>,
	eike-kernel@sf-tec.de, gregkh@suse.de
Subject: Re: Problems with fakephp
Date: Tue, 2 Dec 2008 21:38:04 -0700	[thread overview]
Message-ID: <20081203043804.GA26130@ldl.fc.hp.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0812021729560.2943@shell2.speakeasy.net>

* Trent Piepho <xyzzy@speakeasy.org>:
> On Mon, 1 Dec 2008, Alex Chiang wrote:
> > I think there are now enough ideas in this thread that they're
> > starting to get confusing.
> >
> > 	1) Function vs. device removal
> > 	2) User interface
> > 	3) Existing fakephp bugs
> >
> > For (1), do you need function level hotplug? Or will you be able
> > to get away with device level?
> 
> While I have some hardware the can use function level hotplug (secondary
> functions can be controlled by registers in the primary function), it's not
> something *I* make use of.  But function level hotplug has been there for
> years so it seems like a regression to remove that ability and break the
> existing interface.

That seems reasonable.

> I guess my first though is should be there a new interface, as part of the
> pci core rather than pci hotplug, for adding/removing devices from Linux's
> view?  By devices I mean in the Linux "struct device" sense, so PCI
> functions.
> 
> I think that seems reasonable.  fakephp isn't the best interface.  My patch
> to add "remove" to pci-sysfs ended up being very simple, unless there's a
> serious flaw in it I've overlooked.

I think we should definitely merge your 'remove' attribute patch
for PCI functions. That should be independent of the rest of our
discussion.

It will probably help the SR-IOV folks too.

> So once we have that the question becomes how to keep some compatibility
> with the old fakephp interface.  Either a new legacy compat module like
> I've done or by fixing fakephp.
> 
> I'm more inclined to have the new legacy compat module:
> 
> - It's quite a bit simpler than fakephp so far.
> - It already works better than fakephp ever did.  fakephp can't do
> recursive bridge removal and won't co-exist well with a new pci core
> remove/add interface.
> - Fakephp's use of devices as "slots" appears to be fundamentally at odds
> with the hotplug core.  It's just going to cause problems in the future.
> The new compat module doesn't use hotplug at all, so it shouldn't get in
> the way.

Maybe we should just replace fakephp wholesale with your new
driver?

Or coming at it from another angle, I don't see what benefit
we'll have from keeping both fakephp and your driver. And if
fakephp is as broken as you describe, then it will only cause
more confusion if a user loads both fakephp and legacy_fakephp.

If the user removes a bridge via the correct legacy_fakephp
interface, fakephp won't notice, and we'll just have a broken
mess on our hands.

It would be better to have just one, correctly working fakephp,
even if the implementation is 100% different and truly not even a
"real" hotplug driver.

I think the way forward is:

	- merge in the function level hotplug patch
	- wholesale replacement of fakephp with new fakephp
	- schedule new fakephp for deprecation
	- encourage anyone who wants function level hotplug to
	  use the 'remove' attribute

Thoughts? Jesse, Willy, Eike, Greg?

Thanks.

/ac


  reply	other threads:[~2008-12-03  4:38 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-25 21:24 [PATCH] fakephp: Allocate PCI resources before adding the device Darrick J. Wong
2008-11-25 21:43 ` Greg KH
2008-11-26  4:46 ` Trent Piepho
2008-11-26  7:48   ` Darrick J. Wong
2008-11-26  9:56     ` Trent Piepho
2008-11-26 18:18       ` Darrick J. Wong
2008-11-26 22:23         ` Trent Piepho
2008-11-26 22:55           ` Alex Chiang
2008-11-27  1:44             ` Trent Piepho
2008-11-27  2:42               ` Matthew Wilcox
2008-11-28 10:11                 ` Trent Piepho
2008-11-28 18:57                   ` Matthew Wilcox
2008-11-28 21:21                     ` Trent Piepho
2008-11-28 21:30                       ` Matthew Wilcox
2008-12-01  1:10                         ` Problems with fakephp Trent Piepho
2008-12-16 20:28                           ` fixup PCI device booleans in sysfs Jesse Barnes
2008-11-28 23:18               ` [PATCH] fakephp: Allocate PCI resources before adding the device Alex Chiang
2008-12-01 13:00                 ` Problems with fakephp Trent Piepho
2008-12-02  3:16                   ` Alex Chiang
2008-12-03  4:07                     ` Trent Piepho
2008-12-03  4:38                       ` Alex Chiang [this message]
2008-12-03 17:22                         ` Rolf Eike Beer
2008-12-03 17:43                           ` Alex Chiang
2008-12-03 17:55                             ` Rolf Eike Beer
2008-12-03 18:22                               ` Alex Chiang
2008-12-08 21:09                                 ` Rolf Eike Beer
2008-12-01 13:36                 ` Trent Piepho
2008-12-01 14:08                   ` [PATCH] PCI: Method for removing PCI devices Trent Piepho
2008-12-01 14:40                     ` Greg KH
2008-12-01 14:08                   ` [PATCH] PCI: Legacy fakephp driver Trent Piepho
2008-11-27  1:52             ` [PATCH] fakephp: Allocate PCI resources before adding the device Darrick J. Wong
2008-11-28  9:51               ` Trent Piepho
2008-11-28 18:42                 ` Rolf Eike Beer
2008-11-28 21:06                   ` Trent Piepho
2008-12-01 17:08                     ` Rolf Eike Beer
2008-12-16 19:33                       ` Jesse Barnes
2008-12-16 20:56                         ` [PATCH] fakephp: Allocate PCI resources before adding the?device Darrick J. Wong
2008-12-21  2:23                           ` Trent Piepho

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=20081203043804.GA26130@ldl.fc.hp.com \
    --to=achiang@hp.com \
    --cc=djwong@us.ibm.com \
    --cc=eike-kernel@sf-tec.de \
    --cc=gregkh@suse.de \
    --cc=jbarnes@virtuousgeek.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=matthew@wil.cx \
    --cc=xyzzy@speakeasy.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 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.