Merge pull request #306 from EricccTaiwan/fix

Clarify tasklet limitations and deprecation plans
This commit is contained in:
Jim Huang 2025-04-18 09:42:46 +08:00 committed by GitHub
commit 26988ef5de
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1279,7 +1279,7 @@ If you want more information, you can read this web page:
\item \url{https://kernelnewbies.org/Documents/SeqFileHowTo}
\end{itemize}
You can also read the code of \src{fs/seq\_file.c} in the linux kernel.
You can also read the code of \src{fs/seq\_file.c} in the Linux kernel.
\section{sysfs: Interacting with your module}
\label{sec:sysfs}
@ -1921,7 +1921,7 @@ Example tasklet starts
Example tasklet init continues...
Example tasklet ends
\end{verbatim}
Although tasklet is easy to use, it comes with several drawbacks, and developers are discussing about getting rid of tasklet in linux kernel.
Although tasklet is easy to use, it comes with several drawbacks, and developers have been discussing their removal from the Linux kernel.
The tasklet callback runs in atomic context, inside a software interrupt, meaning that it cannot sleep or access user-space data, so not all work can be done in a tasklet handler.
Also, the kernel only allows one instance of any given tasklet to be running at any given time; multiple different tasklet callbacks can run in parallel.