Skip to content
  • Federico Vaga's avatar
    trigger: always use GFP_ATOMIC on allocation · f5a34778
    Federico Vaga authored
    
    
    in_atomic() function should not be used inside a driver, and it does not
    guarantee atomic context detection. Following the comment from the
    kernel source
    
    /*
     * Are we running in atomic context?  WARNING: this macro cannot
     * always detect atomic context; in particular, it cannot know about
     * held spinlocks in non-preemptible kernels.  Thus it should not be
     * used in the general case to determine whether sleeping is possible.
     * Do not use in_atomic() in driver code.
     */
    
    Signed-off-by: default avatarFederico Vaga <federico.vaga@cern.ch>
    f5a34778