tech-kern archive

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

Re: calling soo_write() from itimer handler



On 2/21/26 22:50, Michael van Elst wrote:
soo_write() may sleep, and that's not allowed in software interrupts.
You need to run soo_write() from a kernel thread (often a work queue
is used which implies a thread).

Since the thread runs asynchronously, you have to decide what to do,
when the timer expires while the previous action hasn't finished
yet.


I understand that it should be used work queue.
Socket which is used in soo_write() is created in user mode with socketpair() and one side is passed to kernel module through ioctl and it is used for signaling event from module to user-mode app.
It transfers 20 byte of data.
Do you think that in this case it need to be sleepable too ?




Home | Main Index | Thread Index | Old Index