* How to configure MDI status per port
@ 2009-06-11 4:19 Chaitanya Lala
2009-07-01 0:32 ` Jeff Kirsher
0 siblings, 1 reply; 2+ messages in thread
From: Chaitanya Lala @ 2009-06-11 4:19 UTC (permalink / raw)
To: Jeff Kirsher; +Cc: Linux Network Development list, Arthur Jones
Hi,
I have a requirement to be able to configure/change the default MDI-X
status of each ethernet port. This should be possible on a per port
basis i.e. it should be possible to configure, say, port 0 to auto mdi-x
mode & port 1 to manual MDI-X mode. A couple of possible implementation
strategies could achieve this but both have some problems. Following is
an overview of the two.
1.) Use a module parameter. Pass an array of values, each value
corresponding to ethernet port supported by the driver. For example,
modprobe e1000e mdix_values=1,0,2,0 (where the numbers 0,1 & 2 represent
auto MDI-X, manual MDI & manual MDI-X modes respectively) assigns value
1 for port 0, 0 for port 1, 2 for port 2 and so on. This value can be
assigned to the mdix parameter (member of the e1000_phy_info structure
in the case of e1000e driver) in the probe routine. The problem here is
how to map the ordered list of numbers to the ethernet ports so that
each number in the list always corresponds to the same ethernet
interface. I assume that the order of enumeration of ethernet ports can
change based on changes to the system topology, i.e. plugging/pulling of
additional NIC cards.
2.) Using ethtool and each driver sets the value in its set_settings
function (part of the ethtool operations structure). The value received
for each port can be assigned to the mdix parameter (member of the
e1000_phy_info structure in the case of e1000e driver) but the problem
is that the value is useful iff it is assigned before the probe routine
is invoked, because the settings in the chip registers are done only at
probe time. Is there a way to change this value and have it take effect
when changed by ethtool?
Any other ideas are most welcome.
Thanks,
Chaitanya
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: How to configure MDI status per port
2009-06-11 4:19 How to configure MDI status per port Chaitanya Lala
@ 2009-07-01 0:32 ` Jeff Kirsher
0 siblings, 0 replies; 2+ messages in thread
From: Jeff Kirsher @ 2009-07-01 0:32 UTC (permalink / raw)
To: clala; +Cc: Linux Network Development list, Arthur Jones
On Wed, Jun 10, 2009 at 9:19 PM, Chaitanya Lala<clala@riverbed.com> wrote:
> Hi,
>
> I have a requirement to be able to configure/change the default MDI-X status
> of each ethernet port. This should be possible on a per port basis i.e. it
> should be possible to configure, say, port 0 to auto mdi-x mode & port 1 to
> manual MDI-X mode. A couple of possible implementation strategies could
> achieve this but both have some problems. Following is an overview of the
> two.
>
> 1.) Use a module parameter. Pass an array of values, each value
> corresponding to ethernet port supported by the driver. For example,
> modprobe e1000e mdix_values=1,0,2,0 (where the numbers 0,1 & 2 represent
> auto MDI-X, manual MDI & manual MDI-X modes respectively) assigns value 1
> for port 0, 0 for port 1, 2 for port 2 and so on. This value can be assigned
> to the mdix parameter (member of the e1000_phy_info structure in the case of
> e1000e driver) in the probe routine. The problem here is how to map the
> ordered list of numbers to the ethernet ports so that each number in the
> list always corresponds to the same ethernet interface. I assume that the
> order of enumeration of ethernet ports can change based on changes to the
> system topology, i.e. plugging/pulling of additional NIC cards.
>
> 2.) Using ethtool and each driver sets the value in its set_settings
> function (part of the ethtool operations structure). The value received for
> each port can be assigned to the mdix parameter (member of the
> e1000_phy_info structure in the case of e1000e driver) but the problem is
> that the value is useful iff it is assigned before the probe routine is
> invoked, because the settings in the chip registers are done only at probe
> time. Is there a way to change this value and have it take effect when
> changed by ethtool?
>
> Any other ideas are most welcome.
>
> Thanks,
> Chaitanya
Option 2 (using ethtool is the right way to go) as far as the driver,
there most likely will need some work to be done since they may not be
setup to handle the manual setting of MDI/MDIX parameter.
--
Cheers,
Jeff
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-07-01 0:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-11 4:19 How to configure MDI status per port Chaitanya Lala
2009-07-01 0:32 ` Jeff Kirsher
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).