Received: by 10.223.176.5 with SMTP id f5csp3746712wra; Mon, 29 Jan 2018 18:57:37 -0800 (PST) X-Google-Smtp-Source: AH8x227k6/8tD3WP6GvmWB1Eb+bEmZJdJQwwxLRJn5WnJxC9csQnRhIspeqXLg/N2OaqcSJG0z7U X-Received: by 10.99.51.203 with SMTP id z194mr21782942pgz.217.1517281057306; Mon, 29 Jan 2018 18:57:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517281057; cv=none; d=google.com; s=arc-20160816; b=LmEQfewStVrDABUhwHaIioLqH/D/RguGLAmAEjbIoZGFBnTq4JGxkPSI0AbSeLaTMK mv7/Hnu3qE04aNFAeySMNtlu9YywQYZ3C8707YtYKi9JB+DJlek+Erc4n41B/RWegdie 4aOJRqvALgnsozKocXNi49PNbHZRMiijn54U/XLs0VnX14GtbW7HCrNJBrETDKogJqZv qSvYaKUPdFgejdZzxgjJgEa/0niWL8Jv3LBmwJ6YmynfuG04Hrn8SSR369IWGNiaac0a tGSOrvWiSQFkK9IH8rtp89koZCRPoSXEbKTnFb6IyNVm5SqG+QF1CvC4AiSBMle3kkyg oKvA== 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 :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=/GQCYi4OgGl7/tmkqP5sPp1NZFaxOUKcsaB4xWwFa3A=; b=UKHY3Zf1FRGZWyap0JPDMkTEM5sIInrdAf5RpMPbErfo6iitTC/SaAdFHl/VTxrT8c hpx6A0KUZa2VUWE4bZbcZV6CiI+Vrvt7zQwawKynUDRT1cu9HJ5zypC2L9xgSm8Pl4Ey gBtLixcEMxzDoRoX98a56feGF+DtdZhuhqBzjU3BLzicQ7cd6yRtdIFioyJlvsZTRwsQ xe3nCdX8K81Z8CK+f2pWhUq1LCZwB8GkhG1c+VpcW5ZhISVfFQ6/2XTD3LkZVkv3yWmH UXaxoKjH0PJlhgTNVhYyg36WpPGp5qKySEiC/89TWGABkGoUSyDvAHykvBE8bFy65F1A ySJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amdcloud.onmicrosoft.com header.s=selector1-amd-com header.b=S5h3sk7j; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n3-v6si682500plb.218.2018.01.29.18.57.22; Mon, 29 Jan 2018 18:57:37 -0800 (PST) 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=@amdcloud.onmicrosoft.com header.s=selector1-amd-com header.b=S5h3sk7j; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752638AbeA3C44 (ORCPT + 99 others); Mon, 29 Jan 2018 21:56:56 -0500 Received: from mail-co1nam03on0058.outbound.protection.outlook.com ([104.47.40.58]:51707 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752378AbeA3C4y (ORCPT ); Mon, 29 Jan 2018 21:56:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=/GQCYi4OgGl7/tmkqP5sPp1NZFaxOUKcsaB4xWwFa3A=; b=S5h3sk7jLyKhSu0VI26NdObk91ELcuUIORdjSBkwvNN9FWCNyojRRXJrTJ7s0765pLPg8P7C0kByT13GCO/KNE96nR64GsQB0+dtdilhk3HbaMERvKt3uDS3wpOyl63nlOwb/JvTg0mb588AqRLth3DcX4F2wc8iz+W2/W5gOhg= Received: from MWHPR1201MB0127.namprd12.prod.outlook.com (10.174.98.142) by MWHPR1201MB2477.namprd12.prod.outlook.com (10.172.95.135) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.444.14; Tue, 30 Jan 2018 02:56:53 +0000 Received: from MWHPR1201MB0127.namprd12.prod.outlook.com ([10.174.98.142]) by MWHPR1201MB0127.namprd12.prod.outlook.com ([10.174.98.142]) with mapi id 15.20.0444.016; Tue, 30 Jan 2018 02:56:52 +0000 From: "He, Roger" To: Michal Hocko CC: "linux-mm@kvack.org" , "linux-kernel@vger.kernel.org" , "dri-devel@lists.freedesktop.org" , "Koenig, Christian" Subject: RE: [PATCH] mm/swap: add function get_total_swap_pages to expose total_swap_pages Thread-Topic: [PATCH] mm/swap: add function get_total_swap_pages to expose total_swap_pages Thread-Index: AQHTmNtYoBUw/9kRPkGbswRNbnupYaOLC3EAgAClcwA= Date: Tue, 30 Jan 2018 02:56:51 +0000 Message-ID: References: <1517214582-30880-1-git-send-email-Hongbo.He@amd.com> <20180129163114.GH21609@dhcp22.suse.cz> In-Reply-To: <20180129163114.GH21609@dhcp22.suse.cz> 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=Hongbo.He@amd.com; x-originating-ip: [116.228.147.241] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;MWHPR1201MB2477;7:/d0e5WBvKfaooULQanouWFg1F+N5On8bWfnpafH3YRVt6zeaLwT6OvwRUrVoMstWghF1T/Zcz7qvOI8Eczu5HWHz4mOemT1cr3tcSnlal8eNG5gbvVUZ+vto7hUZweKwNQLKWMWJd/rEy15pis/MZBDXRch6BqPnUFEQWtGRq35latg/rJqfpVOCs7R/Uuy4Yb68YAULyobhw9t8khKQvWZxvr2QTLVUyNic0Gvmg54PXnnUsPYzNpNd3of0hl7m;20:+pUesfRZyA+gT6bND9Sv5/NjAYt2sVZJwQ99eYzFy4vpq+7QGv7AflRO5Pvn+Jc/C/kj4eD7qpgW82U2S7BwqbTmf5AuGVu3VaH9I+2PvfLAqtIjG4szH/sKvRw7cnEZCgVOOEdt5KX5389+i3QtOP/Jtjj85SbEyj7De19A9ufgSZFYd8quHzS3GBG2J/6n+ZM/jB+SJJosnkL+tLKTwiA3CRoTJhLIq05hnV/AJSedDRTJvUqEQouULdUlF62m x-ms-exchange-antispam-srfa-diagnostics: SSOS;SSOR; x-forefront-antispam-report: SFV:SKI;SCL:-1;SFV:NSPM;SFS:(10009020)(366004)(346002)(396003)(39380400002)(376002)(39860400002)(199004)(189003)(13464003)(377424004)(26005)(53936002)(3280700002)(3660700001)(316002)(305945005)(7736002)(2950100002)(186003)(6916009)(6436002)(86362001)(9686003)(55016002)(99286004)(77096007)(105586002)(106356001)(54906003)(2900100001)(6306002)(5660300001)(8676002)(68736007)(478600001)(4326008)(2906002)(33656002)(7696005)(76176011)(6506007)(53546011)(102836004)(966005)(97736004)(72206003)(3846002)(66066001)(8936002)(229853002)(74316002)(81156014)(59450400001)(14454004)(25786009)(6246003)(6116002)(81166006);DIR:OUT;SFP:1101;SCL:1;SRVR:MWHPR1201MB2477;H:MWHPR1201MB0127.namprd12.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 5f612e97-c428-4373-c38b-08d5678d1d31 x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(4534165)(4627221)(201703031133081)(201702281549075)(48565401081)(5600026)(4604075)(3008032)(2017052603307)(7153060)(7193020);SRVR:MWHPR1201MB2477; x-ms-traffictypediagnostic: MWHPR1201MB2477: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(9452136761055)(767451399110)(217544274631240); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(6040501)(2401047)(8121501046)(5005006)(3231101)(944501161)(93006095)(93001095)(10201501046)(3002001)(6055026)(6041288)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123564045)(20161123562045)(20161123558120)(6072148)(201708071742011);SRVR:MWHPR1201MB2477;BCL:0;PCL:0;RULEID:;SRVR:MWHPR1201MB2477; x-forefront-prvs: 0568F32D91 received-spf: None (protection.outlook.com: amd.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: xFMSawsZnFMC+39bxCgQ3FdaxpX/JGGcd7RZfBWZhXb6YmhF9KI+5SzQl7SuGXkMH5rISrBRsj4ixTMst8QqQQ== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5f612e97-c428-4373-c38b-08d5678d1d31 X-MS-Exchange-CrossTenant-originalarrivaltime: 30 Jan 2018 02:56:51.8924 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR1201MB2477 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org SGkgTWljaGFsOg0KDQpXZSBuZWVkIGEgQVBJIHRvIHRlbGwgVFRNIG1vZHVsZSB0aGUgc3lzdGVt IHRvdGFsbHkgaGFzIGhvdyBtYW55IHN3YXAgY2FjaGUuDQpUaGVuIFRUTSBtb2R1bGUgY2FuIHVz ZSBpdCB0byByZXN0cmljdCBob3cgbWFueSB0aGUgc3dhcCBjYWNoZSBpdCBjYW4gdXNlIHRvIHBy ZXZlbnQgdHJpZ2dlcmluZy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