When you are outside of process context (i.e., in interrupt context), you must observe the
following rules:
• No access to user space is allowed. Because there is no process context, there is
no path to the user space associated with any particular process.
不能访问任何user space的东东
• The current pointer is not meaningful in atomic mode and cannot be used since
the relevant code has no connection with the process that has been interrupted.
不能用current指针
• No sleeping or scheduling may be performed. Atomic code may not call sched-
ule or a form of wait_event, nor may it call any other function that could sleep.
For example, calling kmalloc(..., GFP_KERNEL) is against the rules. Sema-
phores also must not be used since they can sleep.
不能sleep 或者 schedule。
也不能调用任何会sleep的函数。