[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <50C124B7.4070502@canonical.com>
Date: Thu, 06 Dec 2012 16:05:27 -0700
From: Tim Gardner <tim.gardner@...onical.com>
To: Dave Airlie <airlied@...il.com>
CC: linux-kernel@...r.kernel.org,
"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
dri-devel@...ts.freedesktop.org,
David Howells <dhowells@...hat.com>,
Dave Airlie <airlied@...hat.com>
Subject: Re: [PATCH 3.7-rc8] ttm: Fix possible _manager memory allocation
oops
On 12/06/2012 03:46 PM, Dave Airlie wrote:
>>
>> ttm_page_pool_init_locked(&_manager->wc_pool, GFP_HIGHUSER, "wc");
>>
>> @@ -817,6 +821,7 @@ int ttm_page_alloc_init(struct ttm_mem_global *glob, unsigned max_pages)
>> &glob->kobj, "pool");
>> if (unlikely(ret != 0)) {
>> kobject_put(&_manager->kobj);
>> + kfree(_manager);
>> _manager = NULL;
>
> I don;t think this is, since the kobject_put shuold free it.
>
kobject_put only frees memory referenced by kobj, but not the memory
pointed at by _manager.
rtg
--
Tim Gardner tim.gardner@...onical.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists