RE: [PATCH] olympic.c: fixes to olympic_scan

From: Phillips, Mike (PHILLIM@amtrak.com)
Date: Wed Aug 09 2000 - 15:30:56 EST


>* Testing pci_present is useless when it is immediately followed by a
>call to pci_find_device. Since pci_find_device produces correct results
>even when PCI isn't present, there is no need to call pci_present at
>all().

True.

>* The "paragraph" of code right below the call to pci_enable_device can
>be replaced with a simple call to pci_set_master.
>pci_enable_device+pci_set_master enable all the PCI_COMMAND bits needed
>for operation.

Oh yes you do, otherwise the PowerPC won't activate the card properly, this
may be a problem with the PPC arch rather that the driver though.

>* would be nice, but not necessary, if check-region was eliminated and
>request-region was used instead.

On the list

>* replace references to pci_device->resource[x].start with
>pci_resource_start(pci_device, x)

Yep,

>* use the new PCI driver API to clean this sucker up. boy, I'll bet
>this driver would lose a hundred lines of code if you did that. The
>module init code is really hairy and has more code paths/cases than
>absolutely necessary.

The new pci api will clean up a lot of things, most of the code is in there
for various reasons, none of which are probably valid anymore.

> Let me know if you have any questions, I'll be more than happy to answer
> them. Thanks for the cleanup work... you are doing the Linux
> community favor, while also helping to eliminate some of the items on my
> kernel todo list :):)

> Jeff

Jeff, I know you've taken on the responsibility for the ethernet drivers,
and approve of what Arnaldo is doing, but it would have been nice to review
the changes before they were posted to the mailing list. I'm working through
some issues with the driver on certain machines at the moment and when this
is fixed I was going to update the driver with the new pci api's, also the
driver may need slight mods to work with the new cardbus version of the
chipset which I was also going to include.

Mike Phillips

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Tue Aug 15 2000 - 21:00:19 EST