From 8ac6c7a54ed1b98d142dce24b11c6de6a1e239a5 Mon Sep 17 00:00:00 2001 From: hc <hc@nodka.com> Date: Tue, 22 Oct 2024 10:36:11 +0000 Subject: [PATCH] 修改4g拨号为QMI,需要在系统里后台执行quectel-CM --- kernel/arch/alpha/include/asm/futex.h | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-) diff --git a/kernel/arch/alpha/include/asm/futex.h b/kernel/arch/alpha/include/asm/futex.h index ca33225..da67afd 100644 --- a/kernel/arch/alpha/include/asm/futex.h +++ b/kernel/arch/alpha/include/asm/futex.h @@ -31,7 +31,8 @@ { int oldval = 0, ret; - pagefault_disable(); + if (!access_ok(uaddr, sizeof(u32))) + return -EFAULT; switch (op) { case FUTEX_OP_SET: @@ -53,8 +54,6 @@ ret = -ENOSYS; } - pagefault_enable(); - if (!ret) *oval = oldval; @@ -68,7 +67,7 @@ int ret = 0, cmp; u32 prev; - if (!access_ok(VERIFY_WRITE, uaddr, sizeof(u32))) + if (!access_ok(uaddr, sizeof(u32))) return -EFAULT; __asm__ __volatile__ ( -- Gitblit v1.6.2