Dimitris Lampridis wrote:
On Thu, 2004-07-08 at 18:32, David Brownell wrote:

Now, you may not be in a position to make sure
your driver works without the PLX and related
glue ... but you're certainly in a position to
make sure PCI-isms are limited in scope.


I agree 100%, but I don't understand how I can predict what to allocate for other designs that use the isp1160. I need the locations of the command and data ports to communicate with the isp1160, which on the evaluation board are at PCI Base Address 2 (data port) and (PCI Base Address 2) + 2 (command port). How can I know where to look for them on other implementations?

That's what I meant about setting it up to use "platform_device". Your driver shouldn't predict; the board setup should tell you.

See in <linux/device.h> ... look at the ohci-lh7a404.c driver
for an example of how binding to that would work.  There would
be resources in the platform_device which would point you at
the memory and IRQ resources assigned to the chip on any given
platform, set up as part of the board init logic.  The OMAP
code recently converted to that approach too, but it's not yet
been merged back to the main kernel trees.

So basically the probe() code, for whichever bus you're using,
should set up those three resources (claim, map) and then hand
everything else off to bus-generic code.  And other than code
to unbind the driver from that device, and related deltas to
the HCD bus glue, virtually nothing else should need to know
whether you're using PCI.  Again, the LH7A404 code should be
a useful model for how to glue "generic" code (most of the
OHCI code) to different sorts of bus glue (PCI and otherwise).

- Dave





-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - digital self defense, top technical experts, no vendor pitches, unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to