I have solved this issue on a Debian 2.6.26-2 based system, so I figured I would pass along the steps I followed in hopes it may help someone else solve the issue in the future.
This was performed on a Startech dual port PCIe serial card using the mcs9900/9901 chip.
Before beginning, be sure you have all required build tools. (kernel source / headers, build-essentials, etc..)
1) Download the patch in the post above. Unpack the driver..
Code:
tar xzf starex.tar.gz
..navigate to that directory..
..and copy the patch there as well.
Code:
jones@jones-laptop:~/Desktop/starex$ ls
9900.c 9900-isa.c Makefile readme
9900.h 9900-isa.h mcs9900 starex_2.6.28.patch
3) Apply the patch to the 9900.c source.
Code:
patch < starex_2.6.28.patch
4) Edit the following lines:
Line 622:
--> Old code:
Code:
struct tty_struct *tty = up->port.info->port.tty;
--> New code:
Code:
struct tty_struct *tty = up->port.info->tty;
Line 852:
--> Old code:
Code:
struct tty_struct *tty = up->port.info->port.tty;
--> New code:
Code:
struct tty_struct *tty = up->port.info->tty;
And finally line 957:
--> Old code:
Code:
struct tty_struct *tty = up->port.info->port.tty;
--> New code:
Code:
struct tty_struct *tty = up->port.info->tty;
In case you were noticing, yes, those are the same exact lines and changes. It appears that the patch places an object (port) as part of the usage of the function that is not defined as part of those functions in the context of 'tty'. Remove it and move on to building the module.
Because of this, you could alternatively just sed the change globally:
Code:
sed -i s/port\.tty/tty/g 9900.c
5) Build the module:
Code:
jones@jones-laptop:~/Desktop/starex$ sudo -s make
6) Remove all instances of 'rc.d' from the Makefile INSTALL and UNINSTALL functions (as stated above):
INSTALL
Old code:
Code:
ln -s /etc/init.d/mcs9900 /etc/rc.d/rc3.d/Smcs9900 || true
ln -s /etc/init.d/mcs9900 /etc/rc.d/rc5.d/Smcs9900 || true
New code:
Code:
ln -s /etc/init.d/mcs9900 /etc/rc3.d/Smcs9900 || true
ln -s /etc/init.d/mcs9900 /etc/rc5.d/Smcs9900 || true
UNINSTALL
Old code:
Code:
rm -f /etc/rc.d/rc3.d/Smcs9900
rm -f /etc/rc.d/rc5.d/Smcs9900
New code:
Code:
rm -f /etc/rc3.d/Smcs9900
rm -f /etc/rc5.d/Smcs9900
Same thing for this one, you can alternatively just perform an inline substitution:
Code:
sed -i 's/\/rc\.d//g' Makefile
7) Once that's done, go ahead and perform the install:
Code:
jones@jones-laptop:~/Desktop/starex$ sudo -s make install
Hope that helps someone out. Thank you guys in turn for pointing me in the right direction in the first place!
Bookmarks