               Broadcom NetXtreme Gigabit Ethernet Driver
                      For Solaris 2.6/7/8/9/10 for
                        i386 / SPARC platform

              Copyright (c) 2000-2009 Broadcom Corporation
                         All rights reserved.


Contents 

I.   Introduction

II.  Installing Driver

III. Uninstalling Driver

IV.  Driver Update (DU) Diskette Instruction (Intel Platform ONLY)

V.   Customize Driver Configuration


I. Introduction
    ============

This file describes the Solaris Release 8 driver for Broadcom's BCM570X
10/100/1000 Mbps Ethernet Network Interface Controller.  Driver is
released in three formats:

1. BRCMbcme.pkg   : Datastream format.
2. BRCMbcme.tar.Z : Compressed and TAR file system format.
3. bcmedu.img     : Driver Update (DU) binary image which is used to create
                    DU diskette.

This driver supports the following Broadcom network adapters:

* Broadcom NetXtreme Gigabit Ethernet BCM5700
* Broadcom NetXtreme Gigabit Ethernet BCM5701
* Broadcom NetXtreme Gigabit Ethernet BCM5702
* Broadcom NetXtreme Gigabit Ethernet BCM5703
* Broadcom NetXtreme Gigabit Ethernet BCM5704
* Broadcom NetXtreme Gigabit Ethernet BCM5705
* Broadcom NetXtreme Fast Ethernet BCM5782
* Broadcom NetXtreme Gigabit Ethernet BCM5751
* Broadcom NetXtreme Gigabit Ethernet BCM5721
* Broadcom NetXtreme Gigabit Ethernet BCM5753
* Broadcom NetXtreme Gigabit Ethernet BCM5752
* Broadcom NetXtreme Gigabit Ethernet BCM5714
* Broadcom NetXtreme Gigabit Ethernet BCM5715
* Broadcom NetXtreme Gigabit Ethernet BCM5780
* Broadcom NetXtreme Gigabit Ethernet BCM5755
* Broadcom NetXtreme Gigabit Ethernet BCM5722
* Broadcom NetXtreme Gigabit Ethernet BCM5784
* Broadcom NetXtreme Gigabit Ethernet BCM5764
* Broadcom NetXtreme Gigabit Ethernet BCM5723


II. Installing Driver
    =================

1. Change directory to where BRCMbcme.pkg resides.
2. pkgadd -d BRCMbcme.pkg
               OR
( Copy  BRCMbcme.tar.Z to /tmp.
  cd /tmp
  uncompress BRCMbcme.tar.Z
  tar xvf BRCMbcme.tar
  pkgadd -d /tmp)

3. Execute prtconf to determine instance number of the NIC.
4. ifconfig bcme[instance_number] plumb
5. ifconfig bcme[instance_number] ip_address netmask ....

To make these changes permanent, follow these steps:

1. Use your favorite text editor (eg. vi) and create a file named
   hostname.bcme[instance_number] in /etc directory.  Add the
   IP address of the interface to this file, save and exit.
2. Add a proper subnet mask to the file /etc/netmasks.]

In Solaris 7.0 (Intel platform), operating system only allocates 36
pages of 4K physically contiguous memory.  Driver needs about 130K
physically contiguous memory per NIC.  In order to use more than one
NIC.  O/S has to allocate more memory.  This can be done by setting
an O/S system variable "lomempages" in /etc/system. For instance,
4 NICs are installed in Solaris 7 system, physically contiguous
memory is calculated as follows:
      4 NICs * 130K = 520 K ==> 130 pages of 4K is required.

Since this memory might be used by other driver in the system,
200 of 4K of memory is allocated.  Add the following line in
file /etc/system:

     set lomempages=200


III. Uninstalling Driver
      =================

1. ifconfig bcme[instance_number] down
2. ifconfig bcme[instance_number] unplumb
3. pkgrm BRCMbcme.


IV.  Driver Update (DU) Diskette Instruction (Intel Platform ONLY)
     ============================================================

This area contains the Solaris diskette image files(s) and the instructions
to create diskettes from these image file(s).

1.  Insert a blank diskette into your machine's diskette drive and type one
    of the following commands to format it:

   * If you are using DOS, type:

     format A:

   * If you are using the Solaris operating environment, type:

     fdformat -Ud

2.  Check to see if Volume Management is running:

   * If you are using DOS, type:

     dd filename A:

   * If you are using the Solaris operating environment, type:

     volcheck
     ls -l /vol/dev/aliases/floppy0


        * If you see a message similar to this:

          lrwxrwxrwx   1 root  34 Jan 21 17:28
          /vol/dev/aliases/floppy0 ->
          /vol/dev/rdiskette0/unnamed_floppy

          Type:

               dd if=bcmedu.img of=/vol/dev/aliases/floppy0
               bs=36k eject floppy0

        * If you see this message:

          /vol/dev/aliases/floppy0 not found

          Type:

               dd if=bcmedu.img of=/dev/rdiskette bs=36k


Installing Solaris DU Diskette(s)

You can use Solaris DU diskettes in one of two ways:

   * To use new drivers to install or upgrade the Solaris operating
     environment on a machine with new hardware

   * To add new drivers to support new hardware on an already installed
     and booted system

Installing Solaris Using DU Diskette(s)

To install Solaris (Intel Platform Edition) using drivers on the DU
diskette:

1.  Insert the appropriate Configuration Assistant diskette, made from the
included file bcmedu.img into your machine's diskette drive.  Also,
insert the Solaris Installation CD-ROM, or for network installation, verify
with your system administrator that the Solaris network installation image
is available on your network.

2.  Turn your machine on.

3.  When the Configuration Assistant screen is displayed, choose the F4
option (on 2.6, this is labelled F4_Driver Update; on Solaris 7, F4_Add
Driver).

    The message "Enumerating buses ... " is displayed. Then the Install
Driver Update screen is displayed.

4.  Remove the Configuration Assistant diskette from the diskette drive and
insert the first Solaris DU diskette you want.

5.  Press F2_Continue.

    The Select Solaris System Version screen is displayed.

6.  Select the appropriate Solaris OS and press F2_Continue.

The Loading Driver Update Software screen is displayed, along with a
progress bar that shows the percentage of drivers that have been extracted
from the diskette. Drivers are read into memory and survive long enough for
the system to successfully boot to its installation program. When all the
new drivers on the diskette have been processed, the Continue Driver Update
Installation screen is displayed.

7.  Remove the DU diskette from the diskette drive and insert the next DU
diskette you want, if any.

8.  Press F2_Continue.

Again, the Loading Driver Update Software screen is displayed, along with a
progress bar that shows the percentage of drivers that have been extracted
from the diskette. Drivers are read into memory and survive long enough for
the system to successfully boot to its installation program. When all the
new drivers on the diskette have been processed, the Continue Driver Update
Installation screen is displayed.

9.  Repeat Steps 7 and 8 until all the DU diskettes you want are installed.

10. When all the drivers are processed, remove the DU diskette from the
diskette drive and reinsert the Configuration Assistant diskette.

     IMPORTANT: Do not remove the Configuration Assistant diskette from
     the diskette drive until you see the following message displayed
     in a dialog box:

     If you want to bypass the device configuration and boot screens
     when the system reboots, eject the Device Configuration
     Assistant/Boot diskette now.

11. Press F2_Continue.

The Solaris Device Configuration Assistant screen is displayed.

12. Press F2_Continue.

The message "Enumerating buses ..." is displayed.

Then the Scanning Devices screen is displayed. System devices are scanned.
When scanning is complete, the Identified Devices screen is displayed.

13. Press F2_Continue.

 The message "Loading driver ..." is displayed followed by messages about
the drivers that are required to boot your system. After a few seconds, the
Boot Solaris screen is displayed.

14. At the Boot Solaris screen, select the device controller attached to the
device that contains your install medium.

15. Press F2_Continue.

Drivers for the device controller you selected are displayed. Your system
boots to run the install program. The install program starts and your
machine begins booting the complete Solaris operating environment. Then,
after some time, the following messages are displayed, prompting you to
insert each of the Solaris DU diskettes required to install your machine:

     Installing unbundled device driver support
     Extracting driver list from tree..
     <DU diskette name> driver-name...

     Please insert the Driver Update diskette labeled <DU diskette
     name>
     Press <ENTER> when ready.

16. Remove the Configuration Assistant diskette and reinsert the first DU
diskette you inserted earlier into the diskette drive.

17. Press Enter.

Packages, patches, or both that contain the new drivers are installed from
the diskette onto your machine. Messages about each installation are
displayed.

*If drivers on other DU diskettes are required for your machine, this
prompt is displayed:

      Please insert the Driver Update diskette labeled <DU diskette name>
   Press <ENTER> when ready.

*Otherwise, this prompt is displayed:

    If you have additional Update diskettes to install (such as video),
please insert diskette now.
   Additional Update diskettes to install? (y/n) [y]

18. If drivers on other DU diskettes are required, remove the DU diskette
from the diskette drive, insert the next  DU diskette you are prompted to
insert, press Enter, and repeat until all drivers you need are installed.

19. Press Enter.

When installation is complete, the message "Installation complete" is
displayed.

20. Remove the diskette from the diskette drive.

21. Reboot your machine.

When the Solaris operating environment is finished booting and running, the
new devices whose drivers you installed are available for use.

Adding a DU Diskette to an Existing Solaris System

Before adding new or updated drivers, the newly supported hardware devices
should be installed and configured according to the instructions in the
corresponding Device Reference Page, if any. See the Solaris (Intel Platform
Edition) Device Configuration Guide.

When the Solaris (Intel Platform Edition) software is already installed, the
simplest way to add new or updated drivers is to install the DU diskettes as
patches on your system, as follows:

1.  Become superuser on your system.

2.  Check to see if Volume Management is running on the machine you are
updating:

  ps -ef | grep vold

    For more information about managing diskettes and drives, see the System
Administration Guide.

3.  If Volume Management is running, temporarily stop it by typing:

    # /etc/init.d/volmgt stop

4.  Insert the DU diskette into the diskette drive.

5.  Mount the DU diskette at the /mnt mount point:

  # mount -F pcfs /dev/diskette /mnt

  Note: At this point, you must mount the DU diskette in the file structure
to update your system successfully.

6.  Execute the install script on the diskette, using the appropriate
Solaris release directory (currently sol_26 for Solaris 2.6, sol_27 for
Solaris 7, and so on). For example:

    # /mnt/DU/sol_27/i86pc/Tools/install.sh -i

The install.sh script searches for all new or updated drivers on the
diskette. When a new or updated driver is found, the following prompt is
displayed:

    Unconditionally installing DUs <DU driver names>
    Install patch driver-name? [y]

7.  If the driver is the one you want to install, at the prompt, type y for
yes or press Enter. If the driver is not the one you want to install, type n
for no.

If you type y, the install.sh script installs the driver you indicated as
well as the bootmod and bootbin patches.

8.  When you're done and the install.sh script exits, unmount the diskette:

    # cd /
    # umount /mnt

9.  Remove the DU diskette from the diskette drive.

10. Reboot your machine.

  # touch /reconfigure
  # reboot

11. If you haven't already, turn your system off, add the new hardware, and
then turn your system on again.

12. When the autoboot sequence prompt is displayed, quickly press Escape.

The autoboot sequence is interrupted. The Configuration Assistant screen is
displayed.

13. Press F2_Continue.

The message "Enumerating buses ..." is displayed. The Scanning Devices
screen is then displayed. System devices are scanned. When scanning is
complete, the Identified Devices screen is displayed.

14. Press F2_Continue.

The message "Loading driver com.bef ..." is displayed. The Boot Solaris
screen is then displayed.

15. On the Boot Solaris screen, select the device controller attached to the
device that contains your install medium, in this case the main system disk.

The /etc/bootrc script is displayed.

16. At the prompt, type:

  b -r

Your machine boots. You can now use your new hardware.


V. Customize Driver Configuration
   ==============================
To customize the driver edit "/kernel/drv/bcme.conf" and update the
respective parameters in this file.  The following describes the meaning
of these parameters:

# ForceSpeedDuplex : configures link (or instance) to a certain Speed and
# Duplex. By default, AutoNegotiate (0) is set. The setup is based on the
# following values:
#       0 : AutoNegotiate.
#       1 : 10 Mbps speed and Half Duplex mode.
#       2 : 10 Mbps speed and Full Duplex mode.
#       3 : 100 Mbps speed and half Duplex mode.
#       4 : 100 Mbps speed and Full Duplex mode.
#       5 : Force 1000 Mbps Full Duplex mode (Fiber NIC only).
#       6 : AutoNegotiate only 1000 Mbps Full Duplex mode.
#       7 : (Deprecated option)
#       8 : AutoNegotiate only 100 Mbps Full Duplex mode.
#       9 : AutoNegotiate only 100 Mbps Half Duplex mode.
#      10 : AutoNegotiate only 10 Mbps Full Duplex mode.
#      11 : AutoNegotiate only 10 Mbps Half Duplex mode.
#
#  For examples, configure adapters of instance#0 and instance#3 to
#  100 Mbps Full Duplex, and 10 Mbps Half Duplex.
#   ForceSpeedDuplex=4,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0;
#
ForceSpeedDuplex=0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0;

#
# FlowControl : configures flow control parameters of a link. The setup is
# based on the following values:
#       0:  Both Tx and Rx flow control are disabled.
#       1:  Tx flow control is enabled.  Pause frames will be sent if
#           resource is low. But device will not process Rx Pause Frame.
#       2:  Rx flow control is enabled. If device receives Pause Frame,
#           it will stop sending. But device will not send Pause Frame
#           if resource is low.
#       3:  Both Rx and TX flow control are enabled. Pause frames
#           will be sent if resource is low. If device receives Pause Frame,
#           it will stop sending.
#       4:  Advertise both Rx and TX flow control being enable and negotiate
#           with link partner. If link AutoNegotiate is not enabled, then
#           both Tx & Rx Flow Control are disabled.
FlowControl=0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0;

#
# MaxJumboFrameSize : configures Jumbo Frame feature of a link. The valid
# range for this parameter is 0 to 9000. If value configured is less then
# 1500, then Jumbo Frame feature is disable.  BCM5705 NICs don't support
# jumbo frame and therefore this parameter will be ignored by the driver.
MaxJumboFrameSize=0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0;

#
#  TxPacketDescCnt: configures number of Tx packet descriptor.  The valid
#  value is 32 to 512.  More system memory resource will be used for
#  larger number of Tx Packet Descriptors. Default value is 200.
#
TxPacketDescCnt=200;

#
#  RxStdDescCnt: configures number of Rx packet descriptor.  The valid value
#  is 32 to 512.  More system memory resource will be used for larger
#   number of Rx Packet Descriptors. Default value is 500.
#
RxStdDescCnt=500;

#
#  RxJumboDescCnt: configures number of Rx Jumbo packet descriptor.  The
#  valid value is 32 to 256.  More system memory resource will be used for
#  larger number of Rx Jumbo packet descriptors. This parameter is only
#  used if jumbo frame feature is enabled.  Default value is 50.
#
RxJumboDescCnt=50;

#
#  RxCoalescingTicks: configures number of Rx Host Coalescing Ticks in
#  microseconds. This determines upper-bound of time interval that the
#  device will generates interrupt if one or more frames are received.
#  The default value is 150.
#
RxCoalescingTicks=150;

#
#  RxMaxCoalescedFrames: configures number of Rx Maximum Coalesced Frames
#  parameters.  This determines upper-bound of maximum number of Rx buffer
#  descriptors that device processes before it will generate an interrupt.
#  The default value is 10.
#
RxMaxCoalescedFrames=10;

#
#  TxCoalescingTicks: configures number of Tx Host Coalescing Ticks in
#  microseconds. This determines upper-bound of time interval that the
#  device will generates interrupt if one or more frames are sent.  The
#  default value is 500.
#
TxCoalescingTicks=500;

#
#  TxMaxCoalescedFrames: configures number of Tx Maximum Coalesced Frames
#  parameters.  This determines upper-bound of maximum number of Tx buffer
#  descriptors that device processes before it will generate an interrupt.
#  The default value is 80.
#
TxMaxCoalescedFrames=80;

#
#  RxCoalescingTicksDuringInt: configures number of Rx Host Coalescing Ticks
#  in  microseconds during interrupt. This determines upper-bound of time
#  interval that the device will generates interrupt if one or more frames
#  are received during interrupt handling. The default value is 75.
#
RxCoalescingTicksDuringInt=75;

#
#  TxCoalescingTicksDuringInt: configures number of Tx Host Coalescing
#  Ticks in microseconds during interrupt. This determines upper-bound of
#  time interval that the device will generates interrupt if one or more
#  frames are received during interrupt handling.  The default value is 75.
#
TxCoalescingTicksDuringInt=75;

#
#  RxMaxCoalescedFramesDuringInt: configures number of Rx Maximum Coalesced
#  Frames parameters during interrupt handling. This determines upper-bound
#  of maximum number of Rx buffer descriptors that device processes before
#  it will generate an interrupt during interrupt handling. The default
#  value is 10.
#
RxMaxCoalescedFramesDuringInt=10;

#
#  TxMaxCoalescedFramesDuringInt: configures number of Tx Maximum Coalesced
#  Frames parameters during interrupt handling. This determines upper-bound
#  of maximum number of Tx buffer descriptors that device processes before
#  it will generate an interrupt during interrupt handling. The default
#  value is 10.
#
TxMaxCoalescedFramesDuringInt=10;

#
#  StatsCoalescingTicks: configures how often adapter statistics are DMAed
#  to host memory in microsecond.  Default is 1000000.
#
StatsCoalescingTicks=1000000;

#
#  DoubleCopyTxBufferSize: configures double copy Tx buffer size. If a
#  packet to be transmitted is less than this parameter and spanned more
#  than 1 fragments.  These fragments of this packet will be combined into
#  1 fragment.
#
DoubleCopyTxBufferSize=64;

Customize Driver Configuration via NDD command
==============================================

Driver configurations can also be temporarily changed with Solaris ndd
command.  Any changes made with ndd command are temporary and will be
lost when you reboot the system. To make configuration changes survive
after reboot, modifying bcme.conf instead.

To display parameters that are configurable via ndd:

          ndd /dev/bcme '?'

The system should returns the following:

?                             (read only)
Instance                      (read and write)
ForceSpeedDuplex              (read and write)
FlowControl                   (read and write)
RxCoalescingTicks             (read and write)
RxMaxCoalescedFrames          (read and write)
TxCoalescingTicks             (read and write)
TxMaxCoalescedFrames          (read and write)
RxCoalescingTicksDuringInt    (read and write)
RxMaxCoalescedFramesDuringInt (read and write)
TxCoalescingTicksDuringInt    (read and write)
TxMaxCoalescedFramesDuringInt (read and write)
StatsCoalescingTicks          (read and write)
BlinkLeds                     (write only)

To configure a particular NIC, parameter "Instance" has to be set
to proper instance associated with a particular NIC.  For instance,
to force NIC of instance 1 to 100Mbps Full Duplex,

       ndd -set /dev/bcme Instance 1
       ndd -set /dev/bcme ForceSpeedDuplex 4

To query current configuration of Flow Control of instance 3,
       ndd -set /dev/bcme Instance 3
       ndd -get /dev/bcme FlowControl

To blink all LEDs for 10 seconds of NIC of instance 5.
       ndd -set /dev/bcme Instance 5
       ndd -set /dev/bcme BlinkLeds 10


Disabling ASF in the firmware
==============================

Use these instructions to disable ASF in the firmware:

1.  Download the BCM57xx User diagnostic from our driver
    download site at :

    http://www.broadcom.com/drivers/downloaddrivers.php

2.  Create a DOS bootable floppy

3.  Unpack the diag zip-file into this floppy

4.  Boot to DOS using this floppy

5.  Enter "b57udiag -cmd"

6.  Enter setasf -d

7.  Reboot the system


Issues with Solaris 10
================================

Making configuration changes
--------------------------------

Starting with Solaris 10, the administrator can no longer unload and
reload the bcme module to get configuration changes into the system.
The recommended way to do this is to use the 'update_drv bcme' command.
Unfortunately, Solaris 10 ships with a bug that causes the system to
refuse to plumb the interfaces back into the system.

The following warning messages might be seen during the BRCMbcme
driver package installation :

devfsadm: driver failed to attach: bcme
Warning: Driver (bcme) successfully added to the system but failed to attach

To get around this problem, first make sure the package has been added
to the system, then perform the following steps :

1. Unplumb all the bcme interfaces from the system.
2. Execute the following command : 'rem_drv bcme'
3. Make your changes to the /kernel/drv/bcme.conf file.
4. Copy the BRCMbcme.tar.Z file to a temporary location.
5. Enter 'uncompress BRCMbcme.tar.Z'
6. Enter 'tar xvf BRCMbcme.tar'
7. Enter 'cd BRCMbcme/install'
8. Enter 'sh postinstall'

You can now plumb your bcme interfaces back into the system and your
changes will have taken effect.

Using a more drastic method, you can also have configuration changes
take effect by rebooting the system.


New DHCP deconfiguration changes
--------------------------------

Solaris 10 no longer allows the administrator to deconfigure a DHCP
interface by just unplumbing it.  If the device is deconfigured in this
way, the module will not be unloadable.  There are two ways to work
around this issue :

1) If the administrator has a plumbed and DHCP configured interface,
   (s)he must release the interface from DHCP control first by
   issuing the following command :

   ifconfig bcme$instance dhcp drop

   From there the administrator can then desconstruct the interface the
   rest of the way using the normal deconstruction procedure.

2) In the event that the administrator had accidentally unplumbed the
   interface first, (s)he must find the corresponding dhcpagent
   process ID in the process list (ps -A), and kill it using the
   following command :

   kill -15 <process ID>
