Re: [PATCH 03/18] tty: Simplify tty buffer/ldisc interface with helper function

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

 



>> I have little question about flush_to_ldisc().
>> Does can it be multithreaded?
>>
>> I think yes, because on SMP schedule_work() can work on different CPU paralleled.
> 
> Yes, the same work item can now run in parallel on SMP since Tejun Heo
> re-did the workqueue implementation on 2.6.36 [Stefan Richter, the
> firewire maintainer, recently explained this history to me].

About multi threaded delayed works:

In many cases tty layer needs single threaded delayed work for each tty instance.
I propose discussion about create for this purpose (tty layer)'s workqueue with WQ_NON_REENTRANT flag.
And use it instead common schedule_work()'s workqueue - system_wq.
I don't know how expensive(for system resource and CPU) it can be,
but for tty layer, it can be very useful.

> 
>> What do you think about this race condition?
>> https://lkml.org/lkml/2011/11/7/98
> 
> Yes, that is a possible race condition that could lead to some nasty
> results. Good find.
> 
> If you want, I could bring that patch into this patchset or you could
> re-submit that patch to Greg and I could rebase this patchset on top of
> that.

Peter,
Please, do it anywhere you consider possible,
I can't do it myself now.

Thank you,
Ilya.

--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[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