Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753499AbbHSNZw (ORCPT ); Wed, 19 Aug 2015 09:25:52 -0400 Received: from mail-qg0-f53.google.com ([209.85.192.53]:33807 "EHLO mail-qg0-f53.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751239AbbHSNZt (ORCPT ); Wed, 19 Aug 2015 09:25:49 -0400 From: Murilo Opsfelder Araujo To: linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org Cc: Konrad Rzeszutek Wilk , Boris Ostrovsky , Julien Grall , Stefano Stabellini , David Vrabel , Murilo Opsfelder Araujo Subject: [PATCH] xen/tmem: Pass page instead of pfn to xen_tmem_get_page() Date: Wed, 19 Aug 2015 10:25:19 -0300 Message-Id: <1439990719-19517-1-git-send-email-mopsfelder@gmail.com> X-Mailer: git-send-email 2.1.4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1813 Lines: 48 The commit 091208a676dfdabb2b8fe86ee155c6fc80081b69 "xen/tmem: Use xen_page_to_gfn rather than pfn_to_gfn" left behind a call to xen_tmem_get_page() receiving pfn instead of page. This change also fixes the following build warning: drivers/xen/tmem.c: In function ‘tmem_cleancache_get_page’: drivers/xen/tmem.c:194:47: warning: passing argument 4 of ‘xen_tmem_get_page’ makes pointer from integer without a cast ret = xen_tmem_get_page((u32)pool, oid, ind, pfn); ^ drivers/xen/tmem.c:138:12: note: expected ‘struct page *’ but argument is of type ‘long unsigned int’ static int xen_tmem_get_page(u32 pool_id, struct tmem_oid oid, ^ Signed-off-by: Murilo Opsfelder Araujo --- drivers/xen/tmem.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/xen/tmem.c b/drivers/xen/tmem.c index b0c895e..945fc43 100644 --- a/drivers/xen/tmem.c +++ b/drivers/xen/tmem.c @@ -183,7 +183,6 @@ static int tmem_cleancache_get_page(int pool, struct cleancache_filekey key, { u32 ind = (u32) index; struct tmem_oid oid = *(struct tmem_oid *)&key; - unsigned long pfn = page_to_pfn(page); int ret; /* translate return values to linux semantics */ @@ -191,7 +190,7 @@ static int tmem_cleancache_get_page(int pool, struct cleancache_filekey key, return -1; if (ind != index) return -1; - ret = xen_tmem_get_page((u32)pool, oid, ind, pfn); + ret = xen_tmem_get_page((u32)pool, oid, ind, page); if (ret == 1) return 0; else -- 2.1.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/