Jump to content
Форум по продукции MOXA

Прошу помочь со сборкой Linux драйвера для NPort 5150


Recommended Posts

Добрый день. Ubuntu Desktop 14.04. NPort 5150 драйвер не компилируется.

 

 

 

===============================================================================
Copyright © 2002-2012 Moxa Inc.
All Rights Reserved.

MOXA NPort Server Real TTY Driver V1.18 Installation.
System Imformation: Kernel 3.19.0-25-generic; Machine x86_64.
===============================================================================


Tar files, please wait ... OK!
Building driver...

If you want to use secure communication with target,
you might choose [y] to enable the SSL function.
Note: This function support RealCOM with secure mode only.
Do you want to enable secure function? [y/N].
n
make -C /lib/modules/3.19.0-25-generic/build SUBDIRS=/tmp/tmp/moxa modules
make[1]: Entering directory `/usr/src/linux-headers-3.19.0-25-generic'
CC [M] /tmp/tmp/moxa/npreal2.o
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_init_tty’:
/tmp/tmp/moxa/npreal2.c:661:11: error: dereferencing pointer to incomplete type
de->data = (void *) net_node;
^
/tmp/tmp/moxa/npreal2.c:663:11: error: dereferencing pointer to incomplete type
de->proc_fops = &npreal_net_fops;
^
In file included from /tmp/tmp/moxa/npreal2.c:92:0:
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_init’:
/tmp/tmp/moxa/npreal2.h:28:35: error: ‘struct tty_driver’ has no member named ‘termios_locked’
#define DRV_VAR_P(x) npvar_sdriver->x
^
/tmp/tmp/moxa/npreal2.c:779:5: note: in expansion of macro ‘DRV_VAR_P’
DRV_VAR_P(termios_locked) = npvar_termios_locked;
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_open’:
/tmp/tmp/moxa/npreal2.c:1064:13: error: invalid type argument of unary ‘*’ (have ‘struct ktermios’)
*tty->termios = info->normal_termios;
^
/tmp/tmp/moxa/npreal2.c:1066:13: error: invalid type argument of unary ‘*’ (have ‘struct ktermios’)
*tty->termios = info->callout_termios;
^
/tmp/tmp/moxa/npreal2.c:1080:8: error: ‘struct tty_struct’ has no member named ‘low_latency’
tty->low_latency = 1;
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_close’:
/tmp/tmp/moxa/npreal2.c:1170:32: error: invalid type argument of unary ‘*’ (have ‘struct ktermios’)
info->normal_termios = *tty->termios;
^
/tmp/tmp/moxa/npreal2.c:1172:33: error: invalid type argument of unary ‘*’ (have ‘struct ktermios’)
info->callout_termios = *tty->termios;
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_ioctl’:
/tmp/tmp/moxa/npreal2.c:1612:21: error: invalid type argument of ‘->’ (have ‘struct ktermios’)
tty->termios->c_cflag = ((tty->termios->c_cflag & ~CLOCAL) |
^
/tmp/tmp/moxa/npreal2.c:1612:47: error: invalid type argument of ‘->’ (have ‘struct ktermios’)
tty->termios->c_cflag = ((tty->termios->c_cflag & ~CLOCAL) |
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_block_til_ready’:
/tmp/tmp/moxa/npreal2.c:1962:26: error: invalid type argument of ‘->’ (have ‘struct ktermios’)
if ( tty->termios->c_cflag & CLOCAL )
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_startup’:
/tmp/tmp/moxa/npreal2.c:2155:27: error: invalid type argument of ‘->’ (have ‘struct ktermios’)
if (info->tty->termios->c_cflag & CBAUD)
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_shutdown’:
/tmp/tmp/moxa/npreal2.c:2278:42: error: invalid type argument of ‘->’ (have ‘struct ktermios’)
if (!info->tty || (info->tty->termios->c_cflag & HUPCL))
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_port_init’:
/tmp/tmp/moxa/npreal2.c:2325:18: error: incompatible types when assigning to type ‘struct ktermios *’ from type ‘struct ktermios’
if (!(termio = info->tty->termios))
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_port_shutdown’:
/tmp/tmp/moxa/npreal2.c:2700:18: error: incompatible types when assigning to type ‘struct ktermios *’ from type ‘struct ktermios’
if (!(termio = info->tty->termios))
^
/tmp/tmp/moxa/npreal2.c: In function ‘tty_buffer_free’:
/tmp/tmp/moxa/npreal2.c:3352:9: error: implicit declaration of function ‘kfree’ [-Werror=implicit-function-declaration]
kfree(B);
^
/tmp/tmp/moxa/npreal2.c:3355:22: error: ‘struct tty_struct’ has no member named ‘buf’
b->next = tty->buf.free;
^
/tmp/tmp/moxa/npreal2.c:3356:12: error: ‘struct tty_struct’ has no member named ‘buf’
tty->buf.free = b;
^
In file included from include/linux/seqlock.h:35:0,
from include/linux/time.h:5,
from include/linux/stat.h:18,
from include/linux/module.h:10,
from /tmp/tmp/moxa/npreal2.c:42:
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_flush_to_ldisc’:
/tmp/tmp/moxa/npreal2.c:3424:31: error: ‘struct tty_struct’ has no member named ‘buf’
spin_lock_irqsave(&tty->buf.lock, flags);
^
include/linux/spinlock.h:215:34: note: in definition of macro ‘raw_spin_lock_irqsave’
flags = _raw_spin_lock_irqsave(lock); \
^
/tmp/tmp/moxa/npreal2.c:3424:9: note: in expansion of macro ‘spin_lock_irqsave’
spin_lock_irqsave(&tty->buf.lock, flags);
^
/tmp/tmp/moxa/npreal2.c:3425:19: error: ‘struct tty_struct’ has no member named ‘buf’
head = tty->buf.head;
^
/tmp/tmp/moxa/npreal2.c:3428:16: error: ‘struct tty_struct’ has no member named ‘buf’
tty->buf.head = NULL;
^
/tmp/tmp/moxa/npreal2.c:3452:26: error: ‘struct tty_buffer’ has no member named ‘char_buf_ptr’
cp = head->char_buf_ptr + head->read;
^
/tmp/tmp/moxa/npreal2.c:3453:26: error: ‘struct tty_buffer’ has no member named ‘flag_buf_ptr’
fp = head->flag_buf_ptr + head->read;
^
/tmp/tmp/moxa/npreal2.c:3455:44: error: ‘struct tty_struct’ has no member named ‘buf’
spin_unlock_irqrestore(&tty->buf.lock, flags);
^
In file included from include/linux/seqlock.h:35:0,
from include/linux/time.h:5,
from include/linux/stat.h:18,
from include/linux/module.h:10,
from /tmp/tmp/moxa/npreal2.c:42:
/tmp/tmp/moxa/npreal2.c:3461:39: error: ‘struct tty_struct’ has no member named ‘buf’
spin_lock_irqsave(&tty->buf.lock, flags);
^
include/linux/spinlock.h:215:34: note: in definition of macro ‘raw_spin_lock_irqsave’
flags = _raw_spin_lock_irqsave(lock); \
^
/tmp/tmp/moxa/npreal2.c:3461:17: note: in expansion of macro ‘spin_lock_irqsave’
spin_lock_irqsave(&tty->buf.lock, flags);
^
/tmp/tmp/moxa/npreal2.c:3463:16: error: ‘struct tty_struct’ has no member named ‘buf’
tty->buf.head = head;
^
/tmp/tmp/moxa/npreal2.c:3465:36: error: ‘struct tty_struct’ has no member named ‘buf’
spin_unlock_irqrestore(&tty->buf.lock, flags);
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_create_proc_entry’:
/tmp/tmp/moxa/npreal2.c:3546:5: error: implicit declaration of function ‘create_proc_entry’ [-Werror=implicit-function-declaration]
return( create_proc_entry( name, mode, parent ) );
^
/tmp/tmp/moxa/npreal2.c:3546:5: warning: return makes pointer from integer without a cast [enabled by default]
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_remove_proc_entry’:
/tmp/tmp/moxa/npreal2.c:3554:26: error: dereferencing pointer to incomplete type
remove_proc_entry(pde->name, pde->parent);
^
/tmp/tmp/moxa/npreal2.c:3554:37: error: dereferencing pointer to incomplete type
remove_proc_entry(pde->name, pde->parent);
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_net_open’:
/tmp/tmp/moxa/npreal2.c:3606:5: error: implicit declaration of function ‘PDE’ [-Werror=implicit-function-declaration]
de = PDE(inode);
^
/tmp/tmp/moxa/npreal2.c:3606:8: warning: assignment makes pointer from integer without a cast [enabled by default]
de = PDE(inode);
^
/tmp/tmp/moxa/npreal2.c:3615:32: error: dereferencing pointer to incomplete type
nd = (struct nd_struct *)de->data;
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_net_write’:
/tmp/tmp/moxa/npreal2.c:4255:18: error: ‘struct tty_struct’ has no member named ‘low_latency’
if(!info->tty->low_latency)
^
/tmp/tmp/moxa/npreal2.c:4283:5: warning: passing argument 1 of ‘tty_buffer_request_room’ from incompatible pointer type [enabled by default]
if ((cnt = tty_buffer_request_room(tty, count)) <= 0)
^
In file included from /tmp/tmp/moxa/npreal2.c:57:0:
include/linux/tty_flip.h:6:12: note: expected ‘struct tty_port *’ but argument is of type ‘struct tty_struct *’
extern int tty_buffer_request_room(struct tty_port *port, size_t size);
^
/tmp/tmp/moxa/npreal2.c:4296:17: error: ‘struct tty_struct’ has no member named ‘icanon’
if (!tty->icanon || tty->canon_data)
^
/tmp/tmp/moxa/npreal2.c:4296:32: error: ‘struct tty_struct’ has no member named ‘canon_data’
if (!tty->icanon || tty->canon_data)
^
/tmp/tmp/moxa/npreal2.c:4311:13: error: ‘struct tty_struct’ has no member named ‘icanon’
if (!tty->icanon || tty->canon_data)
^
/tmp/tmp/moxa/npreal2.c:4311:28: error: ‘struct tty_struct’ has no member named ‘canon_data’
if (!tty->icanon || tty->canon_data)
^
/tmp/tmp/moxa/npreal2.c:4313:52: error: ‘struct tty_struct’ has no member named ‘read_cnt’
if ((cnt = MIN(cnt,(N_TTY_BUF_SIZE-1) - tty->read_cnt )) <= 0)
^
/tmp/tmp/moxa/npreal2.c:117:26: note: in definition of macro ‘MIN’
#define MIN(a,B) ((a) < (B) ? (a) : (B))
^
/tmp/tmp/moxa/npreal2.c:4313:52: error: ‘struct tty_struct’ has no member named ‘read_cnt’
if ((cnt = MIN(cnt,(N_TTY_BUF_SIZE-1) - tty->read_cnt )) <= 0)
^
/tmp/tmp/moxa/npreal2.c:117:38: note: in definition of macro ‘MIN’
#define MIN(a,B) ((a) < (B) ? (a) : (B))
^
/tmp/tmp/moxa/npreal2.c:4347:5: warning: passing argument 1 of ‘tty_insert_flip_string’ from incompatible pointer type [enabled by default]
if ((count = tty_insert_flip_string(tty, (unsigned char *)buf, cnt)))
^
In file included from /tmp/tmp/moxa/npreal2.c:57:0:
include/linux/tty_flip.h:32:19: note: expected ‘struct tty_port *’ but argument is of type ‘struct tty_struct *’
static inline int tty_insert_flip_string(struct tty_port *port,
^
/tmp/tmp/moxa/npreal2.c:4349:9: warning: passing argument 1 of ‘tty_flip_buffer_push’ from incompatible pointer type [enabled by default]
tty_flip_buffer_push(tty);
^
In file included from /tmp/tmp/moxa/npreal2.c:57:0:
include/linux/tty_flip.h:13:13: note: expected ‘struct tty_port *’ but argument is of type ‘struct tty_struct *’
extern void tty_flip_buffer_push(struct tty_port *port);
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_wait_command_completed’:
/tmp/tmp/moxa/npreal2.c:4462:13: error: implicit declaration of function ‘interruptible_sleep_on_timeout’ [-Werror=implicit-function-declaration]
interruptible_sleep_on_timeout(&nd->cmd_rsp_wait,timeout);
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_process_notify’:
/tmp/tmp/moxa/npreal2.c:4516:16: error: ‘struct tty_struct’ has no member named ‘low_latency’
if(!tty->low_latency)
^
/tmp/tmp/moxa/npreal2.c:4522:9: warning: passing argument 1 of ‘tty_insert_flip_char’ from incompatible pointer type [enabled by default]
tty_insert_flip_char(tty, 0, TTY_BREAK);
^
In file included from /tmp/tmp/moxa/npreal2.c:57:0:
include/linux/tty_flip.h:16:19: note: expected ‘struct tty_port *’ but argument is of type ‘struct tty_struct *’
static inline int tty_insert_flip_char(struct tty_port *port,
^
/tmp/tmp/moxa/npreal2.c: In function ‘npreal_do_session_recovery’:
/tmp/tmp/moxa/npreal2.c:4571:22: error: incompatible types when assigning to type ‘struct ktermios *’ from type ‘struct ktermios’
if (!(termio = info->tty->termios))
^
cc1: some warnings being treated as errors
make[2]: *** [/tmp/tmp/moxa/npreal2.o] Error 1
make[1]: *** [_module_/tmp/tmp/moxa] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.19.0-25-generic'
make: *** [module] Error 2
Check Driver...
FAILED !!!

Install Not Completed !

 

Link to comment
  • 2 months later...
  • Replies 54
  • Created
  • Last Reply

Top Posters In This Topic

  • 7 months later...

Здравствуйте.

подскажите, а как сделать чтобы каждый раз после загрузки системы не приходилось запускать:

/mxloadsvr module,

а сервер загружался автоматически по уже прописанной конфигурации

 
Link to comment
  • 5 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...