Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp1218479ybg; Fri, 18 Oct 2019 14:02:03 -0700 (PDT) X-Google-Smtp-Source: APXvYqwpbm0sJbb9tBBAcJzltzHHqeWCfEwDIfDYVqiTnVM40jN2wBYFCpZlT+gLWz27y7Xs2VTa X-Received: by 2002:a50:fa94:: with SMTP id w20mr12107947edr.47.1571432523570; Fri, 18 Oct 2019 14:02:03 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1571432523; cv=pass; d=google.com; s=arc-20160816; b=MVN5YiNVhtKgGmFoIBa5kib3+3rj5L2KeCL90TBa3Hey3t4mkTgRsl3DNaRc1Sc0tM 2rYIjqT0EkEoTe4vroitQSzGKuDceD+DNZhV0TbjVWZHVB7KqTheLamOccmCWgCr+HoY fZHl5FLsgmlS0M9Nx31+qvsGYIw7RMUxjfe28JqSGgIyJ0M6UBlhnHhwK6zYsYqg/uSf 2Yo4dOlD3wyGFhGtbI9/JCWbtXq5zl3O7aArUKLHL2cr4SwyjcMFgyf6OahyxLZhH+i3 xsWSqQsQHAhWaURx2GJANWD2PhWcGbs0RLOGawgh4hDqeTrPEvZFHx4gECoJNwgx8UcE Pwxw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-id:content-language:accept-language:in-reply-to:references :message-id:date:thread-index:thread-topic:subject:cc:to:from :dkim-signature; bh=/IOvRIRGh3Bl9lOTZKpGMLh5eFo5cLcEhWhin3LkuYs=; b=0vbA67L+4HIZmbcVDDUJ7BzVwY5jT1lRha8FgaiRjLSa8moanuFraUlTgE0OjOVBou PZBAef9daBbCoA8avFo50rq0v/ikAmoIqJn6UAlreB3vVxsXUFJA8L5fvditjur3BLU4 UnyxxPPdjwDNteLwQcF7dGMYVNaNkrMfmP1iGt25t9fSupF23IjKYJ0NIF2ykJdgpbeJ b9w86Bp6lwvk5mKWbQJh7OstDHfCdtuQKBKsUl+xroksSBvMRDpl0z6w5aVNbpa3SdOe mtWeBUQt5Ibc3gD1djbfMcPr4MuMTNmx0tZ0FUjYYIpdttGEqSgABwalxc+v9eC5Fpjb MR0w== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vmware.com header.s=selector2 header.b=O8UQs3OC; arc=pass (i=1 spf=pass spfdomain=vmware.com dkim=pass dkdomain=vmware.com dmarc=pass fromdomain=vmware.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=vmware.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v5si5214619ede.126.2019.10.18.14.01.40; Fri, 18 Oct 2019 14:02:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@vmware.com header.s=selector2 header.b=O8UQs3OC; arc=pass (i=1 spf=pass spfdomain=vmware.com dkim=pass dkdomain=vmware.com dmarc=pass fromdomain=vmware.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=vmware.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2406445AbfJQQ3C (ORCPT + 99 others); Thu, 17 Oct 2019 12:29:02 -0400 Received: from mail-eopbgr810081.outbound.protection.outlook.com ([40.107.81.81]:28000 "EHLO NAM01-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2392968AbfJQQ3C (ORCPT ); Thu, 17 Oct 2019 12:29:02 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WiDZgM+jZUQzqe3p1ykxmkdNHwobsLyO/PMKNskJO9t8ZjA7nonCFkATtoVMJk2hhbhHeLOAP9aKNqojt1GSwGs5DTarcXjPKdbUxgOKBARNBMXminYTnxQxs+faMZ8kqJyc/PX/u4kA0UFC9UExVoRx/HZsXCg9NHn/1CKeCwTfJ21Q653H+tGSWWoO9/je8O0T4Orhxg/6vSdTCJ+VC0s77TnjuCodRoopKaOo8gcNLzE1TKv4aNRlUc7OXBR2uziqutyyjj+FKfd5bo3LZHwBYGL72+VvQrPNe7bbpRIfs/5PZ1e7Olx4y1Hnfhg57I2BP9PV7KxJ/6dLghcQaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/IOvRIRGh3Bl9lOTZKpGMLh5eFo5cLcEhWhin3LkuYs=; b=mx6W1/iRBfq3h09IGzQuog9M9MFEe1nKQRXoIlifPCb+qdkVQI3tErcKUe6u5Q06b3jv1yGo9rwWNwN1FlhSKj4fiZ+5NkDxl8Yp7KytJsvIOFfZLIzMGboGf0V8IY1OL0q6PKTZnCI6jYwdXTOylH8zOdr311xh7zHuctlnhm2HrwMZYaRAJQ3CG+xleNb9a+IslNwx5vfgor8Z97lsmxnaqFaLvXGYYqGIYAtpPUaSUAD2ngbX/JTdIntBOvoyJrEZU1/EeGTBxYbk8C/oby8vcNdYOCqfSlXBzAz5J1qjY3wIJsOxo0mI6/+PQaNLZ+3uK0+V5Kml9cCArPWrmw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vmware.com; dmarc=pass action=none header.from=vmware.com; dkim=pass header.d=vmware.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vmware.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/IOvRIRGh3Bl9lOTZKpGMLh5eFo5cLcEhWhin3LkuYs=; b=O8UQs3OCsj0YIfI04XJ0sMCPfFdkFWMTTRGfDTAZNiSQcK+0O8sCfGZurw7chdOi7+j3oRAmX30EosubysH5lICtI38qVKDZbzWoN4boySxX4avtPId5GtbWySZBGaeZ2JAJGweVhYuyKdapuV9zpL8TJFrGrI0h8q6PgIRSRNI= Received: from MN2PR05MB6208.namprd05.prod.outlook.com (20.178.241.91) by MN2PR05MB6464.namprd05.prod.outlook.com (20.178.246.202) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2367.16; Thu, 17 Oct 2019 16:28:56 +0000 Received: from MN2PR05MB6208.namprd05.prod.outlook.com ([fe80::f9be:d2d8:1003:99b5]) by MN2PR05MB6208.namprd05.prod.outlook.com ([fe80::f9be:d2d8:1003:99b5%6]) with mapi id 15.20.2347.021; Thu, 17 Oct 2019 16:28:56 +0000 From: Ajay Kaher To: Vlastimil Babka , "gregkh@linuxfoundation.org" CC: "torvalds@linux-foundation.org" , "punit.agrawal@arm.com" , "akpm@linux-foundation.org" , "kirill.shutemov@linux.intel.com" , "willy@infradead.org" , "will.deacon@arm.com" , "mszeredi@redhat.com" , "stable@vger.kernel.org" , "linux-mm@kvack.org" , "linux-kernel@vger.kernel.org" , Srivatsa Bhat , "srivatsa@csail.mit.edu" , Alexey Makhalov , Srinidhi Rao , Vikash Bansal , Anish Swaminathan , Vasavi Sirnapalli , Steven Rostedt , "stable@kernel.org" , Ben Hutchings Subject: Re: [PATCH v2 6/8] mm: prevent get_user_pages() from overflowing page refcount Thread-Topic: [PATCH v2 6/8] mm: prevent get_user_pages() from overflowing page refcount Thread-Index: AQHVfffGKc9CRR2dekieWi7B72DxaadSSqyAgA0lZIA= Date: Thu, 17 Oct 2019 16:28:56 +0000 Message-ID: References: <1570581863-12090-1-git-send-email-akaher@vmware.com> <1570581863-12090-7-git-send-email-akaher@vmware.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=akaher@vmware.com; x-originating-ip: [2405:204:549c:9b0:157a:adf0:3cf7:b301] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 513f87e1-ea4d-4795-d702-08d7531f1b79 x-ms-traffictypediagnostic: MN2PR05MB6464:|MN2PR05MB6464:|MN2PR05MB6464: x-ms-exchange-purlcount: 2 x-ld-processed: b39138ca-3cee-4b4a-a4d6-cd83d9dd62f0,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-forefront-prvs: 01930B2BA8 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(4636009)(366004)(346002)(396003)(136003)(376002)(39860400002)(199004)(189003)(66446008)(478600001)(6436002)(14454004)(25786009)(71190400001)(71200400001)(102836004)(966005)(2501003)(99286004)(6512007)(186003)(6486002)(8676002)(86362001)(8936002)(14444005)(81166006)(229853002)(81156014)(76176011)(6306002)(33656002)(5660300002)(256004)(11346002)(2616005)(476003)(316002)(64756008)(66556008)(446003)(305945005)(4326008)(91956017)(76116006)(66476007)(6506007)(110136005)(54906003)(486006)(66946007)(6246003)(7736002)(7416002)(6116002)(2906002)(46003)(36756003);DIR:OUT;SFP:1101;SCL:1;SRVR:MN2PR05MB6464;H:MN2PR05MB6208.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: vmware.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: nAdprhsS138QtDDDkafsVykjYk77snaXupS/KIR+mseVAiTfMB+5jYns5YrenXsB5rDKvwof3VIJWVAhYGy04Ay4bDgsb3Mi2yhHjyDqJTuPivHDh0l1LA5VMn11pZ/UDjOxGsBuHzjmODWyHe0w4pt8vla/VGeoR/k7mO6irRWJoPm65Qr5t86GEeXT11owk+oS1bPA/dLkdHg3gQ3JhVbBVSjQ42oPl+mDDhHvMRNMXWH4+PwRgYS0G8kXjchAFwaFugi1va6r6DeJneB5WAn7w2I+LRlMsyDtFhUI/er66f43wWTg0LZmZLGnxSZEk2NAILufdXlGVPfMpcxC1jKNO+r65l3AOtTE8h5ph6HL7A9j9FvSrUlQg1l8WKGKTfFz49Piy3fNEIhUl1qJ6iSzMPMzu2t2na0KQRiBnsO5bgYYDxFteZ7KpzoBPWWRsvt8vPvxMMiRZ0BjzaLl/g== Content-Type: text/plain; charset="utf-8" Content-ID: Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: vmware.com X-MS-Exchange-CrossTenant-Network-Message-Id: 513f87e1-ea4d-4795-d702-08d7531f1b79 X-MS-Exchange-CrossTenant-originalarrivaltime: 17 Oct 2019 16:28:56.5166 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: b39138ca-3cee-4b4a-a4d6-cd83d9dd62f0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: PtfFgwfZeoqoCqJLxuv3Tgabwx3ThrmFhK+hVl6vN3QRHJDdr3/KF3dxzLkZqrgM9YAeLMKaASyIjbN/AcxbHA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR05MB6464 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org DQrvu79PbiAwOS8xMC8xOSwgNjo0MyBQTSwgIlZsYXN0aW1pbCBCYWJrYSIgPHZiYWJrYUBzdXNl LmN6PiB3cm90ZToNCg0KPj4gUmVwb3J0ZWQtYnk6IEphbm4gSG9ybiA8amFubmhAZ29vZ2xlLmNv bT4NCj4+IEFja2VkLWJ5OiBNYXR0aGV3IFdpbGNveCA8d2lsbHlAaW5mcmFkZWFkLm9yZz4NCj4+ IENjOiBzdGFibGVAa2Vybm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