Commit 8847b8e6 authored by Russell King's avatar Russell King

Merge flint.arm.linux.org.uk:/usr/src/linux-bk-2.5/linux-2.5

into flint.arm.linux.org.uk:/usr/src/linux-bk-2.5/linux-2.5-rmk
parents 8a7f3127 a814d16f
3COM PCI TOKEN LINK VELOCITY XL TOKEN RING CARDS README
Release 0.9.0 - Release
Jul 17th 2000 Mike Phillips
1.2.0 - Final
Feb 17th 2002 Mike Phillips
Updated for submission to the 2.4.x kernel.
Thanks:
Terry Murphy from 3Com for tech docs and support,
Adam D. Ligas for testing the driver.
Note:
This driver will NOT work with the 3C339 Token Ring cards, you need
to use the tms380 driver instead.
Options:
The driver accepts three options: ringspeed, pkt_buf_sz and message_level.
These options can be specified differently for each card found.
ringspeed: Has one of three settings 0 (default), 4 or 16. 0 will
make the card autosense the ringspeed and join at the appropriate speed,
this will be the default option for most people. 4 or 16 allow you to
explicitly force the card to operate at a certain speed. The card will fail
if you try to insert it at the wrong speed. (Although some hubs will allow
this so be *very* careful). The main purpose for explicitly setting the ring
speed is for when the card is first on the ring. In autosense mode, if the card
cannot detect any active monitors on the ring it will open at the same speed as
its last opening. This can be hazardous if this speed does not match the speed
you want the ring to operate at.
pkt_buf_sz: This is this initial receive buffer allocation size. This will
default to 4096 if no value is entered. You may increase performance of the
driver by setting this to a value larger than the network packet size, although
the driver now re-sizes buffers based on MTU settings as well.
message_level: Controls level of messages created by the driver. Defaults to 0:
which only displays start-up and critical messages. Presently any non-zero
value will display all soft messages as well. NB This does not turn
debuging messages on, that must be done by modified the source code.
Variable MTU size:
The driver can handle a MTU size upto either 4500 or 18000 depending upon
ring speed. The driver also changes the size of the receive buffers as part
of the mtu re-sizing, so if you set mtu = 18000, you will need to be able
to allocate 16 * (sk_buff with 18000 buffer size) call it 18500 bytes per ring
position = 296,000 bytes of memory space, plus of course anything
necessary for the tx sk_buff's. Remember this is per card, so if you are
building routers, gateway's etc, you could start to use a lot of memory
real fast.
2/17/02 Mike Phillips
Linux* Base Driver for the Intel(R) PRO/1000 Family of Adapters
===============================================================
February 5, 2002
Contents
========
- In This Release
- Supported Adapters
- Command Line Parameters
- Speed and Duplex Configuration
- Known Issues
- Support
In This Release
===============
This file describes the Linux* Base Driver for the Intel(R) PRO/1000 Family
of Adapters, version 4.2.x.
This driver includes support for Itanium(TM)-based systems.
This release version includes the following:
- support for the ethtool 1.4 interface. A third-party application can use
the ethtool interface to get and set driver parameters.
- the zero copy feature. Zero copy provides faster information throughput.
By default, this feature is enabled if using a kernel that supports it.
Zero copy is not supported on the original PWLA8490 (plain) adapter.
Supported Adapters
==================
The following Intel network adapters are compatible with the drivers in this
release:
Controller Adapter Name Board IDs
---------- ------------ ---------
82542 PRO/1000 Gigabit Server Adapter 700262-xxx, 717037-xxx
82543 PRO/1000 F Server Adapter 738640-xxx, A38888-xxx,
A06512-xxx
82543 PRO/1000 T Server Adapter A19845-xxx, A33948-xxx
82544 PRO/1000 XT Server Adapter A51580-xxx
82544 PRO/1000 XF Server Adapter A50484-xxx
82544 PRO/1000 T Desktop Adapter A62947-xxx
To verify your Intel adapter is supported, find the board ID number on the
adapter. Look for a label that has a barcode and a number in the format of
123456-001 (six digits hyphen three digits). Match this to the list of
numbers above.
For more information on how to identify your adapter, go to the Adapter &
Driver ID Guide at:
http://support.intel.com/support/network/adapter/pro100/21397.htm
For the latest Intel network drivers for Linux, go to:
http://appsr.intel.com/scripts-df/support_intel.asp
Command Line Parameters
=======================
If the driver is built as a module, the following parameters are used by
entering them on the command line with the modprobe or insmod command.
For example, with two PRO/1000 PCI adapters, entering:
insmod e1000 TxDescriptors=80,128
loads the e1000 driver with 80 TX resources for the first adapter and 128 TX
resources for the second adapter.
For more information about the AutoNeg, Duplex, and Speed parameters, see the
"Speed and Duplex Configuration" section in this document.
AutoNeg (Intel PRO/1000 T and PRO/1000 XT server adapters only)
Valid Range: 0-0x0F, 0x20-0x2F
Default Value: 0x2F
This parameter is a bit mask that specifies which speed and duplex
settings the board advertises. When this parameter is used, the Speed and
Duplex parameters must not be specified.
Duplex (Intel PRO/1000 T and PRO/1000 XT server adapters only)
Valid Range: 0-2 (0=auto-negotiate, 1=half, 2=full)
Default Value: 0
Defines the direction in which data is allowed to flow. Can by either one
or two-directional. If both Duplex and the link partner are set to auto-
negotiate, the board auto-detects the correct duplex. If the link partner
is forced (either full or half), Duplex defaults to half-duplex.
FlowControl
Valid Range: 0-3 (0=none, 1=Rx only, 2=Tx only, 3=Rx&Tx)
Default: Read flow control settings from the EEPROM
This parameter controls the automatic generation(Tx) and response(Rx) to
Ethernet PAUSE frames.
RxDescriptors
Valid Range: 80-256 for 82542 and 82543-based adapters
80-4096 for 82544-based adapters
Default Value: 256
This value is the number of receive descriptors allocated by the driver.
Increasing this value allows the driver to buffer more incoming packets.
Each descriptor is 16 bytes. A receive buffer is also allocated for each
descriptor and can be either 2048, 4096, 8192, or 16384 bytes, depending
on the MTU setting.
RxIntDelay
Valid Range: 0-65535 (0=off)
Default Value: 64
This value delays the generation of receive interrupts in units of 1.024
microseconds. Receive interrupt reduction can improve CPU efficiency if
properly tuned for specific network traffic. Increasing this value adds
extra latency to frame reception and can end up decreasing the throughput
of TCP traffic. If the system is reporting dropped receives, this value
may be set too high, causing the driver to run out of available receive
descriptors.
Speed (Intel PRO/1000 T and PRO/1000 XT server adapters only)
Valid Settings: 0, 10, 100, 1000
Default Value: 0 (auto-negotiate at all supported speeds)
Speed forces the line speed to the specified value in megabits per second
(Mbps). If this parameter is not specified or is set to 0 and the link
partner is set to auto-negotiate, the board will auto-detect the correct
speed. Duplex must also be set when Speed is set to either 10 or 100.
TxDescriptors
Valid Range: 80-256 for 82542 and 82543-based adapters
80-4096 for 82544-based adapters
Default Value: 256
This value is the number of transmit descriptors allocated by the driver.
Increasing this value allows the driver to queue more transmits. Each
descriptor is 16 bytes.
TxIntDelay
Valid Range: 0-65535 (0=off)
Default Value: 64
This value delays the generation of transmit interrupts in units of 1.024
microseconds. Transmit interrupt reduction can improve CPU efficiency if
properly tuned for specific network traffic. If the system is reporting
dropped transmits, this value may be set too high causing the driver to
run out of available transmit descriptors.
XsumRX (not available on the PRO/1000 Gigabit Server Adapter)
Valid Range: 0-1
Default Value: 1
A value of '1' indicates that the driver should enable IP checksum
offload for received packets (both UDP and TCP) to the adapter hardware.
Speed and Duplex Configuration
==============================
Three keywords are used to control the speed and duplex configuration of the
PRO/1000 T and PRO/1000 XT server adapters. These keywords are Speed, Duplex,
and AutoNeg.
If the board uses a fiber interface, these keywords are ignored, and the
fiber interface board only links at 1000 Mbps full-duplex.
For copper-based boards, the keywords interact as follows:
The default operation is auto-negotiate. The board advertises all supported
speed and duplex combinations, and it links at the highest common speed and
duplex mode IF the link partner is set to auto-negotiate.
If Speed = 1000, limited auto-negotiation is enabled and only 1000 Mbps is
advertised (The 1000BaseT spec requires auto-negotiation.)
If Speed = 10 or 100, then both Speed and Duplex must be set. Auto-
negotiation is disabled, and the AutoNeg parameter is ignored. Partner MUST
also be forced.
The AutoNeg parameter is used when more control is required over the auto-
negotiation process. When this parameter is used, Speed and Duplex must not
be specified. This parameter is a bitmap that specifies which speed and
duplex settings are advertised to the link partner.
Bit 7 6 5 4 3 2 1 0
Speed (Mbps) N/A N/A 1000 N/A 100 100 10 10
Duplex Full Full Half Full Half
Note that setting AutoNeg does not guarantee that the board will link at the
highest specified speed or duplex mode, but the board will link at the
highest possible speed/duplex of the link partner IF the link partner is also
set to auto-negotiate. If the link partner is forced speed/duplex, the
adapter MUST be forced to the same speed/duplex.
Known Issues
============
Driver Hangs Under Heavy Traffic Loads
--------------------------------------
Intel is aware that previously released e1000 drivers may hang under very
specific types of heavy traffic loads. This version includes a workaround
that resets the adapter automatically if a hang condition is detected. This
workaround ensures network traffic flow is not affected when a hang occurs.
Jumbo Frames System Requirement
-------------------------------
Memory allocation failures have been observed on Linux systems with 64 MB
of RAM or less that are running Jumbo Frames. If you are using Jumbo
Frames, your system may require more than the advertised minimum
requirement of 64 MB of system memory.
Support
=======
For general information and support, go to the Intel support website at:
http://support.intel.com
If an issue is identified with the released source code on the supported
kernel with a supported adapter, email the specific information related to
the issue to linux.nics@intel.com.
License
=======
This software program is released under the terms of a license agreement
between you ('Licensee') and Intel. Do not use or load this software or any
associated materials (collectively, the 'Software') until you have carefully
read the full terms and conditions of the LICENSE located in this software
package. By loading or using the Software, you agree to the terms of this
Agreement. If you do not agree with the terms of this Agreement, do not
install or use the Software.
* Other names and brands may be claimed as the property of others.
......@@ -69,6 +69,14 @@ S: Status, one of the following:
it has been replaced by a better system and you
should be using that.
3C359 NETWORK DRIVER
P: Mike Phillips
M: mikep@linuxtr.net
L: linux-net@vger.rutgers.edu
L: linux-tr@linuxtr.net
W: http://www.linuxtr.net
S: Maintained
3C501 NETWORK DRIVER
P: Alan Cox
M: alan@the.3c501.cabal.tm
......@@ -777,6 +785,13 @@ P: Tigran Aivazian
M: tigran@veritas.com
S: Maintained
INTEL PRO/1000 GIGABIT ETHERNET SUPPORT
P: Chris Leech
M: christopher.leech@intel.com
P: Scott Feldman
M: scott.feldman@intel.com
S: Supported
INTERMEZZO FILE SYSTEM
P: Peter J. Braam
M: braam@clusterfs.com
......
......@@ -173,22 +173,11 @@ static struct hpsb_highlevel *hl_handle = NULL;
* defined way to get at the kernel page tables.
*/
static inline unsigned long uvirt_to_bus(unsigned long adr)
{
unsigned long kva, ret;
kva = page_address(vmalloc_to_page(adr));
ret = virt_to_bus((void *)kva);
MDEBUG(printk("uv2b(%lx-->%lx)", adr, ret));
return ret;
}
static inline unsigned long kvirt_to_bus(unsigned long adr)
{
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *)adr));
ret = virt_to_bus((void *)kva);
MDEBUG(printk("kv2b(%lx-->%lx)", adr, ret));
return ret;
......@@ -200,10 +189,9 @@ static inline unsigned long kvirt_to_bus(unsigned long adr)
*/
static inline unsigned long kvirt_to_pa(unsigned long adr)
{
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *)adr));
ret = __pa(kva);
MDEBUG(printk("kv2pa(%lx-->%lx)", adr, ret));
return ret;
......
......@@ -141,24 +141,33 @@ __setup("bttv.radio=", p_radio);
* defined way to get at the kernel page tables.
*/
static inline unsigned long uvirt_to_bus(unsigned long adr)
{
unsigned long kva, ret;
kva = page_address(vmalloc_to_page(adr));
ret = virt_to_bus((void *)kva);
MDEBUG(printk("uv2b(%lx-->%lx)", adr, ret));
return ret;
/*
* Take a vmalloc address, and turn it into
* the aliased kernel virtual address..
*
* CAREFUL! Anybody who does this gets to sit
* in their own cr*p when it comes to virtual
* cache aliases. It's _your_ problem.
*
* Also, note how it only works within one page.
* If you're doing page-crossing stuff, you're on
* your own.
*
* THIS IS BROKEN CODE! You shouldn't do things
* like this.
*/
static inline void *vmalloc_to_virt(void *addr)
{
struct page *page = vmalloc_to_page(addr);
return page_address(page) + (~PAGE_MASK & (unsigned long)addr);
}
static inline unsigned long kvirt_to_bus(unsigned long adr)
static inline unsigned long kvirt_to_bus(unsigned long addr)
{
unsigned long va, kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
ret = virt_to_bus((void *)kva);
MDEBUG(printk("kv2b(%lx-->%lx)", adr, ret));
unsigned long ret;
ret = virt_to_bus(vmalloc_to_virt((void *)addr));
MDEBUG(printk("kv2b(%lx-->%lx)", addr, ret));
return ret;
}
......@@ -166,21 +175,18 @@ static inline unsigned long kvirt_to_bus(unsigned long adr)
* This is used when initializing the contents of the
* area and marking the pages as reserved.
*/
static inline unsigned long kvirt_to_pa(unsigned long adr)
static inline unsigned long kvirt_to_pa(unsigned long addr)
{
unsigned long va, kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
ret = __pa(kva);
MDEBUG(printk("kv2pa(%lx-->%lx)", adr, ret));
unsigned long ret;
ret = virt_to_phys(vmalloc_to_virt((void *)addr));
MDEBUG(printk("kv2pa(%lx-->%lx)", addr, ret));
return ret;
}
static void * rvmalloc(signed long size)
{
void * mem;
unsigned long adr, page;
unsigned long adr;
mem=vmalloc_32(size);
if (NULL == mem)
......@@ -191,8 +197,7 @@ static void * rvmalloc(signed long size)
adr=(unsigned long) mem;
while (size > 0)
{
page = kvirt_to_pa(adr);
mem_map_reserve(virt_to_page(__va(page)));
mem_map_reserve(vmalloc_to_page((void *)adr));
adr+=PAGE_SIZE;
size-=PAGE_SIZE;
}
......@@ -202,15 +207,14 @@ static void * rvmalloc(signed long size)
static void rvfree(void * mem, signed long size)
{
unsigned long adr, page;
unsigned long adr;
if (mem)
{
adr=(unsigned long) mem;
while (size > 0)
{
page = kvirt_to_pa(adr);
mem_map_unreserve(virt_to_page(__va(page)));
mem_map_unreserve(vmalloc_to_page((void *)adr));
adr+=PAGE_SIZE;
size-=PAGE_SIZE;
}
......
......@@ -186,10 +186,9 @@ static void reset_camera_struct(struct cam_data *cam);
*/
static inline unsigned long kvirt_to_pa(unsigned long adr)
{
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *)adr));
ret = __pa(kva);
return ret;
}
......
......@@ -123,10 +123,9 @@ static inline int meye_emptyq(struct meye_queue *queue, int *elem) {
* area and marking the pages as reserved.
*/
static inline unsigned long kvirt_to_pa(unsigned long adr) {
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *) adr));
ret = __pa(kva);
MDEBUG(printk("kv2pa(%lx-->%lx)\n", adr, ret));
return ret;
......
......@@ -806,6 +806,42 @@ CONFIG_DL2K
say M here and read <file:Documentation/modules.txt>. This is
recommended. The module will be called dl2k.o.
CONFIG_E1000
This driver supports Intel(R) PRO/1000 gigabit ethernet family of
adapters, which includes:
Controller Adapter Name Board IDs
---------- ------------ ---------
82542 PRO/1000 Gigabit Server Adapter 700262-xxx,
717037-xxx
82543 PRO/1000 F Server Adapter 738640-xxx,
A38888-xxx,
A06512-xxx
82543 PRO/1000 T Server Adapter A19845-xxx,
A33948-xxx
82544 PRO/1000 XT Server Adapter A51580-xxx
82544 PRO/1000 XF Server Adapter A50484-xxx
82544 PRO/1000 T Desktop Adapter A62947-xxx
For more information on how to identify your adapter, go to the
Adapter & Driver ID Guide at:
<http://support.intel.com/support/network/adapter/pro100/21397.htm>
For general information and support, go to the Intel support
website at:
<http://support.intel.com>
More specific information on configuring the driver is in
<file:Documentation/networking/e1000.txt>.
This driver is also available as a module ( = code which can be
inserted in and removed from the running kernel whenever you want).
The module will be called e1000.o. If you want to compile it as a
module, say M here and read <file:Documentation/modules.txt> as well
as <file:Documentation/networking/net-modules.txt>.
CONFIG_LANCE
If you have a network (Ethernet) card of this type, say Y and read
the Ethernet-HOWTO, available from
......
......@@ -231,6 +231,7 @@ if [ "$CONFIG_ACENIC" != "n" ]; then
bool ' Omit support for old Tigon I based AceNICs' CONFIG_ACENIC_OMIT_TIGON_I
fi
dep_tristate 'D-Link DL2000-based Gigabit Ethernet support' CONFIG_DL2K $CONFIG_PCI
dep_tristate 'Intel(R) PRO/1000 Gigabit Ethernet support' CONFIG_E1000 $CONFIG_PCI
dep_tristate 'MyriCOM Gigabit Ethernet support' CONFIG_MYRI_SBUS $CONFIG_SBUS
dep_tristate 'National Semiconduct DP83820 support' CONFIG_NS83820 $CONFIG_PCI
dep_tristate 'Packet Engines Hamachi GNIC-II support' CONFIG_HAMACHI $CONFIG_PCI
......
......@@ -25,6 +25,10 @@ ifeq ($(CONFIG_TULIP),y)
obj-y += tulip/tulip.o
endif
ifeq ($(CONFIG_E1000),y)
obj-y += e1000/e1000.o
endif
ifeq ($(CONFIG_ISDN_PPP),y)
obj-$(CONFIG_ISDN) += slhc.o
endif
......@@ -32,6 +36,7 @@ endif
subdir-$(CONFIG_NET_PCMCIA) += pcmcia
subdir-$(CONFIG_NET_WIRELESS) += wireless
subdir-$(CONFIG_TULIP) += tulip
subdir-$(CONFIG_E1000) += e1000
subdir-$(CONFIG_IRDA) += irda
subdir-$(CONFIG_TR) += tokenring
subdir-$(CONFIG_WAN) += wan
......
This software program is available to you under a choice of one of two
licenses. You may choose to be licensed under either the GNU General Public
License (GPL) Version 2, June 1991, available at
http://www.fsf.org/copyleft/gpl.html, or the Intel BSD + Patent License, the
text of which follows:
Recipient has requested a license and Intel Corporation ("Intel") is willing
to grant a license for the software entitled Linux Base Driver for the
Intel(R) PRO/1000 Family of Adapters (e1000) (the "Software") being provided
by Intel Corporation. The following definitions apply to this license:
"Licensed Patents" means patent claims licensable by Intel Corporation which
are necessarily infringed by the use of sale of the Software alone or when
combined with the operating system referred to below.
"Recipient" means the party to whom Intel delivers this Software.
"Licensee" means Recipient and those third parties that receive a license to
any operating system available under the GNU Public License version 2.0 or
later.
Copyright (c) 1999 - 2002 Intel Corporation.
All rights reserved.
The license is provided to Recipient and Recipient's Licensees under the
following terms.
Redistribution and use in source and binary forms of the Software, with or
without modification, are permitted provided that the following conditions
are met:
Redistributions of source code of the Software may retain the above
copyright notice, this list of conditions and the following disclaimer.
Redistributions in binary form of the Software may reproduce the above
copyright notice, this list of conditions and the following disclaimer in
the documentation and/or materials provided with the distribution.
Neither the name of Intel Corporation nor the names of its contributors
shall be used to endorse or promote products derived from this Software
without specific prior written permission.
Intel hereby grants Recipient and Licensees a non-exclusive, worldwide,
royalty-free patent license under Licensed Patents to make, use, sell, offer
to sell, import and otherwise transfer the Software, if any, in source code
and object code form. This license shall include changes to the Software
that are error corrections or other minor changes to the Software that do
not add functionality or features when the Software is incorporated in any
version of an operating system that has been distributed under the GNU
General Public License 2.0 or later. This patent license shall apply to the
combination of the Software and any operating system licensed under the GNU
Public License version 2.0 or later if, at the time Intel provides the
Software to Recipient, such addition of the Software to the then publicly
available versions of such operating systems available under the GNU Public
License version 2.0 or later (whether in gold, beta or alpha form) causes
such combination to be covered by the Licensed Patents. The patent license
shall not apply to any other combinations which include the Software. NO
hardware per se is licensed hereunder.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MECHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR IT CONTRIBUTORS BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
ANY LOSS OF USE; DATA, OR PROFITS; OR BUSINESS INTERUPTION) HOWEVER CAUSED
AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR
TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# Makefile for the Intel(R) PRO/1000 ethernet driver
#
# Note! Dependencies are done automagically by 'make dep', which also
# removes any old dependencies. DON'T put your own dependencies here
# unless it's something special (ie not a .c file).
#
# Note 2! The CFLAGS definitions are now in the main makefile...
O_TARGET := e1000.o
obj-y := e1000_main.o e1000_mac.o e1000_phy.o \
e1000_ethtool.o e1000_param.o e1000_proc.o
obj-m := $(O_TARGET)
include $(TOPDIR)/Rules.make
/*******************************************************************************
This software program is available to you under a choice of one of two
licenses. You may choose to be licensed under either the GNU General Public
License (GPL) Version 2, June 1991, available at
http://www.fsf.org/copyleft/gpl.html, or the Intel BSD + Patent License, the
text of which follows:
Recipient has requested a license and Intel Corporation ("Intel") is willing
to grant a license for the software entitled Linux Base Driver for the
Intel(R) PRO/1000 Family of Adapters (e1000) (the "Software") being provided
by Intel Corporation. The following definitions apply to this license:
"Licensed Patents" means patent claims licensable by Intel Corporation which
are necessarily infringed by the use of sale of the Software alone or when
combined with the operating system referred to below.
"Recipient" means the party to whom Intel delivers this Software.
"Licensee" means Recipient and those third parties that receive a license to
any operating system available under the GNU Public License version 2.0 or
later.
Copyright (c) 1999 - 2002 Intel Corporation.
All rights reserved.
The license is provided to Recipient and Recipient's Licensees under the
following terms.
Redistribution and use in source and binary forms of the Software, with or
without modification, are permitted provided that the following conditions
are met:
Redistributions of source code of the Software may retain the above
copyright notice, this list of conditions and the following disclaimer.
Redistributions in binary form of the Software may reproduce the above
copyright notice, this list of conditions and the following disclaimer in
the documentation and/or materials provided with the distribution.
Neither the name of Intel Corporation nor the names of its contributors
shall be used to endorse or promote products derived from this Software
without specific prior written permission.
Intel hereby grants Recipient and Licensees a non-exclusive, worldwide,
royalty-free patent license under Licensed Patents to make, use, sell, offer
to sell, import and otherwise transfer the Software, if any, in source code
and object code form. This license shall include changes to the Software
that are error corrections or other minor changes to the Software that do
not add functionality or features when the Software is incorporated in any
version of an operating system that has been distributed under the GNU
General Public License 2.0 or later. This patent license shall apply to the
combination of the Software and any operating system licensed under the GNU
Public License version 2.0 or later if, at the time Intel provides the
Software to Recipient, such addition of the Software to the then publicly
available versions of such operating systems available under the GNU Public
License version 2.0 or later (whether in gold, beta or alpha form) causes
such combination to be covered by the Licensed Patents. The patent license
shall not apply to any other combinations which include the Software. NO
hardware per se is licensed hereunder.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MECHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR IT CONTRIBUTORS BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
ANY LOSS OF USE; DATA, OR PROFITS; OR BUSINESS INTERUPTION) HOWEVER CAUSED
AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR
TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*******************************************************************************/
/* Linux PRO/1000 Ethernet Driver main header file */
#ifndef _E1000_H_
#define _E1000_H_
#include <linux/stddef.h>
#include <linux/config.h>
#include <linux/module.h>
#include <linux/types.h>
#include <asm/byteorder.h>
#include <linux/init.h>
#include <linux/mm.h>
#include <linux/errno.h>
#include <linux/ioport.h>
#include <linux/pci.h>
#include <linux/kernel.h>
#include <linux/netdevice.h>
#include <linux/etherdevice.h>
#include <linux/skbuff.h>
#include <linux/delay.h>
#include <linux/timer.h>
#include <linux/slab.h>
#include <linux/interrupt.h>
#include <linux/string.h>
#include <linux/pagemap.h>
#include <asm/bitops.h>
#include <asm/io.h>
#include <asm/irq.h>
#include <linux/capability.h>
#include <linux/in.h>
#include <linux/ip.h>
#include <linux/tcp.h>
#include <linux/udp.h>
#include <net/pkt_sched.h>
#include <linux/list.h>
#include <asm/uaccess.h>
struct e1000_adapter;
#include "e1000_mac.h"
#include "e1000_phy.h"
#define BAR_0 0
/* Advertise that we can DMA from any address location */
#define E1000_DMA_MASK (~0x0UL)
#if DBG
#define E1000_DBG(args...) printk(KERN_DEBUG "e1000: " args)
#else
#define E1000_DBG(args...)
#endif
#define E1000_ERR(args...) printk(KERN_ERR "e1000: " args)
#ifdef CONFIG_PPC
#define E1000_MAX_INTR 1
#else
#define E1000_MAX_INTR 10
#endif
/* Supported Rx Buffer Sizes */
#define E1000_RXBUFFER_2048 2048
#define E1000_RXBUFFER_4096 4096
#define E1000_RXBUFFER_8192 8192
#define E1000_RXBUFFER_16384 16384
/* How many Tx Descriptors do we need to call netif_wake_queue ? */
#define E1000_TX_QUEUE_WAKE 16
#define E1000_JUMBO_PBA 0x00000028
#define E1000_DEFAULT_PBA 0x00000030
/* only works for sizes that are powers of 2 */
#define E1000_ROUNDUP(i, size) ((i) = (((i) + (size) - 1) & ~((size) - 1)))
/* wrapper around a pointer to a socket buffer,
* so a DMA handle can be stored along with the buffer */
struct e1000_buffer {
struct sk_buff *skb;
uint64_t dma;
unsigned long length;
};
struct e1000_desc_ring {
/* pointer to the descriptor ring memory */
void *desc;
/* physical address of the descriptor ring */
dma_addr_t dma;
/* length of descriptor ring in bytes */
unsigned int size;
/* number of descriptors in the ring */
unsigned int count;
/* (atomic) number of desc with no buffer */
atomic_t unused;
/* number of desc with no buffer */
unsigned int unused_count;
/* next descriptor to associate a buffer with */
unsigned int next_to_use;
/* next descriptor to check for DD status bit */
unsigned int next_to_clean;
/* array of buffer information structs */
struct e1000_buffer *buffer_info;
};
#define E1000_RX_DESC(ring, i) \
(&(((struct e1000_rx_desc *)((ring).desc))[i]))
#define E1000_TX_DESC(ring, i) \
(&(((struct e1000_tx_desc *)((ring).desc))[i]))
#define E1000_CONTEXT_DESC(ring, i) \
(&(((struct e1000_context_desc *)((ring).desc))[i]))
/* board specific private data structure */
struct e1000_adapter {
struct timer_list watchdog_timer;
struct timer_list phy_info_timer;
#ifdef CONFIG_PROC_FS
struct list_head proc_list_head;
#endif
char *id_string;
uint32_t bd_number;
uint32_t rx_buffer_len;
uint32_t part_num;
uint32_t wol;
uint16_t link_speed;
uint16_t link_duplex;
spinlock_t stats_lock;
atomic_t irq_sem;
boolean_t rx_csum;
/* TX */
struct e1000_desc_ring tx_ring;
unsigned long trans_finish;
uint32_t tx_int_delay;
uint32_t txd_cmd;
/* RX */
struct e1000_desc_ring rx_ring;
uint64_t hw_csum_err;
uint64_t hw_csum_good;
uint32_t rx_int_delay;
/* OS defined structs */
struct net_device *netdev;
struct pci_dev *pdev;
struct net_device_stats net_stats;
/* structs defined in e1000_mac.h or e1000_phy.h */
struct e1000_shared_adapter shared;
struct e1000_shared_stats stats;
struct e1000_phy_info phy_info;
struct e1000_phy_stats phy_stats;
};
#endif /* _E1000_H_ */
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/*******************************************************************************
This software program is available to you under a choice of one of two
licenses. You may choose to be licensed under either the GNU General Public
License (GPL) Version 2, June 1991, available at
http://www.fsf.org/copyleft/gpl.html, or the Intel BSD + Patent License, the
text of which follows:
Recipient has requested a license and Intel Corporation ("Intel") is willing
to grant a license for the software entitled Linux Base Driver for the
Intel(R) PRO/1000 Family of Adapters (e1000) (the "Software") being provided
by Intel Corporation. The following definitions apply to this license:
"Licensed Patents" means patent claims licensable by Intel Corporation which
are necessarily infringed by the use of sale of the Software alone or when
combined with the operating system referred to below.
"Recipient" means the party to whom Intel delivers this Software.
"Licensee" means Recipient and those third parties that receive a license to
any operating system available under the GNU Public License version 2.0 or
later.
Copyright (c) 1999 - 2002 Intel Corporation.
All rights reserved.
The license is provided to Recipient and Recipient's Licensees under the
following terms.
Redistribution and use in source and binary forms of the Software, with or
without modification, are permitted provided that the following conditions
are met:
Redistributions of source code of the Software may retain the above
copyright notice, this list of conditions and the following disclaimer.
Redistributions in binary form of the Software may reproduce the above
copyright notice, this list of conditions and the following disclaimer in
the documentation and/or materials provided with the distribution.
Neither the name of Intel Corporation nor the names of its contributors
shall be used to endorse or promote products derived from this Software
without specific prior written permission.
Intel hereby grants Recipient and Licensees a non-exclusive, worldwide,
royalty-free patent license under Licensed Patents to make, use, sell, offer
to sell, import and otherwise transfer the Software, if any, in source code
and object code form. This license shall include changes to the Software
that are error corrections or other minor changes to the Software that do
not add functionality or features when the Software is incorporated in any
version of an operating system that has been distributed under the GNU
General Public License 2.0 or later. This patent license shall apply to the
combination of the Software and any operating system licensed under the GNU
Public License version 2.0 or later if, at the time Intel provides the
Software to Recipient, such addition of the Software to the then publicly
available versions of such operating systems available under the GNU Public
License version 2.0 or later (whether in gold, beta or alpha form) causes
such combination to be covered by the Licensed Patents. The patent license
shall not apply to any other combinations which include the Software. NO
hardware per se is licensed hereunder.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MECHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR IT CONTRIBUTORS BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
ANY LOSS OF USE; DATA, OR PROFITS; OR BUSINESS INTERUPTION) HOWEVER CAUSED
AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR
TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*******************************************************************************/
/* glue for the OS independant part of e1000
* includes register access macros
*/
#ifndef _E1000_OSDEP_H_
#define _E1000_OSDEP_H_
#include <linux/types.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <asm/io.h>
#include <linux/interrupt.h>
#define usec_delay(x) udelay(x)
#define msec_delay(x) do { if(in_interrupt()) { \
mdelay(x); \
} else { \
set_current_state(TASK_UNINTERRUPTIBLE); \
schedule_timeout((x * HZ)/1000); \
} } while(0)
#define PCI_COMMAND_REGISTER PCI_COMMAND
#define CMD_MEM_WRT_INVALIDATE PCI_COMMAND_INVALIDATE
typedef enum {
FALSE = 0,
TRUE = 1
} boolean_t;
#define ASSERT(x) if(!(x)) BUG()
#define MSGOUT(S, A, B) printk(KERN_DEBUG S "\n", A, B)
#if DBG
#define DEBUGOUT(S) printk(KERN_DEBUG S "\n")
#define DEBUGOUT1(S, A...) printk(KERN_DEBUG S "\n", A)
#else
#define DEBUGOUT(S)
#define DEBUGOUT1(S, A...)
#endif
#define DEBUGFUNC(F) DEBUGOUT(F)
#define DEBUGOUT2 DEBUGOUT1
#define DEBUGOUT3 DEBUGOUT2
#define DEBUGOUT7 DEBUGOUT3
#define E1000_WRITE_REG(a, reg, value) ( \
((a)->mac_type >= e1000_82543) ? \
(writel((value), ((a)->hw_addr + E1000_##reg))) : \
(writel((value), ((a)->hw_addr + E1000_82542_##reg))))
#define E1000_READ_REG(a, reg) ( \
((a)->mac_type >= e1000_82543) ? \
readl((a)->hw_addr + E1000_##reg) : \
readl((a)->hw_addr + E1000_82542_##reg))
#define E1000_WRITE_REG_ARRAY(a, reg, offset, value) ( \
((a)->mac_type >= e1000_82543) ? \
writel((value), ((a)->hw_addr + E1000_##reg + ((offset) << 2))) : \
writel((value), ((a)->hw_addr + E1000_82542_##reg + ((offset) << 2))))
#define E1000_READ_REG_ARRAY(a, reg, offset) ( \
((a)->mac_type >= e1000_82543) ? \
readl((a)->hw_addr + E1000_##reg + ((offset) << 2)) : \
readl((a)->hw_addr + E1000_82542_##reg + ((offset) << 2)))
#endif /* _E1000_OSDEP_H_ */
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/*
* 3c359.h (c) 2000 Mike Phillips (mikep@linuxtr.net) All Rights Reserved
*
* Linux driver for 3Com 3C359 Token Link PCI XL cards.
*
* This software may be used and distributed according to the terms
* of the GNU General Public License Version 2 or (at your option)
* any later verion, incorporated herein by reference.
*/
/* Memory Access Commands */
#define IO_BYTE_READ 0x28 << 24
#define IO_BYTE_WRITE 0x18 << 24
#define IO_WORD_READ 0x20 << 24
#define IO_WORD_WRITE 0x10 << 24
#define MMIO_BYTE_READ 0x88 << 24
#define MMIO_BYTE_WRITE 0x48 << 24
#define MMIO_WORD_READ 0x80 << 24
#define MMIO_WORD_WRITE 0x40 << 24
#define MEM_BYTE_READ 0x8C << 24
#define MEM_BYTE_WRITE 0x4C << 24
#define MEM_WORD_READ 0x84 << 24
#define MEM_WORD_WRITE 0x44 << 24
#define PMBAR 0x1C80
#define PMB_CPHOLD (1<<10)
#define CPATTENTION 0x180D
#define CPA_PMBARVIS (1<<7)
#define CPA_MEMWREN (1<<6)
#define SWITCHSETTINGS 0x1C88
#define EECONTROL 0x1C8A
#define EEDATA 0x1C8C
#define EEREAD 0x0080
#define EEWRITE 0x0040
#define EEERASE 0x0060
#define EE_ENABLE_WRITE 0x0030
#define EEBUSY (1<<15)
#define WRBR 0xCDE02
#define WWOR 0xCDE04
#define WWCR 0xCDE06
#define MACSTATUS 0xCDE08
#define MISR_RW 0xCDE0B
#define MISR_AND 0xCDE2B
#define MISR_SET 0xCDE4B
#define RXBUFAREA 0xCDE10
#define RXEARLYTHRESH 0xCDE12
#define TXSTARTTHRESH 0x58
#define DNPRIREQTHRESH 0x2C
#define MISR_CSRB (1<<5)
#define MISR_RASB (1<<4)
#define MISR_SRBFR (1<<3)
#define MISR_ASBFR (1<<2)
#define MISR_ARBF (1<<1)
/* MISR Flags memory locations */
#define MF_SSBF 0xDFFE0
#define MF_ARBF 0xDFFE1
#define MF_ASBFR 0xDFFE2
#define MF_SRBFR 0xDFFE3
#define MF_RASB 0xDFFE4
#define MF_CSRB 0xDFFE5
#define MMIO_MACDATA 0x10
#define MMIO_MAC_ACCESS_CMD 0x14
#define MMIO_TIMER 0x1A
#define MMIO_DMA_CTRL 0x20
#define MMIO_DNLISTPTR 0x24
#define MMIO_HASHFILTER 0x28
#define MMIO_CONFIG 0x29
#define MMIO_DNPRIREQTHRESH 0x2C
#define MMIO_DNPOLL 0x2D
#define MMIO_UPPKTSTATUS 0x30
#define MMIO_FREETIMER 0x34
#define MMIO_COUNTDOWN 0x36
#define MMIO_UPLISTPTR 0x38
#define MMIO_UPPOLL 0x3C
#define MMIO_UPBURSTTHRESH 0x40
#define MMIO_DNBURSTTHRESH 0x41
#define MMIO_INTSTATUS_AUTO 0x56
#define MMIO_TXSTARTTHRESH 0x58
#define MMIO_INTERRUPTENABLE 0x5A
#define MMIO_INDICATIONENABLE 0x5C
#define MMIO_COMMAND 0x5E /* These two are meant to be the same */
#define MMIO_INTSTATUS 0x5E /* Makes the code more readable this way */
#define INTSTAT_CMD_IN_PROGRESS (1<<12)
#define INTSTAT_SRB (1<<14)
#define INTSTAT_INTLATCH (1<<0)
/* Indication / Interrupt Mask
* Annoyingly the bits to be set in the indication and interrupt enable
* do not match with the actual bits received in the interrupt, although
* they are in the same order.
* The mapping for the indication / interrupt are:
* Bit Indication / Interrupt
* 0 HostError
* 1 txcomplete
* 2 updneeded
* 3 rxcomplete
* 4 intrequested
* 5 macerror
* 6 dncomplete
* 7 upcomplete
* 8 txunderrun
* 9 asbf
* 10 srbr
* 11 arbc
*
* The only ones we don't want to receive are txcomplete and rxcomplete
* we use dncomplete and upcomplete instead.
*/
#define INT_MASK 0xFF5
/* Note the subtle difference here, IND and INT */
#define SETINDENABLE (8<<12)
#define SETINTENABLE (7<<12)
#define SRBBIT (1<<10)
#define ASBBIT (1<<9)
#define ARBBIT (1<<11)
#define SRB 0xDFE90
#define ASB 0xDFED0
#define ARB 0xD0000
#define SCRATCH 0xDFEF0
#define INT_REQUEST 0x6000 /* (6 << 12) */
#define ACK_INTERRUPT 0x6800 /* (13 <<11) */
#define GLOBAL_RESET 0x00
#define DNDISABLE 0x5000
#define DNENABLE 0x4800
#define DNSTALL 0x3002
#define DNRESET 0x5800
#define DNUNSTALL 0x3003
#define UPRESET 0x2800
#define UPSTALL 0x3000
#define UPUNSTALL 0x3001
#define SETCONFIG 0x4000
#define SETTXSTARTTHRESH 0x9800
/* Received Interrupts */
#define ASBFINT (1<<13)
#define SRBRINT (1<<14)
#define ARBCINT (1<<15)
#define TXUNDERRUN (1<<11)
#define UPCOMPINT (1<<10)
#define DNCOMPINT (1<<9)
#define HARDERRINT (1<<7)
#define RXCOMPLETE (1<<4)
#define TXCOMPINT (1<<2)
#define HOSTERRINT (1<<1)
/* Receive descriptor bits */
#define RXOVERRUN (1<<19)
#define RXFC (1<<21)
#define RXAR (1<<22)
#define RXUPDCOMPLETE (1<<23)
#define RXUPDFULL (1<<24)
#define RXUPLASTFRAG (1<<31)
/* Transmit descriptor bits */
#define TXDNCOMPLETE (1<<16)
#define TXTXINDICATE (1<<27)
#define TXDPDEMPTY (1<<29)
#define TXDNINDICATE (1<<31)
#define TXDNFRAGLAST (1<<31)
/* Interrupts to Acknowledge */
#define LATCH_ACK 1
#define TXCOMPACK (1<<1)
#define INTREQACK (1<<2)
#define DNCOMPACK (1<<3)
#define UPCOMPACK (1<<4)
#define ASBFACK (1<<5)
#define SRBRACK (1<<6)
#define ARBCACK (1<<7)
#define XL_IO_SPACE 128
#define SRB_COMMAND_SIZE 50
/* Adapter Commands */
#define REQUEST_INT 0x00
#define MODIFY_OPEN_PARMS 0x01
#define RESTORE_OPEN_PARMS 0x02
#define OPEN_NIC 0x03
#define CLOSE_NIC 0x04
#define SET_SLEEP_MODE 0x05
#define SET_GROUP_ADDRESS 0x06
#define SET_FUNC_ADDRESS 0x07
#define READ_LOG 0x08
#define SET_MULTICAST_MODE 0x0C
#define CHANGE_WAKEUP_PATTERN 0x0D
#define GET_STATISTICS 0x13
#define SET_RECEIVE_MODE 0x1F
/* ARB Commands */
#define RECEIVE_DATA 0x81
#define RING_STATUS_CHANGE 0x84
/* ASB Commands */
#define ASB_RECEIVE_DATE 0x81
/* Defines for LAN STATUS CHANGE reports */
#define LSC_SIG_LOSS 0x8000
#define LSC_HARD_ERR 0x4000
#define LSC_SOFT_ERR 0x2000
#define LSC_TRAN_BCN 0x1000
#define LSC_LWF 0x0800
#define LSC_ARW 0x0400
#define LSC_FPE 0x0200
#define LSC_RR 0x0100
#define LSC_CO 0x0080
#define LSC_SS 0x0040
#define LSC_RING_REC 0x0020
#define LSC_SR_CO 0x0010
#define LSC_FDX_MODE 0x0004
#define XL_MAX_ADAPTERS 8 /* 0x08 __MODULE_STRING can't hand 0xnn */
/* 3c359 defaults for buffers */
#define XL_RX_RING_SIZE 16 /* must be a power of 2 */
#define XL_TX_RING_SIZE 16 /* must be a power of 2 */
#define PKT_BUF_SZ 4096 /* Default packet size */
/* 3c359 data structures */
struct xl_tx_desc {
u32 dnnextptr ;
u32 framestartheader ;
u32 buffer ;
u32 buffer_length ;
};
struct xl_rx_desc {
u32 upnextptr ;
u32 framestatus ;
u32 upfragaddr ;
u32 upfraglen ;
};
struct xl_private {
/* These two structures must be aligned on 8 byte boundaries */
/* struct xl_rx_desc xl_rx_ring[XL_RX_RING_SIZE]; */
/* struct xl_tx_desc xl_tx_ring[XL_TX_RING_SIZE]; */
struct xl_rx_desc *xl_rx_ring ;
struct xl_tx_desc *xl_tx_ring ;
struct sk_buff *tx_ring_skb[XL_TX_RING_SIZE], *rx_ring_skb[XL_RX_RING_SIZE];
int tx_ring_head, tx_ring_tail ;
int rx_ring_tail, rx_ring_no ;
int free_ring_entries ;
u16 srb;
u16 arb;
u16 asb;
u8 *xl_mmio;
char *xl_card_name;
struct pci_dev *pdev ;
spinlock_t xl_lock ;
volatile int srb_queued;
struct wait_queue *srb_wait;
volatile int asb_queued;
struct net_device_stats xl_stats ;
u16 mac_buffer ;
u16 xl_lan_status ;
u8 xl_ring_speed ;
u16 pkt_buf_sz ;
u8 xl_message_level;
u16 xl_copy_all_options ;
unsigned char xl_functional_addr[4] ;
u16 xl_addr_table_addr, xl_parms_addr ;
u8 xl_laa[6] ;
u32 rx_ring_dma_addr ;
u32 tx_ring_dma_addr ;
};
This diff is collapsed.
......@@ -129,3 +129,21 @@ CONFIG_SMCTR
The module will be called smctr.o. If you want to compile it
as a module, say M here and read <file:Documentation/modules.txt>.
3COM 3C359 Token Link Velocity XL PCI adapter support
CONFIG_3C359
This is support for the 3Com PCI Velocity XL cards, specifically
the 3Com 3C359, please note this is not for the 3C339 cards, you
should use the tms380 driver instead.
If you have such an adapter, say Y and read the Token-Ring
mini-HOWTO, available from <http://www.linuxdoc.org/docs.html#howto>.
This driver is also available as a module ( = code which can be
inserted in and removed from the running kernel whenever you want).
The module will will be called 3c359.o. If you want to compile it
as a module, say M here and read Documentation/modules.txt.
Also read the file <file:Documentation/networking/3c359.txt> or check the
Linux Token Ring Project site for the latest information at
<http://www.linuxtr.net>
......@@ -18,6 +18,7 @@ if [ "$CONFIG_TR" != "n" ]; then
fi
dep_tristate ' IBM Olympic chipset PCI adapter support' CONFIG_IBMOL $CONFIG_TR $CONFIG_PCI
dep_tristate ' IBM Lanstreamer chipset PCI adapter support' CONFIG_IBMLS $CONFIG_TR $CONFIG_PCI
dep_tristate ' 3Com 3C359 Token Link Velocity XL adapter support' CONFIG_3C359 $CONFIG_TR $CONFIG_PCI
tristate ' Generic TMS380 Token Ring ISA/PCI adapter support' CONFIG_TMS380TR
if [ "$CONFIG_TMS380TR" != "n" ]; then
dep_tristate ' Generic TMS380 PCI support' CONFIG_TMSPCI $CONFIG_PCI
......
......@@ -21,6 +21,7 @@ obj-$(CONFIG_MADGEMC) += madgemc.o
obj-$(CONFIG_TMSPCI) += tmspci.o
obj-$(CONFIG_TMSISA) += tmsisa.o
obj-$(CONFIG_SMCTR) += smctr.o
obj-$(CONFIG_3C359) += 3c359.o
O_TARGET := tr.o
......
......@@ -321,6 +321,7 @@ enum via_rhine_chips {
VT86C100A = 0,
VT6102,
VT3043,
VT6105,
};
struct via_rhine_chip_info {
......@@ -349,7 +350,7 @@ static struct via_rhine_chip_info via_rhine_chip_info[] __devinitdata =
{ "VIA VT6102 Rhine-II", RHINE_IOTYPE, 256,
CanHaveMII | HasWOL },
{ "VIA VT3043 Rhine", RHINE_IOTYPE, 128,
CanHaveMII | ReqTxAlign }
CanHaveMII | ReqTxAlign },
{ "VIA VT6105 Rhine-III", RHINE_IOTYPE, 256,
CanHaveMII | HasWOL },
};
......
......@@ -380,10 +380,9 @@ static unsigned char uvQuanTable518[] = OV518_UVQUANTABLE;
static inline unsigned long
kvirt_to_pa(unsigned long adr)
{
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *)adr));
ret = __pa(kva);
return ret;
}
......
......@@ -184,10 +184,9 @@ static struct video_device pwc_template = {
*/
static inline unsigned long kvirt_to_pa(unsigned long adr)
{
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *)adr));
ret = __pa(kva);
return ret;
}
......
......@@ -89,10 +89,9 @@ static struct usb_driver se401_driver;
*/
static inline unsigned long kvirt_to_pa(unsigned long adr)
{
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *)adr));
ret = __pa(kva);
return ret;
}
......
......@@ -68,10 +68,9 @@ static int usbvideo_default_procfs_write_proc(
*/
unsigned long usbvideo_kvirt_to_pa(unsigned long adr)
{
unsigned long va, kva, ret;
unsigned long kva, ret;
va = VMALLOC_VMADDR(adr);
kva = page_address(vmalloc_to_page(va));
kva = page_address(vmalloc_to_page((void *)adr));
ret = __pa(kva);
MDEBUG(printk("kv2pa(%lx-->%lx)", adr, ret));
return ret;
......
......@@ -585,7 +585,7 @@ static inline struct vm_area_struct * find_vma_intersection(struct mm_struct * m
extern struct vm_area_struct *find_extend_vma(struct mm_struct *mm, unsigned long addr);
extern struct page * vmalloc_to_page(unsigned long adr);
extern struct page * vmalloc_to_page(void *addr);
#endif /* __KERNEL__ */
......
......@@ -772,6 +772,7 @@
#define PCI_VENDOR_ID_3COM 0x10b7
#define PCI_DEVICE_ID_3COM_3C985 0x0001
#define PCI_DEVICE_ID_3COM_3C339 0x3390
#define PCI_DEVICE_ID_3COM_3C359 0x3590
#define PCI_DEVICE_ID_3COM_3C590 0x5900
#define PCI_DEVICE_ID_3COM_3C595TX 0x5950
#define PCI_DEVICE_ID_3COM_3C595T4 0x5951
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment