Re: [PATCH 2/2] pcnet32: PHY selection support

From: Adam Kropelin
Date: Fri Feb 17 2006 - 12:55:54 EST


Seewer Philippe wrote:
> Most AMD pcnet chips support up to 32 external PHYs. This patch
> introduces basic PHY selection/switching support, by adding two
> new module parameters:
> -maxphy: how many PHYs the card supports
> -usephy: which phy to use instead of eeprom default
>
> Maxphy is necessary in order to check the range of usephy and may
> be overriden inside the module.

It seems a bit pointless for the range check of a user-supplied value to
be driven by another user-supplied value.

> If only maxphy is present I've implemented an algorithm which checks
> the link state on all PHYs and uses the one that has a link.

Knowing how many PHYs to scan is potentially useful, but how about
determining that at runtime? Missing PHYs should be detectable with a
timeout or similar. Too risky?

--Adam

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