Messages in this thread Patch in this message | | | From | mohammed0x00 <> | Subject | [PATCH] ipc: Using unlikely macro is more efficient. | Date | Sun, 17 Sep 2023 20:12:41 +0300 |
| |
Signed-off-by: Mohammed Mansour <mmansour.mm5@gmail.com> --- ipc/shm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ipc/shm.c b/ipc/shm.c index 576a543b7..8ce67ae16 100644 --- a/ipc/shm.c +++ b/ipc/shm.c @@ -734,7 +734,7 @@ static int newseg(struct ipc_namespace *ns, struct ipc_params *params) shp->shm_perm.security = NULL; error = security_shm_alloc(&shp->shm_perm); - if (error) { + if (unlikely(error)) { kfree(shp); return error; } -- 2.34.1
| |