Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp568205yba; Fri, 12 Apr 2019 09:06:30 -0700 (PDT) X-Google-Smtp-Source: APXvYqx5KtVFkb1HHhDkdl/lM5FCpCReuL7EnjhuQOYiBPzKGSvuBgIzcTwTps7ezhsJYkbRiSlQ X-Received: by 2002:a17:902:5a2:: with SMTP id f31mr56022144plf.119.1555085189959; Fri, 12 Apr 2019 09:06:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555085189; cv=none; d=google.com; s=arc-20160816; b=tuulrYux5TqIte4kq+OT/cKhh6uiinUNF4/YvhdjA5QvQDvPdm+yFGKc49KYTusAfH yv/OaW5SUCFLXn8lvSzyTEmi4E5kcIfqj5jLNtL5V1XjXXgNcmRUyzGDj4shtwmqNB/h kU8bcnnSxPyJHTbmDc8FUF7e83SPkldJ3Fchce/HmJj2YO+9CEZ68okZS3I21mYnfXTp 1JDaKWUi6LyLWpusieyO4ipmC3WEiVoxMf9ZYTGv7wv5jbeeksw8Z+WmO+5IYiISrKRK 0YkEu5cKNuvTrkRXY9oVdUEpCXQqtR0nvcXwLQgawOU/FeETHc/CQZjgI/dJ1ycbBhNU mauw== ARC-Message-Signature: i=1; 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=RnalLb37tdOT68e+z6j3AK56+aLKTY24jeQrFgWRkh4=; b=q7XnLAaOMpG3C67AyWDgZcLh0FXpGJTrn+PO12se15d8Db+nqzkUmwTexoPP6CMOfw B0qwE2izs+okgS55yyY8MfeMos+I/7ldIXU08+oi4/+C5hTHO0OylYypx0xzzhnNhP8m HXGbTDCUGA0VL1QJHNxbyVWmif5GYeZoMpY7LVpszHFIbW3oQQX0DaksLU18WuJ69IHx SgbTPnsIiyHXVO2GdCLPNjOhiY41MJyFmV4Bk80TtkH8P0BXHZQcU9lHx9ejxAkwqoAk R4fOycowZAxkPrANP2D5Q1E1PKo5vGrzCOptKOEK23rBbOSPwtIkmUQ6riWqd0DMbOdo QLuQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@vmware.com header.s=selector1 header.b="hz/XNTXv"; 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=QUARANTINE 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 y2si36912122pgl.527.2019.04.12.09.06.13; Fri, 12 Apr 2019 09:06:29 -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=selector1 header.b="hz/XNTXv"; 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=QUARANTINE dis=NONE) header.from=vmware.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726865AbfDLQEW (ORCPT + 99 others); Fri, 12 Apr 2019 12:04:22 -0400 Received: from mail-eopbgr800048.outbound.protection.outlook.com ([40.107.80.48]:18496 "EHLO NAM03-DM3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726755AbfDLQEV (ORCPT ); Fri, 12 Apr 2019 12:04:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vmware.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=RnalLb37tdOT68e+z6j3AK56+aLKTY24jeQrFgWRkh4=; b=hz/XNTXv2Mz6ivglj2+apTuLe+XDDBBclwzmHnvuefg5lMSWSVjlc13uq490Tx++otEPwpPtBROcCWsxHrxoMtF0cFQBqDdPMB5x4wobsx4yq848EULhOQ9C2+ajrx8QtNMvAKiMGCdfdpafLNh+vhALjh5W1BnrAVyed6btBQk= Received: from MN2PR05MB6141.namprd05.prod.outlook.com (20.178.241.217) by MN2PR05MB6030.namprd05.prod.outlook.com (20.178.241.159) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1813.9; Fri, 12 Apr 2019 16:04:16 +0000 Received: from MN2PR05MB6141.namprd05.prod.outlook.com ([fe80::91e:292d:e304:78ad]) by MN2PR05MB6141.namprd05.prod.outlook.com ([fe80::91e:292d:e304:78ad%7]) with mapi id 15.20.1792.009; Fri, 12 Apr 2019 16:04:16 +0000 From: Thomas Hellstrom To: "dri-devel@lists.freedesktop.org" , Linux-graphics-maintainer , "linux-kernel@vger.kernel.org" CC: Thomas Hellstrom , Andrew Morton , Matthew Wilcox , Will Deacon , Peter Zijlstra , Rik van Riel , Minchan Kim , Michal Hocko , Huang Ying , Souptick Joarder , =?utf-8?B?SsOpcsO0bWUgR2xpc3Nl?= , "linux-mm@kvack.org" Subject: [PATCH 1/9] mm: Allow the [page|pfn]_mkwrite callbacks to drop the mmap_sem Thread-Topic: [PATCH 1/9] mm: Allow the [page|pfn]_mkwrite callbacks to drop the mmap_sem Thread-Index: AQHU8UlgUqBNZlsCAEaA+wc3NiIS7Q== Date: Fri, 12 Apr 2019 16:04:15 +0000 Message-ID: <20190412160338.64994-2-thellstrom@vmware.com> References: <20190412160338.64994-1-thellstrom@vmware.com> In-Reply-To: <20190412160338.64994-1-thellstrom@vmware.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: VE1PR03CA0023.eurprd03.prod.outlook.com (2603:10a6:802:a0::35) To MN2PR05MB6141.namprd05.prod.outlook.com (2603:10b6:208:c7::25) authentication-results: spf=none (sender IP is ) smtp.mailfrom=thellstrom@vmware.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.20.1 x-originating-ip: [155.4.205.35] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 10f9a846-1d8b-4495-f803-08d6bf6082ec x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600139)(711020)(4605104)(2017052603328)(7193020);SRVR:MN2PR05MB6030; x-ms-traffictypediagnostic: MN2PR05MB6030: x-ld-processed: b39138ca-3cee-4b4a-a4d6-cd83d9dd62f0,ExtAddr x-microsoft-antispam-prvs: x-forefront-prvs: 0005B05917 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(136003)(366004)(346002)(376002)(39860400002)(396003)(199004)(189003)(110136005)(25786009)(476003)(2616005)(71190400001)(6512007)(2906002)(186003)(486006)(316002)(54906003)(68736007)(1076003)(6486002)(6436002)(446003)(478600001)(3846002)(71200400001)(6116002)(11346002)(66574012)(99286004)(256004)(14444005)(14454004)(2501003)(8676002)(66066001)(7736002)(4326008)(6506007)(81166006)(36756003)(81156014)(386003)(97736004)(102836004)(50226002)(106356001)(52116002)(5660300002)(53936002)(8936002)(7416002)(305945005)(76176011)(26005)(86362001)(105586002);DIR:OUT;SFP:1101;SCL:1;SRVR:MN2PR05MB6030;H:MN2PR05MB6141.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-message-info: sWkyFCpQHafy3Wcw2aH9xrkAISUryjWv/yjF9No2JxMuwgTKhzm5tTypuA8/dDl2souKvun/0Rtx9zYY6YMpUbschdES/dmx1oIrTnRJJ35umFk2p1LIpJhXVNXDftd5uuI/ERYu8ZTZ2cDX0oepv1R6oiabE41cuMJat0HTb1HWq8dqJ/NmJPDV+7IYc+iYJ5gkfquGxR/RWXCkCnQQsSZsVPjE8M8T97tqIAIAJK2C8df3/YPRPAFTexsxQ2VXYW7hk4i82IfTSXFehlLeFswVhpJaF42ENV7nZr9uF5HJ0F2wzSlA3uqdiMLgrpOwyd8Lwa3RTXjYz0fLbvaM7URP2PmAelcs51l84YxmkOf65dpPH0pKVXZlLDx13j+USjg/vR7DCgQOKJNxzNZ4J0CaZR8umzvhL44LveIyeY4= Content-Type: text/plain; charset="utf-8" Content-ID: <97BDAE19231BEF48BCE613AF38370D78@namprd05.prod.outlook.com> Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: vmware.com X-MS-Exchange-CrossTenant-Network-Message-Id: 10f9a846-1d8b-4495-f803-08d6bf6082ec X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Apr 2019 16:04:15.9011 (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-Transport-CrossTenantHeadersStamped: MN2PR05MB6030 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RHJpdmVyIGZhdWx0IGNhbGxiYWNrcyBhcmUgYWxsb3dlZCB0byBkcm9wIHRoZSBtbWFwX3NlbSB3 aGVuIGV4cGVjdGluZw0KbG9uZyBoYXJkd2FyZSB3YWl0cyB0byBhdm9pZCBibG9ja2luZyBvdGhl ciBtbSB1c2Vycy4gQWxsb3cgdGhlIG1rd3JpdGUNCmNhbGxiYWNrcyB0byBkbyB0aGUgc2FtZSBi eSByZXR1cm5pbmcgZWFybHkgb24gVk1fRkFVTFRfUkVUUlkuDQoNCkluIHBhcnRpY3VsYXIgd2Ug d2FudCB0byBiZSBhYmxlIHRvIGRyb3AgdGhlIG1tYXBfc2VtIHdoZW4gd2FpdGluZyBmb3INCmEg c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