1 |
199 |
simons |
|
2 |
|
|
|
3 |
|
|
Application Information
|
4 |
|
|
|
5 |
|
|
The included application, called "rcc" (for RedCreek Control), is an
|
6 |
|
|
example of a user-space application (i.e., not running within kernel
|
7 |
|
|
space). It issues ioctl commands to communicate with the PCI driver.
|
8 |
|
|
It is intended for reference only. It can currently report any of
|
9 |
|
|
the following information:
|
10 |
|
|
|
11 |
|
|
- PCI driver information ("getinfo")
|
12 |
|
|
- card statistics ("getstats")
|
13 |
|
|
- card's ip address & netmask ("getipnmask")
|
14 |
|
|
- card's mac address ("getmac")
|
15 |
|
|
- current speed ("getspeed")
|
16 |
|
|
- firmware version string ("getfirmware")
|
17 |
|
|
- status of the link (up or down) ("getstatus")
|
18 |
|
|
|
19 |
|
|
This program needs to run as root, to avoid encountering permission
|
20 |
|
|
problems. An alternative is to change the permission and ownership
|
21 |
|
|
so that it runs as a setuid root process (for example, "chown
|
22 |
|
|
root.root rcc; chmod u+s rcc").
|
23 |
|
|
|
24 |
|
|
|
25 |
|
|
Quick PCI driver background
|
26 |
|
|
|
27 |
|
|
The adapter has its own IP and mac addresses which you have to
|
28 |
|
|
assign using the RedCreek manager (assuming the adapter is
|
29 |
|
|
running 3.X firmware). Your linux box will not know anything
|
30 |
|
|
about the adapter's IP address -- ie, the adapter will show up
|
31 |
|
|
as a regular nic. You will assign the linux box IP address using
|
32 |
|
|
the "ifconfig" command, as mentioned below.
|
33 |
|
|
|
34 |
|
|
To compile the driver, simply type "make".
|
35 |
|
|
This, of course, assumes that you have GNU compiler environment
|
36 |
|
|
already setup on a linux box. The .c and .h files were copied
|
37 |
|
|
to a dos filesystem (the floppy), so you may have to use "dos2unix" to
|
38 |
|
|
convert it back to a unix text file. Keep in mind that the driver
|
39 |
|
|
currently works with kernels 2.0.X only. Furthermore, it was only
|
40 |
|
|
tested with kernel 2.0.34. There is work being done on porting the
|
41 |
|
|
driver to the 2.1.X kernel, however, it's still incomplete.
|
42 |
|
|
|
43 |
|
|
When the compile is done, you'll send up with three object files
|
44 |
|
|
related to the driver: rcmtl.o, rcpci45.o, and rc.o; rcmtl.o
|
45 |
|
|
is the RedCreek API message layer; rcpci45.o is the upper level
|
46 |
|
|
Linux driver which contains the interface to the kernel. Finally,
|
47 |
|
|
since the driver is compiled as a loadable module, rcmtl.o and
|
48 |
|
|
rcpci45.o are linked together into a third file, rc.o, which is the
|
49 |
|
|
actual driver.
|
50 |
|
|
|
51 |
|
|
To load the driver:
|
52 |
|
|
|
53 |
|
|
"insmod rc"
|
54 |
|
|
|
55 |
|
|
If you are in console mode, you'll see a few messages send by the
|
56 |
|
|
driver. One of the messages will indicated how many adapters were
|
57 |
|
|
found; the messages are also stored in /var/log/messages, so they
|
58 |
|
|
can be viewed later. If you are running X, then you'll have to
|
59 |
|
|
view the messages by examining /var/log/messages.
|
60 |
|
|
|
61 |
|
|
The adapter will show up as a regular nic. Thus, if you have only
|
62 |
|
|
one nic (the pci card) in your box, you would at this point configure
|
63 |
|
|
it with the following commands:
|
64 |
|
|
|
65 |
|
|
mandatory:
|
66 |
|
|
"ifconfig eth0
|
67 |
|
|
adapter!>"
|
68 |
|
|
"route add -net eth0"
|
69 |
|
|
|
70 |
|
|
optional (if you want to be able to access other networks):
|
71 |
|
|
"route add default gw eth0"
|
72 |
|
|
|
73 |
|
|
Done. Type "ifconfig" to see "eth0" and the packet count, as well
|
74 |
|
|
as the IP address, net mask, etc.
|
75 |
|
|
|
76 |
|
|
To unload the driver, you first have to shutdown the interface:
|
77 |
|
|
|
78 |
|
|
"ifconfig eth0 down"
|
79 |
|
|
|
80 |
|
|
Then you unload the driver with "rmmod rc".
|
81 |
|
|
|
82 |
|
|
|
83 |
|
|
For technical support, please send email to Pete Popov at
|
84 |
|
|
ppopov@redcreek.com. Please have as complete of a description of
|
85 |
|
|
the problem as possible.
|