I went and got the latest DDK from Citrix and imported it into the XenServer I wanted to make a driver for. On boot up you give it a password, but I also gave it an ip address so I could ssh into it (working in the console is not fun).
I went to the lsi-3ware site and got a copy of the latest code set and scp’d it over to the ddk VM. Since the DDK comes with the latest kernel, I went and checked which kernel it currently was using (2.6.32 in my case), unzipped the code set, and found the 2.6.32 .tgz file. I made a new folder in root to work in, and copied over the helloworld.spec and Makefile from /root/examples/driver/. Then I altered them to reflect the 3ware driver I wanted to make, i.e. wherever there was a reference to helloworld, I’d change it to 3w-sas. Since the driver expects the .tgz to be under /usr/src/redhat/SOURCES/ I went ahead and put it there. Running the make build-srctarballs command was supposed to unzip the .tgz file into the current directory, but because the contents of that .tgz is in a subfolder I manually unzipped it into place. Running make build-iso finished the process, and I was able to copy over the .iso to the dom0 and install the kernel module so under the new kernel we could use the 3ware card.