Re: [PATCH v4 1/3] tty: rename tty_kopen() and add new function tty_kopen_shared()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Dec 17, 2019 at 09:19:38PM +0100, Jacek Anaszewski wrote:
> On 12/17/19 7:27 PM, Uwe Kleine-König wrote:
> > Hello Jacek,
> > 
> > On Tue, Dec 17, 2019 at 07:08:47PM +0100, Jacek Anaszewski wrote:
> >> I wanted to test the set but unfortunately this
> >> patch does not apply. See below for the apparent reason.
> >>
> >>> [...]
> >>> -struct tty_struct *tty_kopen(dev_t device)
> >>> +static struct tty_struct *tty_kopen(dev_t device, int shared)
> >>>  {
> >>>  	struct tty_struct *tty;
> >>>  	struct tty_driver *driver;
> >>
> >> In mainline, even in v5.5-rc2 we have here NULL assignment:
> >>
> >> struct tty_driver *driver = NULL;
> > 
> > Yeah, if you don't want to wait for Greg's tree to appear in next, this
> > is the patch you're missing:
> > 
> > 	https://lkml.org/lkml/2019/12/17/101
> 
> Thanks for the pointer.
> 
> And regarding the trigger - I've tried below use case
> on my desktop Debian:
> 
> Ctrl+Alt+F3 to change the console
> 
> Then logged in and executed tty command:
> 
> $ tty
> $ /dev/tty3
> 
> $ cd /sys/class/leds/input5\:\:capslock
> note: this is LED on my USB keyboard and it works correct
> with e.g. timer trigger
> 
> /sys/class/leds/input5::capslock$ echo tty > trigger
> 
> $ cat /sys/class/tty/tty3/dev > dev
> 
> Type some characters.
> 
> LED does not blink.
> 
> $ echo "aaa" > /dev/tty3
> $ aaa
> 
> LED also does not blink.
> 
> I assume this is correct test case for tty trigger?

Try it on a real serial port, tty3 is a virtual one and I do not think
the "transmit/receive" statistics are every updated on a virtual one as
it does not make any sense to do so.

thanks,

greg k-h



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux