lkml.org 
[lkml]   [2006]   [Mar]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Try 2, Fix release function in IPMI device model
Dmitry Torokhov wrote:

>On 3/22/06, Corey Minyard <minyard@acm.org> wrote:
>
>
>> struct bmc_device
>> {
>>- struct platform_device dev;
>>+ struct platform_device *dev;
>> struct ipmi_device_id id;
>> unsigned char guid[16];
>> int guid_set;
>>- int interfaces;
>>+
>>+ struct kref refcount;
>>
>>
>>
>
>Hi,
>
>I am confused as to why you need kref here. Just unregister/kfree
>memory occupied by your device structure after doing
>platform_device_unregister and that's it. platform code won't
>reference your memory and your attribute code should not be called
>from module exit code so everything shoudl be fine.
>
>
This structure represents a "BMC", which is a microcontroller
that does managment functions. There may be more than one
interface to a BMC, so the kref keeps track of all the interfaces
referencing the structure.

-Corey
-
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/

\
 
 \ /
  Last update: 2006-03-22 22:30    [W:1.625 / U:0.336 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site