Chapter 4. Driver Installation
52 3ware Serial ATA RAID Controller User Guide
To update the kernel with new driver source
1 Copy .c and .h files to
sys/dev/twa and makefile to sys/modules/twa
2 Go to /usr/src/sys/conf/ and edit the files file (use vi or any other editor)
a Remove these lines:
twa/twa.c
twa/twa_cam.c
twa/twa_freebsd.c
twa/twa_fwing.c
twa/twa_globals.c
b Replace them with:
twa/tw_cl_fwimg.c (omit this if using code set 9.3.0.4 or newer)
twa/tw_cl_init.c
twa/tw_cl_initr.c
twa/tw_cl_io.c
twa/tw_cl_misc.c
twa/tw_osl_cam.c
twa/tw_osl_freebsd.c
c Save changes.
3Go to /usr/src/sys/conf/ and edit kern.pre.mk (use vi or any other
editor).
Below this line:
INCLUDES+= -I$S/contrib/ngatm
Add this line: INCLUDES+= -I$S/dev/twa
Save changes.
4Go to
usr/src/sys/i386/conf or /usr/src/sys/amd64/conf,
depending on whether you have a 32-bit or 64-bit version of FreeBSD 5.4
(respectively).
a Edit the
GENERIC file (use vi or any other editor).
b Make sure
Device twa # 3ware 9000 series is not commented
out.
c Save changes.
dDo
config (GENERIC, SMP, PAE), using the flags required for your
hardware, followed by
cd ../compile/SMP
make clean
make cleandepend
make depend
make
make install
5 Reboot your system.
When the system reboots, the new kernel driver module will load
automatically.