Re: Problem with line discipline in new kernels

2015-08-23 Thread Valdis . Kletnieks
On Sun, 23 Aug 2015 10:14:20 +0300, Ruth Glushkin said: On Thu, 22 Aug 2015 00:21:00 -, Valdis Kletnieks said: Sounds like a reference counting problem. As far as I know, reference counter for line discipline sets to 0 in tty_register_ldisc(), Not for the discipline, for the *MODULE*.

Re: Problem with line discipline in new kernels

2015-08-23 Thread Ruth Glushkin
On Thu, 22 Aug 2015 00:21:00 -, Valdis Kletnieks said: Sounds like a reference counting problem. As far as I know, reference counter for line discipline sets to 0 in tty_register_ldisc(), increases to 1 in get_ldops() and decreases to 1 in put_ldops(). In tty_unregister_ldisc() it checks

Problem with line discipline in new kernels

2015-08-21 Thread Margarita Glushkin
I have a linux kernel driver for serial device, which uses line discipline and char device. Driver works with all old kernels, starting from 3.8 this driver still works, but when I unload it and load again to the memory (modprobe -r bpsctl_mod, after modprobe bpsctl_mod), it crashes the kernel.

Re: Problem with line discipline in new kernels

2015-08-21 Thread Valdis . Kletnieks
On Thu, 13 Aug 2015 13:00:58 -, Margarita Glushkin said: I have a linux kernel driver for serial device, which uses line discipline and char device. Driver works with all old kernels, starting from 3.8 this driver still works, but when I unload it and load again to the memory (modprobe -r