Home > Не вошло > Solaris: configure media on bge

Solaris: configure media on bge

October 29th, 2013 Leave a comment Go to comments

Configuring speed and duplex for bge driver on Solaris.

Stolen here: http://unix.derkeiler.com/Mailing-Lists/SunManagers/2003-12/0421.html

The bge inferface (V210) can be forced to a certain speed and duplex via two methodes: ndd and bge.conf

NDD Creating a script in /etc/rc2.d/S68net_tune 
             #!/sbin/sh 
             # /etc/rc2.d/S68net-tune 
             PATH=/usr/bin:/usr/sbin 
             # Force bge0 to 100fdx autoneg off 
             ndd -set /dev/bge0 adv_1000fdx_cap 0 
             ndd -set /dev/bge0 adv_1000hdx_cap 0 
             ndd -set /dev/bge0 adv_100fdx_cap 1 
             ndd -set /dev/bge0 adv_100hdx_cap 0 
             ndd -set /dev/bge0 adv_10fdx_cap 0 
             ndd -set /dev/bge0 adv_10hdx_cap 0 
             ndd -set /dev/bge0 adv_autoneg_cap 0
bge.conf Adding the following line to the file 
             /platform/sun4u/kernel/drv/bge.conf
             adv_autoneg_cap=0 adv_1000fdx_cap=0 adv_1000hdx_cap=0 \ 
             adv_100fdx_cap=1 adv_100hdx_cap=0 adv_10fdx_cap=0 \ 
             adv_10hdx_cap=0;

However, using bge.conf will force all instances of bge to the speed/duplex specified in the file.

My question:

Is it possible to do this per instance within the bge.conf file or can it only be done via NDD?

I know it is possible for ce instances within the file /platform/sun4u/kernel/drv/ce.conf file using three parameters: name, parent, and unit-address.

name="pci108e,abba" parent="/pci@21c,700000/pci@1" unit-address="0" \ 
 adv_autoneg_cap=0 adv_1000fdx_cap=0 adv_1000hdx_cap=0 \ 
 adv_100fdx_cap=1 adv_100hdx_cap=0 adv_100T4_cap=0 adv_10fdx_cap=0 \ 
 adv_10hdx_cap=0;

I will summarize.

—-8<—-

The summary:

A Sun engineer came back with the following.

It is possible, and the syntax is very similar. Search /etc/path_to_inst on your system for some of the magic numbers; on mine they were:

     $ grep bge /etc/path_to_inst 
      "/pci@1f,700000/network@2" 0 "bge" 
      "/pci@1f,700000/network@2,1" 1 "bge" 
      "/pci@1d,700000/network@2" 2 "bge" 
      "/pci@1d,700000/network@2,1" 3 "bge"

From this, the “parent” value is everything before “/network@” and the “unit-address” is everything after it. Also, the “name” for bge should be either “bge” or “pci108e,1648”.

So, the /platform/sun4u/kernel/drv/bge.conf file should be:

    # interface bge0 
     name="bge" parent="/pci@1f,700000" unit-address="2" \ 
     adv_autoneg_cap=0 adv_1000fdx_cap=0 adv_1000hdx_cap=0 \ 
     adv_100fdx_cap=1 adv_100hdx_cap=0 adv_100T4_cap=0 adv_10fdx_cap=0 \ 
     adv_10hdx_cap=0;
    # interface bge1 
     name="bge" parent="/pci@1f,700000" unit-address="2,1" \ 
     adv_autoneg_cap=0 adv_1000fdx_cap=0 adv_1000hdx_cap=0 \ 
     adv_100fdx_cap=1 adv_100hdx_cap=0 adv_100T4_cap=0 adv_10fdx_cap=0 \ 
     adv_10hdx_cap=0;
    # interface bge2 
     name="bge" parent="/pci@1d,700000" unit-address="2" \ 
     adv_autoneg_cap=0 adv_1000fdx_cap=0 adv_1000hdx_cap=0 \ 
     adv_100fdx_cap=1 adv_100hdx_cap=0 adv_100T4_cap=0 adv_10fdx_cap=0 \ 
     adv_10hdx_cap=0;
    # interface bge3 
     name="bge" parent="/pci@1d,700000" unit-address="2,1" \ 
     adv_autoneg_cap=0 adv_1000fdx_cap=0 adv_1000hdx_cap=0 \ 
     adv_100fdx_cap=1 adv_100hdx_cap=0 adv_100T4_cap=0 adv_10fdx_cap=0 \ 
     adv_10hdx_cap=0;

 

 

Categories: Не вошло Tags:
  1. No comments yet.
  1. No trackbacks yet.
You must be logged in to post a comment.