Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
powerpc: Add __must_check to set_memory_...()
After the following powerpc commits, all calls to set_memory_...() functions check returned value. - Commit 8f17bd2 ("powerpc: Handle error in mark_rodata_ro() and mark_initmem_nx()") - Commit f7f18e3 ("powerpc/kprobes: Handle error returned by set_memory_rox()") - Commit 009cf11 ("powerpc: Don't ignore errors from set_memory_{n}p() in __kernel_map_pages()") - Commit 9cbacb8 ("powerpc: Don't ignore errors from set_memory_{n}p() in __kernel_map_pages()") - Commit 78cb094 ("powerpc: Handle error in mark_rodata_ro() and mark_initmem_nx()") All calls in core parts of the kernel also always check returned value, can be looked at with following query: $ git grep -w -e set_memory_ro -e set_memory_rw -e set_memory_x -e set_memory_nx -e set_memory_rox `find . -maxdepth 1 -type d | grep -v arch | grep /` It is now possible to flag those functions with __must_check to make sure no new unchecked call it added. Link: KSPP#7 Signed-off-by: Christophe Leroy <[email protected]>
- Loading branch information