• Jan Kara's avatar
    fanotify: Avoid lost events due to ENOMEM for unlimited queues · 1f5eaa90
    Jan Kara authored
    Fanotify queues of unlimited length do not expect events can be lost.
    Since these queues are used for system auditing and other security
    related tasks, loosing events can even have security implications.
    Currently, since the allocation is small (32-bytes), it cannot fail
    however when we start accounting events in memcgs, allocation can start
    failing. So avoid loosing events due to failure to allocate memory by
    making event allocation use __GFP_NOFAIL.
    Reviewed-by: default avatarAmir Goldstein <amir73il@gmail.com>
    Signed-off-by: default avatarJan Kara <jack@suse.cz>
    1f5eaa90
fanotify.h 1.7 KB