From patchwork Fri Sep 8 22:45:03 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ram Pai X-Patchwork-Id: 811879 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3xptr20DBCz9s75 for ; Sat, 9 Sep 2017 09:31:30 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="YxV4j28o"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 3xptr16GH3zDrSP for ; Sat, 9 Sep 2017 09:31:29 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="YxV4j28o"; dkim-atps=neutral X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gmail.com (client-ip=2607:f8b0:400d:c0d::244; helo=mail-qt0-x244.google.com; envelope-from=ram.n.pai@gmail.com; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="YxV4j28o"; dkim-atps=neutral Received: from mail-qt0-x244.google.com (mail-qt0-x244.google.com [IPv6:2607:f8b0:400d:c0d::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 3xpsrt6L3wzDrcp for ; Sat, 9 Sep 2017 08:47:10 +1000 (AEST) Received: by mail-qt0-x244.google.com with SMTP id h21so2358304qth.4 for ; Fri, 08 Sep 2017 15:47:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=EUT54Uj10IvV0ANYD4UC1vcgvR9YOvNp6lQeldh8lX8=; b=YxV4j28omCEgl1wLV/dBZH2Iu1VWH4Tgs7s40aun8dqdYlkHfxpQ6Muk3Fz3fZ464y Chce+cXSEESO1ZHD5FR+Ptc/Iy5cM6ZAybl7b+QYmL/53XZEp3r6iEKGbR9bdOZtGaW3 DYYopgFkyoJo6GQIfdJfHom1HPMymU/bOH+9rzQTXj4FTXl1s72dEwZXMOjErL/RQQV2 fodECku6Hii2nXwUaTWbgzt91I3cO3iX6txVhZkRN1gTfFt9hg2vnz67Zy1YeTRK4/6b +ag+7Xf3SYCh6ATsbshfWa5d+U3hp/sojEe7h8nHMA/3fLxw4u4qtztMUg14usjoqdsm e58w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=EUT54Uj10IvV0ANYD4UC1vcgvR9YOvNp6lQeldh8lX8=; b=aTjOZBZiFDCKpxbyArRRx3/8UhD+cnvyVyC1vVKFKn8nGcx+IvK2IzvSyWEd800YsJ ow+W/0MU0QeDZeWj4MzhR6YpJKwTe3xC3PtDQOCrvdfIUQ+Uozj52Sl1rmG0oIgqhrOZ r3QpQz0d+SOV0KdJEVxI3hMZ8Tzf0DaKDjZjENfJDwvxgQSWr/ZkDQnQjaK8XPOzsro2 BJ3Gq54CttdV622d2zJNmA4OgsfRAOFETBlQ0dz6G9JQ94uVirIAw/PgTiRY0uLSmxeS zWiG/EUaMkm0+U/CYuJ39LiTRAgIlBtdB98wJW5MlCpkySIpQAerJBWV+fgtTL5o9j7N /guw== X-Gm-Message-State: AHPjjUiyYRlaolC3ma+gXx5+z/ab4PFtutq4eIwgXf/ACsmsFMOzstzi FjnyHfkHVHmBAQ== X-Google-Smtp-Source: AOwi7QB2Prmxf6H14qOiAXLO/yW6T3EfZud31u0KDyVRUJxbzwl/FT1Wr4QKE/FLkmacAkhOP8GG3Q== X-Received: by 10.200.49.170 with SMTP id h39mr6155821qte.162.1504910828029; Fri, 08 Sep 2017 15:47:08 -0700 (PDT) Received: from localhost.localdomain (50-39-103-96.bvtn.or.frontiernet.net. [50.39.103.96]) by smtp.gmail.com with ESMTPSA id x124sm2033726qka.85.2017.09.08.15.47.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 08 Sep 2017 15:47:07 -0700 (PDT) From: Ram Pai To: mpe@ellerman.id.au, linuxppc-dev@lists.ozlabs.org Subject: [PATCH 15/25] powerpc: sys_pkey_mprotect() system call Date: Fri, 8 Sep 2017 15:45:03 -0700 Message-Id: <1504910713-7094-24-git-send-email-linuxram@us.ibm.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1504910713-7094-1-git-send-email-linuxram@us.ibm.com> References: <1504910713-7094-1-git-send-email-linuxram@us.ibm.com> X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: ebiederm@xmission.com, linuxram@us.ibm.com, mhocko@kernel.org, paulus@samba.org, aneesh.kumar@linux.vnet.ibm.com, bauerman@linux.vnet.ibm.com, khandual@linux.vnet.ibm.com Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Patch provides the ability for a process to associate a pkey with a address range. Signed-off-by: Ram Pai --- arch/powerpc/include/asm/systbl.h | 1 + arch/powerpc/include/asm/unistd.h | 4 +--- arch/powerpc/include/uapi/asm/unistd.h | 1 + 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/include/asm/systbl.h b/arch/powerpc/include/asm/systbl.h index 22dd776..b33b551 100644 --- a/arch/powerpc/include/asm/systbl.h +++ b/arch/powerpc/include/asm/systbl.h @@ -390,3 +390,4 @@ SYSCALL(statx) SYSCALL(pkey_alloc) SYSCALL(pkey_free) +SYSCALL(pkey_mprotect) diff --git a/arch/powerpc/include/asm/unistd.h b/arch/powerpc/include/asm/unistd.h index e0273bc..daf1ba9 100644 --- a/arch/powerpc/include/asm/unistd.h +++ b/arch/powerpc/include/asm/unistd.h @@ -12,12 +12,10 @@ #include -#define NR_syscalls 386 +#define NR_syscalls 387 #define __NR__exit __NR_exit -#define __IGNORE_pkey_mprotect - #ifndef __ASSEMBLY__ #include diff --git a/arch/powerpc/include/uapi/asm/unistd.h b/arch/powerpc/include/uapi/asm/unistd.h index 7993a07..71ae45e 100644 --- a/arch/powerpc/include/uapi/asm/unistd.h +++ b/arch/powerpc/include/uapi/asm/unistd.h @@ -396,5 +396,6 @@ #define __NR_statx 383 #define __NR_pkey_alloc 384 #define __NR_pkey_free 385 +#define __NR_pkey_mprotect 386 #endif /* _UAPI_ASM_POWERPC_UNISTD_H_ */