[<prev] [next>] [day] [month] [year] [list]
Message-ID: <1496333486.1567.0.camel@seibold.net>
Date: Thu, 01 Jun 2017 18:11:26 +0200
From: Logan Gunthorpe <logang@...tatee.com>
To: linux-kernel@...r.kernel.org
Cc: Logan Gunthorpe <logang@...tatee.com>,
Stephen Bates <sbates@...thlin.com>,
Stefani Seibold <stefani@...bold.net>,
Greg KH <greg@...ah.com>,
Andrew Morton <akpm@...ux-foundation.org>
Subject: [PATCH] kfifo: cleanup example to not use page_link
This is a layering violation so we replace the uses with calls to
sg_page(). This is a prep patch for replacing page_link and this
is one of the very few uses outside of scatterlist.h.
I. Acked-by: Stefani Seibold <stefani@...bold.net>
Signed-off-by: Logan Gunthorpe <logang@...tatee.com>
Signed-off-by: Stephen Bates <sbates@...thlin.com>
Cc: Stefani Seibold <stefani@...bold.net>
Cc: Greg KH <greg@...ah.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>
---
samples/kfifo/dma-example.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/samples/kfifo/dma-example.c b/samples/kfifo/dma-example.c
index aa243db..be0d4a5 100644
--- a/samples/kfifo/dma-example.c
+++ b/samples/kfifo/dma-example.c
@@ -75,8 +75,8 @@ static int __init example_init(void)
for (i = 0; i < nents; i++) {
printk(KERN_INFO
"sg[%d] -> "
- "page_link 0x%.8lx offset 0x%.8x length 0x%.8x\n",
- i, sg[i].page_link, sg[i].offset,
sg[i].length);
+ "page %p offset 0x%.8x length 0x%.8x\n",
+ i, sg_page(&sg[i]), sg[i].offset,
sg[i].length);
if (sg_is_last(&sg[i]))
break;
@@ -104,8 +104,8 @@ static int __init example_init(void)
for (i = 0; i < nents; i++) {
printk(KERN_INFO
"sg[%d] -> "
- "page_link 0x%.8lx offset 0x%.8x length 0x%.8x\n",
- i, sg[i].page_link, sg[i].offset,
sg[i].length);
+ "page %p offset 0x%.8x length 0x%.8x\n",
+ i, sg_page(&sg[i]), sg[i].offset,
sg[i].length);
if (sg_is_last(&sg[i]))
break;
Powered by blists - more mailing lists