euleros inclusion category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I7WLVX
---------------------------------------------
The handlers for GMEM_PAGE_FAULT_REQUEST and GMEM_EVICT_PAGE_REQUEST are not set if CONFIG_REMOTE_PAGER_MASTER=m
Signed-off-by: Chen Jun chenjun102@huawei.com --- drivers/remote_pager/main.c | 4 ++-- drivers/remote_pager/msg_handler_comm.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/remote_pager/main.c b/drivers/remote_pager/main.c index 66f303ce61c9..b7c8d8440bfa 100644 --- a/drivers/remote_pager/main.c +++ b/drivers/remote_pager/main.c @@ -10,7 +10,7 @@ #include "msg_chan/msg_layer/msg_layer.h" #include "msg_handler.h"
-#ifdef CONFIG_REMOTE_PAGER_SLAVE +#if IS_ENABLED(CONFIG_REMOTE_PAGER_SLAVE) #include "swap/device/swap_manager.h" #endif
@@ -18,7 +18,7 @@ static int __init remote_pager_init(void) { msg_handle_init();
-#ifdef CONFIG_REMOTE_PAGER_SLAVE +#if IS_ENABLED(CONFIG_REMOTE_PAGER_SLAVE) init_swap_manager("list_lru"); #endif return 0; diff --git a/drivers/remote_pager/msg_handler_comm.c b/drivers/remote_pager/msg_handler_comm.c index 129a4247305f..f195ad15e646 100644 --- a/drivers/remote_pager/msg_handler_comm.c +++ b/drivers/remote_pager/msg_handler_comm.c @@ -17,7 +17,7 @@ static struct workqueue_struct *remote_pager_wq;
struct msg_handler_st rpg_kmsg_cbftns[GMEM_MSG_MAX_ID] = { -#ifdef CONFIG_REMOTE_PAGER_SLAVE +#if IS_ENABLED(CONFIG_REMOTE_PAGER_SLAVE) /* HOST TO REMOTE */ [GMEM_TASK_PAIRING_REQUEST] = { gmem_handle_task_pairing @@ -42,7 +42,7 @@ struct msg_handler_st rpg_kmsg_cbftns[GMEM_MSG_MAX_ID] = { }, #endif
-#ifdef CONFIG_REMOTE_PAGER_MASTER +#if IS_ENABLED(CONFIG_REMOTE_PAGER_MASTER) /* REMOTE TO HOST */ [GMEM_PAGE_FAULT_REQUEST] = { gmem_handle_dev_fault