Message ID | 90e6851e1c71696f03cfa2c71377f0542d8dbd8d.1580365432.git.sandipan@linux.ibm.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <SRS0=SaG1=3T=kvack.org=owner-linux-mm@kernel.org> Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D7AE314B4 for <patchwork-linux-mm@patchwork.kernel.org>; Thu, 30 Jan 2020 06:37:47 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A533F2082E for <patchwork-linux-mm@patchwork.kernel.org>; Thu, 30 Jan 2020 06:37:47 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A533F2082E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.ibm.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 96E956B02F4; Thu, 30 Jan 2020 01:37:44 -0500 (EST) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 920266B02F5; Thu, 30 Jan 2020 01:37:44 -0500 (EST) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 80CDC6B02F6; Thu, 30 Jan 2020 01:37:44 -0500 (EST) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0247.hostedemail.com [216.40.44.247]) by kanga.kvack.org (Postfix) with ESMTP id 68A846B02F4 for <linux-mm@kvack.org>; Thu, 30 Jan 2020 01:37:44 -0500 (EST) Received: from smtpin22.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 39EBD824934B for <linux-mm@kvack.org>; Thu, 30 Jan 2020 06:37:44 +0000 (UTC) X-FDA: 76433344848.22.cord88_2660732f2362c X-Spam-Summary: 2,0,0,ec64031cd43848af,d41d8cd98f00b204,sandipan@linux.ibm.com,:shuah@kernel.org:skhan@linuxfoundation.org:linux-kselftest@vger.kernel.org:linux-arch@vger.kernel.org:linuxppc-dev@lists.ozlabs.org:x86@kernel.org::fweimer@redhat.com:dave.hansen@intel.com:linuxram@us.ibm.com:mhocko@kernel.org:mingo@redhat.com:aneesh.kumar@linux.ibm.com:bauerman@linux.ibm.com:msuchanek@suse.de:mpe@ellerman.id.au,RULES_HIT:41:355:379:541:800:960:973:988:989:1260:1261:1345:1359:1437:1535:1541:1711:1730:1747:1777:1792:2393:2559:2562:2693:3138:3139:3140:3141:3142:3352:3865:3866:3867:3868:3870:3871:3872:3874:5007:6261:6742:7576:10004:11026:11473:11657:11658:11914:12043:12114:12297:12555:12679:12895:13069:13311:13357:13972:14181:14384:14394:14721:21080:21451:21617:21990:30045:30054:30056:30064:30070,0,RBL:148.163.158.5:@linux.ibm.com:.lbl8.mailshell.net-62.2.0.100 64.100.201.201,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fp,MSBL:0,DNSBL:none,Custom_ru les:0:0: X-HE-Tag: cord88_2660732f2362c X-Filterd-Recvd-Size: 5356 Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by imf41.hostedemail.com (Postfix) with ESMTP for <linux-mm@kvack.org>; Thu, 30 Jan 2020 06:37:43 +0000 (UTC) Received: from pps.filterd (m0098413.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 00U6ahpR085257 for <linux-mm@kvack.org>; Thu, 30 Jan 2020 01:37:43 -0500 Received: from e06smtp04.uk.ibm.com (e06smtp04.uk.ibm.com [195.75.94.100]) by mx0b-001b2d01.pphosted.com with ESMTP id 2xtmmy1k3h-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for <linux-mm@kvack.org>; Thu, 30 Jan 2020 01:37:42 -0500 Received: from localhost by e06smtp04.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for <linux-mm@kvack.org> from <sandipan@linux.ibm.com>; Thu, 30 Jan 2020 06:37:41 -0000 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) by e06smtp04.uk.ibm.com (192.168.101.134) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 30 Jan 2020 06:37:36 -0000 Received: from d06av22.portsmouth.uk.ibm.com (d06av22.portsmouth.uk.ibm.com [9.149.105.58]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 00U6bZ4c26476672 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 30 Jan 2020 06:37:35 GMT Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 1AA7F4C046; Thu, 30 Jan 2020 06:37:35 +0000 (GMT) Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 8DC844C04A; Thu, 30 Jan 2020 06:37:32 +0000 (GMT) Received: from fir03.in.ibm.com (unknown [9.121.59.65]) by d06av22.portsmouth.uk.ibm.com (Postfix) with ESMTP; Thu, 30 Jan 2020 06:37:32 +0000 (GMT) From: Sandipan Das <sandipan@linux.ibm.com> To: shuah@kernel.org, skhan@linuxfoundation.org, linux-kselftest@vger.kernel.org Cc: linux-arch@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, x86@kernel.org, linux-mm@kvack.org, fweimer@redhat.com, dave.hansen@intel.com, linuxram@us.ibm.com, mhocko@kernel.org, mingo@redhat.com, aneesh.kumar@linux.ibm.com, bauerman@linux.ibm.com, msuchanek@suse.de, mpe@ellerman.id.au Subject: [PATCH v18 09/24] selftests/vm/pkeys: Fix assertion in pkey_disable_set/clear() Date: Thu, 30 Jan 2020 12:06:51 +0530 X-Mailer: git-send-email 2.17.1 In-Reply-To: <cover.1580365432.git.sandipan@linux.ibm.com> References: <cover.1580365432.git.sandipan@linux.ibm.com> In-Reply-To: <cover.1580365432.git.sandipan@linux.ibm.com> References: <cover.1580365432.git.sandipan@linux.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 20013006-0016-0000-0000-000002E1F2E6 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 20013006-0017-0000-0000-00003344BBBF Message-Id: <90e6851e1c71696f03cfa2c71377f0542d8dbd8d.1580365432.git.sandipan@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.138,18.0.572 definitions=2020-01-30_01:2020-01-28,2020-01-30 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=608 impostorscore=0 phishscore=0 malwarescore=0 lowpriorityscore=0 clxscore=1015 bulkscore=0 mlxscore=0 adultscore=0 spamscore=0 priorityscore=1501 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-1911200001 definitions=main-2001300042 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> |
Series |
selftests, powerpc, x86: Memory Protection Keys
|
expand
|
diff --git a/tools/testing/selftests/vm/protection_keys.c b/tools/testing/selftests/vm/protection_keys.c index 4b1ddb526228..7fd52d5c4bfd 100644 --- a/tools/testing/selftests/vm/protection_keys.c +++ b/tools/testing/selftests/vm/protection_keys.c @@ -400,7 +400,7 @@ void pkey_disable_set(int pkey, int flags) dprintf1("%s(%d) pkey_reg: 0x%016llx\n", __func__, pkey, read_pkey_reg()); if (flags) - pkey_assert(read_pkey_reg() > orig_pkey_reg); + pkey_assert(read_pkey_reg() >= orig_pkey_reg); dprintf1("END<---%s(%d, 0x%x)\n", __func__, pkey, flags); } @@ -431,7 +431,7 @@ void pkey_disable_clear(int pkey, int flags) dprintf1("%s(%d) pkey_reg: 0x%016llx\n", __func__, pkey, read_pkey_reg()); if (flags) - assert(read_pkey_reg() < orig_pkey_reg); + assert(read_pkey_reg() <= orig_pkey_reg); } void pkey_write_allow(int pkey)