Linux – Error compiling custom kernel with a new usb serial driver

compilingdriverslinux-kernelusb

I have tried compile a driver for my kernel 3.13.0-40-generic. I have also tried compile a custom kernel with this driver but both have failed.

The name of the driver is vizzini for Linux 2.6.18-3.4.x. I have downloaded it from here.

The error is:

/home/usuario/Descargas/xr21v141x-lnx2.6.18-to-3.4-pak/vizzini.c:137:26: error: ‘usb_serial_probe’ undeclared here (not in a function)
         .probe         = usb_serial_probe,
                          ^
/home/usuario/Descargas/xr21v141x-lnx2.6.18-to-3.4-pak/vizzini.c: In function ‘vizzini_set_termios’:
/home/usuario/Descargas/xr21v141x-lnx2.6.18-to-3.4-pak/vizzini.c:419:29: error: invalid type argument of ‘->’ (have ‘struct ktermios’)
         cflag = tty->termios->c_cflag;
                             ^
In file included from include/linux/printk.h:236:0,
                 from include/linux/kernel.h:13,
                 from /home/usuario/Descargas/xr21v141x-lnx2.6.18-to-3.4-pak/vizzini.c:42:
/home/usuario/Descargas/xr21v141x-lnx2.6.18-to-3.4-pak/vizzini.c: In function ‘vizzini_out_callback’:
/home/usuario/Descargas/xr21v141x-lnx2.6.18-to-3.4-pak/vizzini.c:804:72: error: ‘struct usb_serial_port’ has no member named ‘number’
         if (debug) dev_dbg(&port->dev, "%s - port %d\n", __func__, port->number);
                                                                        ^

I checked in that the function is static and declared in usb-serial.c in line 697.

Can anybody help me?

Thanks and regards!.

Best Answer

I was using a driver for <3.4 kernel and I have the 3.13. I had downloaded a new driver. I saw "3.1.3"...

Related Question