From: Jeff Garzik <jgarzik@mandrakesoft.com>
To: Kai Germaschewski <kai@tp1.ruhr-uni-bochum.de>
Cc: Linus Torvalds <torvalds@transmeta.com>,
Vojtech Pavlik <vojtech@suse.cz>,
Peter Osterlund <petero2@telia.com>,
Patrick Mochel <mochel@osdl.org>, Tobias Diedrich <ranma@gmx.at>,
Alessandro Suardi <alessandro.suardi@oracle.com>,
linux-kernel@vger.kernel.org
Subject: Re: 2.5.20 - Xircom PCI Cardbus doesn't work
Date: Sat, 15 Jun 2002 15:58:35 -0400 [thread overview]
Message-ID: <3D0B9C6B.8050601@mandrakesoft.com> (raw)
In-Reply-To: <Pine.LNX.4.44.0206151411410.7247-100000@chaos.physics.uiowa.edu>
Kai Germaschewski wrote:
> I still think it's probably a good idea to replace pci_enable_device()
> by a more fine-grained API, which allows a driver author to specify
> which exact resources he needs.
To repeat, pci_enable_device is not _just_ resource assignment.
It also provides:
1) power state management (wakes up the device)
2) an entry point which guarantees the bus layer that the driver is not
interested in the hardware at all before that point. Or IOW,
pci_enable_device is a bus layer hook for whatever "device
wakeup/appearing" needs that bus has. Sure, we are talking about moving
some of that functionality to other functions (pci_request_<foo>), but
that doesn't mean we should ditch the hook altogether.
Remember, we have a matching pair here: pci_enable_device,
pci_disable_device. Update the code that goes on between those two
calls, sure. But leave the calls there.
> So a complete API would be
>
> pci_request_{irq,io,mmio}
> pci_release_{irq,io,mmio}
> pci_enable_{irq,io,mmio}
> pci_assign_{irq,io,mmio}
>
> but normally a driver would just use pci_request/release_*() + maybe
> pci_assign_irq(), which will take care of the appropriate assign/enable
> internally.
That seems like a decent enough API, pending a bit of driver conversion
to see how well it works out in practice. So I'm ok with it (with the
pci_enable_device proviso, above)
Jeff
next prev parent reply other threads:[~2002-06-15 20:02 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-03 11:07 2.5.20 - Xircom PCI Cardbus doesn't work Alessandro Suardi
2002-06-06 17:08 ` Peter Osterlund
2002-06-09 9:17 ` Tobias Diedrich
2002-06-09 10:55 ` Peter Osterlund
2002-06-10 15:44 ` Patrick Mochel
2002-06-10 19:28 ` Peter Osterlund
2002-06-14 16:33 ` Linus Torvalds
2002-06-14 17:20 ` Peter Osterlund
2002-06-14 17:47 ` Linus Torvalds
2002-06-14 17:53 ` Vojtech Pavlik
2002-06-14 18:05 ` Linus Torvalds
2002-06-14 18:12 ` Kai Germaschewski
2002-06-14 18:18 ` Linus Torvalds
2002-06-14 19:37 ` Jeff Garzik
2002-06-15 18:48 ` Linus Torvalds
2002-06-15 19:05 ` Linus Torvalds
2002-06-15 19:39 ` Kai Germaschewski
2002-06-15 19:58 ` Jeff Garzik [this message]
2002-06-15 23:00 ` Kai Germaschewski
2002-06-15 20:07 ` Jeff Garzik
2002-06-15 22:51 ` Kai Germaschewski
2002-06-14 19:31 ` Jeff Garzik
2002-06-14 23:25 ` Kai Germaschewski
2002-06-14 23:53 ` Jeff Garzik
2002-06-15 8:25 ` Ingo Oeser
2002-06-14 19:34 ` Jeff Garzik
2002-06-14 18:30 ` Peter Osterlund
2002-06-14 18:51 ` Linus Torvalds
2002-06-14 20:07 ` Peter Osterlund
2002-06-15 2:42 ` Paul Mackerras
2002-06-15 21:58 ` Cardbus Linus Torvalds
2002-06-16 7:01 ` Cardbus Eric W. Biederman
2002-06-16 8:18 ` Cardbus Paul Mackerras
2002-06-10 20:59 ` 2.5.20 - Xircom PCI Cardbus doesn't work Alessandro Suardi
2002-06-16 4:57 ` Linus Torvalds
2002-06-16 7:40 ` Peter Osterlund
2002-06-16 18:16 ` Linus Torvalds
2002-06-16 18:42 ` Martin Dalecki
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=3D0B9C6B.8050601@mandrakesoft.com \
--to=jgarzik@mandrakesoft.com \
--cc=alessandro.suardi@oracle.com \
--cc=kai@tp1.ruhr-uni-bochum.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mochel@osdl.org \
--cc=petero2@telia.com \
--cc=ranma@gmx.at \
--cc=torvalds@transmeta.com \
--cc=vojtech@suse.cz \
/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