kernel: Rearrange and eliminate potential call delays

This commit is contained in:
ShirkNeko
2025-10-06 00:08:57 +08:00
parent 5779892bbc
commit 8489c442c9
2 changed files with 58 additions and 43 deletions

View File

@@ -7,6 +7,14 @@
#include "ss/policydb.h"
#include "linux/key.h"
#if defined(CONFIG_ARM) || defined(CONFIG_ARM64)
// arch/arm64/include/asm/barrier.h, adding dsb probably unneeded
#define DONT_GET_SMART() do { barrier(); isb(); } while (0)
#else
// well, compiler atleast, and not our targets
#define DONT_GET_SMART() barrier()
#endif
/**
* list_count_nodes - count the number of nodes in a list
* @head: the head of the list