[char-misc-next V3] mei: add reference counting for me clients

2015-01-10 Thread Tomas Winkler
To support dynamic addition and removal of me clients we add reference counter. Update kdoc with locking requirements. Signed-off-by: Tomas Winkler --- V2: add locking requirements to kdoc V3: fix warning: 'cb/me_cl' may be used uninitialized in this function drivers/misc/mei/amthif.c | 14

[char-misc-next V3] mei: add reference counting for me clients

2015-01-10 Thread Tomas Winkler
To support dynamic addition and removal of me clients we add reference counter. Update kdoc with locking requirements. Signed-off-by: Tomas Winkler tomas.wink...@intel.com --- V2: add locking requirements to kdoc V3: fix warning: 'cb/me_cl' may be used uninitialized in this function

RE: [char-misc-next V3] mei: add reference counting for me clients

2014-11-06 Thread Winkler, Tomas
> -Original Message- > From: Greg KH [mailto:gre...@linuxfoundation.org] > Sent: Thursday, November 06, 2014 17:58 > To: Winkler, Tomas > Cc: a...@arndb.de; linux-kernel@vger.kernel.org > Subject: Re: [char-misc-next V3] mei: add reference counting for me clients &

Re: [char-misc-next V3] mei: add reference counting for me clients

2014-11-06 Thread Greg KH
On Thu, Nov 06, 2014 at 08:40:21AM +, Winkler, Tomas wrote: > > > > On Tue, Nov 04, 2014 at 05:22:51AM +, Winkler, Tomas wrote: > > > > > > > > On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: > > > > > To support dynamic addition/remove we add reference > > > > > counter. >

RE: [char-misc-next V3] mei: add reference counting for me clients

2014-11-06 Thread Winkler, Tomas
> > On Tue, Nov 04, 2014 at 05:22:51AM +, Winkler, Tomas wrote: > > > > > > On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: > > > > To support dynamic addition/remove we add reference > > > > counter. > > > > > > What is keeping two different threads / cpus from grabbing a

Re: [char-misc-next V3] mei: add reference counting for me clients

2014-11-06 Thread Greg KH
On Thu, Nov 06, 2014 at 08:40:21AM +, Winkler, Tomas wrote: On Tue, Nov 04, 2014 at 05:22:51AM +, Winkler, Tomas wrote: On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: To support dynamic addition/remove we add reference counter. What is keeping

RE: [char-misc-next V3] mei: add reference counting for me clients

2014-11-06 Thread Winkler, Tomas
-Original Message- From: Greg KH [mailto:gre...@linuxfoundation.org] Sent: Thursday, November 06, 2014 17:58 To: Winkler, Tomas Cc: a...@arndb.de; linux-kernel@vger.kernel.org Subject: Re: [char-misc-next V3] mei: add reference counting for me clients On Thu, Nov 06, 2014 at 08

RE: [char-misc-next V3] mei: add reference counting for me clients

2014-11-06 Thread Winkler, Tomas
On Tue, Nov 04, 2014 at 05:22:51AM +, Winkler, Tomas wrote: On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: To support dynamic addition/remove we add reference counter. What is keeping two different threads / cpus from grabbing a reference at the same

Re: [char-misc-next V3] mei: add reference counting for me clients

2014-11-05 Thread Greg KH
On Tue, Nov 04, 2014 at 05:22:51AM +, Winkler, Tomas wrote: > > > > On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: > > > To support dynamic addition/remove we add reference > > > counter. > > > > What is keeping two different threads / cpus from grabbing a reference > > at

Re: [char-misc-next V3] mei: add reference counting for me clients

2014-11-05 Thread Greg KH
On Tue, Nov 04, 2014 at 05:22:51AM +, Winkler, Tomas wrote: On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: To support dynamic addition/remove we add reference counter. What is keeping two different threads / cpus from grabbing a reference at the same time the

RE: [char-misc-next V3] mei: add reference counting for me clients

2014-11-03 Thread Winkler, Tomas
> > On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: > > To support dynamic addition/remove we add reference > > counter. > > What is keeping two different threads / cpus from grabbing a reference > at the same time the other one is dropping it? > > You have a list here, with no

Re: [char-misc-next V3] mei: add reference counting for me clients

2014-11-03 Thread Greg KH
On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: > To support dynamic addition/remove we add reference > counter. What is keeping two different threads / cpus from grabbing a reference at the same time the other one is dropping it? You have a list here, with no locking, right? You

[char-misc-next V3] mei: add reference counting for me clients

2014-11-03 Thread Tomas Winkler
To support dynamic addition/remove we add reference counter. Signed-off-by: Tomas Winkler --- V2: code style and documentation fixes V3: 1. Use refcounter also in mei_me_cl_rm_all, 2. Replace mei_me_cl_rm_by_id with mei_me_cl_rm_by_uuid_id 3. Few more doc fixes

[char-misc-next V3] mei: add reference counting for me clients

2014-11-03 Thread Tomas Winkler
To support dynamic addition/remove we add reference counter. Signed-off-by: Tomas Winkler tomas.wink...@intel.com --- V2: code style and documentation fixes V3: 1. Use refcounter also in mei_me_cl_rm_all, 2. Replace mei_me_cl_rm_by_id with mei_me_cl_rm_by_uuid_id 3. Few more doc

Re: [char-misc-next V3] mei: add reference counting for me clients

2014-11-03 Thread Greg KH
On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: To support dynamic addition/remove we add reference counter. What is keeping two different threads / cpus from grabbing a reference at the same time the other one is dropping it? You have a list here, with no locking, right? You

RE: [char-misc-next V3] mei: add reference counting for me clients

2014-11-03 Thread Winkler, Tomas
On Mon, Nov 03, 2014 at 10:42:05AM +0200, Tomas Winkler wrote: To support dynamic addition/remove we add reference counter. What is keeping two different threads / cpus from grabbing a reference at the same time the other one is dropping it? You have a list here, with no locking,