FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Device-mapper Development

 
 
LinkBack Thread Tools
 
Old 05-25-2011, 04:47 PM
Mikulas Patocka
 
Default dm-kcopyd: Introduce gfp flags for alloc_pl

dm-kcopyd: Introduce gfp flags for alloc_pl

It will be used in further patches.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>

---
drivers/md/dm-kcopyd.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)

Index: linux-2.6.39-fast/drivers/md/dm-kcopyd.c
================================================== =================
--- linux-2.6.39-fast.orig/drivers/md/dm-kcopyd.c 2011-05-24 22:14:45.000000000 +0200
+++ linux-2.6.39-fast/drivers/md/dm-kcopyd.c 2011-05-25 13:19:02.000000000 +0200
@@ -70,15 +70,15 @@ static void wake(struct dm_kcopyd_client
queue_work(kc->kcopyd_wq, &kc->kcopyd_work);
}

-static struct page_list *alloc_pl(void)
+static struct page_list *alloc_pl(gfp_t gfp)
{
struct page_list *pl;

- pl = kmalloc(sizeof(*pl), GFP_KERNEL);
+ pl = kmalloc(sizeof(*pl), gfp);
if (!pl)
return NULL;

- pl->page = alloc_page(GFP_KERNEL);
+ pl->page = alloc_page(gfp);
if (!pl->page) {
kfree(pl);
return NULL;
@@ -143,7 +143,7 @@ static int client_alloc_pages(struct dm_
struct page_list *pl = NULL, *next;

for (i = 0; i < nr; i++) {
- next = alloc_pl();
+ next = alloc_pl(GFP_KERNEL);
if (!next) {
if (pl)
drop_pages(pl);

--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
 
Old 05-25-2011, 05:50 PM
Joe Thornber
 
Default dm-kcopyd: Introduce gfp flags for alloc_pl

Thanks Mikulas,

I've reviewed and tested these 4 patches.

- Joe

On Wed, 2011-05-25 at 12:47 -0400, Mikulas Patocka wrote:
> dm-kcopyd: Introduce gfp flags for alloc_pl
>
> It will be used in further patches.
>
> Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>

--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
 

Thread Tools




All times are GMT. The time now is 10:23 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org