EasyManua.ls Logo

Broadcom BCM5722 - Page 202

Broadcom BCM5722
593 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
BCM5722 Programmer’s Guide
10/15/07
Broadcom Corporation
Page 143 Endian Control (Byte and Word Swapping) Document 5722-PG101-R
ARCHITECTURE
The BCM5722 Ethernet controller is internally a big-endian machine, and its internal processors are big-endian devices. The
BCM5722 Ethernet controller stores data internally in big-endian format using a 64-bit memory subsystem.
However, many hosts (e.g., x86 systems) use the little-endian format, and the PCI bus uses the little-endian format.
Therefore the BCM5722 Ethernet controller has a number of byte swapping options that may be configured by software so
that Little or Big Endian hosts can interface as seamlessly as possible with BCM5722 Ethernet controller over PCI. The
BCM5722 Ethernet controller has the following bits that control byte and word swapping:
Enable Endian Word Swap (bit 3, Miscellaneous Host Control register (offset 0x68 into PCI Config register, se
“Miscellaneous Host Control Register (Offset 0x68)” on page 204). If 1, this register enables 32-bit word swapping when
accessing the BCM5722 Ethernet controller via the PCI target interface.
Enable Endian Byte Swap (bit 2, Miscellaneous Host Control register (offset 0x68 into PCI Config register, see
“Miscellaneous Host Control Register (Offset 0x68)” on page 204). If 1, this register enables byte swapping (within a 32-
bit word) when accessing the BCM5722 Ethernet controller via the PCI target interface.
Word Swap Data (bit 5, Mode Control register (offset 0x6800 into the BCM5722 Ethernet controller registers). If 1, this
register enables word swapping of frame data when it comes across the bus.
Byte Swap Data (bit 4, Mode Control register (offset 0x6800 into the BCM5722 Ethernet controller registers). If 1, this
register enables byte swapping of frame data when it comes across the bus.
Word Swap Non-Frame Data (bit 2, Mode Control register (offset 0x6800 into the BCM5722 Ethernet controller
registers). If 1, this register enables word swapping of non frame data (i.e,. buffer descriptors, statistics, etc.) when it
comes across the bus.
Byte Swap Non-Frame Data (bit 1, Mode Control register (offset 0x6800 into the BCM5722 Ethernet controller
registers). If 1, this register enables byte swapping of non frame data (i.e., buffer descriptors, statistics, etc.) when it
comes across the
bus.
The setting of the above swapping bits will affect the order of how data is represented when it is transferred across PCI.
Since byte swapping is a confusing subject, examples will be shown that reflect how each byte swapping bit works

Table of Contents