Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-23 Thread li guang
在 2013-04-23二的 15:40 -0700,Andrew Morton写道: > On Mon, 22 Apr 2013 13:47:22 +0800 liguang wrote: > > > originally, 'data->flags = CSD_FLAG_LOCK', > > and we use 'data->flags &= ~CSD_FLAG_LOCK' > > for csd_unlock, they are not symmetrix operations > > so use '|=' instead of '='. > > though, now

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-23 Thread Andrew Morton
On Mon, 22 Apr 2013 13:47:22 +0800 liguang wrote: > originally, 'data->flags = CSD_FLAG_LOCK', > and we use 'data->flags &= ~CSD_FLAG_LOCK' > for csd_unlock, they are not symmetrix operations > so use '|=' instead of '='. > though, now data->flags only hold CSD_FLAG_LOCK, > it's not so

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-23 Thread Andrew Morton
On Mon, 22 Apr 2013 13:47:22 +0800 liguang lig.f...@cn.fujitsu.com wrote: originally, 'data-flags = CSD_FLAG_LOCK', and we use 'data-flags = ~CSD_FLAG_LOCK' for csd_unlock, they are not symmetrix operations so use '|=' instead of '='. though, now data-flags only hold CSD_FLAG_LOCK, it's not

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-23 Thread li guang
在 2013-04-23二的 15:40 -0700,Andrew Morton写道: On Mon, 22 Apr 2013 13:47:22 +0800 liguang lig.f...@cn.fujitsu.com wrote: originally, 'data-flags = CSD_FLAG_LOCK', and we use 'data-flags = ~CSD_FLAG_LOCK' for csd_unlock, they are not symmetrix operations so use '|=' instead of '='.

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread Sedat Dilek
On Mon, Apr 22, 2013 at 8:30 AM, Sedat Dilek wrote: > On Mon, Apr 22, 2013 at 8:22 AM, li guang wrote: >> 在 2013-04-22一的 08:18 +0200,Sedat Dilek写道: >>> On Mon, Apr 22, 2013 at 7:47 AM, liguang wrote: >>> > originally, 'data->flags = CSD_FLAG_LOCK', >>> > and we use 'data->flags &=

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread Sedat Dilek
On Mon, Apr 22, 2013 at 8:22 AM, li guang wrote: > 在 2013-04-22一的 08:18 +0200,Sedat Dilek写道: >> On Mon, Apr 22, 2013 at 7:47 AM, liguang wrote: >> > originally, 'data->flags = CSD_FLAG_LOCK', >> > and we use 'data->flags &= ~CSD_FLAG_LOCK' >> > for csd_unlock, they are not symmetrix operations

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread li guang
在 2013-04-22一的 08:18 +0200,Sedat Dilek写道: > On Mon, Apr 22, 2013 at 7:47 AM, liguang wrote: > > originally, 'data->flags = CSD_FLAG_LOCK', > > and we use 'data->flags &= ~CSD_FLAG_LOCK' > > for csd_unlock, they are not symmetrix operations > > so use '|=' instead of '='. > > though, now

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread Sedat Dilek
On Mon, Apr 22, 2013 at 7:47 AM, liguang wrote: > originally, 'data->flags = CSD_FLAG_LOCK', > and we use 'data->flags &= ~CSD_FLAG_LOCK' > for csd_unlock, they are not symmetrix operations > so use '|=' instead of '='. > though, now data->flags only hold CSD_FLAG_LOCK, > it's not so meaningful

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread Sedat Dilek
On Mon, Apr 22, 2013 at 7:47 AM, liguang lig.f...@cn.fujitsu.com wrote: originally, 'data-flags = CSD_FLAG_LOCK', and we use 'data-flags = ~CSD_FLAG_LOCK' for csd_unlock, they are not symmetrix operations so use '|=' instead of '='. though, now data-flags only hold CSD_FLAG_LOCK, it's not so

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread li guang
在 2013-04-22一的 08:18 +0200,Sedat Dilek写道: On Mon, Apr 22, 2013 at 7:47 AM, liguang lig.f...@cn.fujitsu.com wrote: originally, 'data-flags = CSD_FLAG_LOCK', and we use 'data-flags = ~CSD_FLAG_LOCK' for csd_unlock, they are not symmetrix operations so use '|=' instead of '='. though, now

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread Sedat Dilek
On Mon, Apr 22, 2013 at 8:22 AM, li guang lig.f...@cn.fujitsu.com wrote: 在 2013-04-22一的 08:18 +0200,Sedat Dilek写道: On Mon, Apr 22, 2013 at 7:47 AM, liguang lig.f...@cn.fujitsu.com wrote: originally, 'data-flags = CSD_FLAG_LOCK', and we use 'data-flags = ~CSD_FLAG_LOCK' for csd_unlock, they

Re: [PATCH 1/2] smp: use '|=' for csd_lock

2013-04-22 Thread Sedat Dilek
On Mon, Apr 22, 2013 at 8:30 AM, Sedat Dilek sedat.di...@gmail.com wrote: On Mon, Apr 22, 2013 at 8:22 AM, li guang lig.f...@cn.fujitsu.com wrote: 在 2013-04-22一的 08:18 +0200,Sedat Dilek写道: On Mon, Apr 22, 2013 at 7:47 AM, liguang lig.f...@cn.fujitsu.com wrote: originally, 'data-flags =

[PATCH 1/2] smp: use '|=' for csd_lock

2013-04-21 Thread liguang
originally, 'data->flags = CSD_FLAG_LOCK', and we use 'data->flags &= ~CSD_FLAG_LOCK' for csd_unlock, they are not symmetrix operations so use '|=' instead of '='. though, now data->flags only hold CSD_FLAG_LOCK, it's not so meaningful to use '|=' to set 1 bit, and '&= ~' to clear 1 bit.

[PATCH 1/2] smp: use '|=' for csd_lock

2013-04-21 Thread liguang
originally, 'data-flags = CSD_FLAG_LOCK', and we use 'data-flags = ~CSD_FLAG_LOCK' for csd_unlock, they are not symmetrix operations so use '|=' instead of '='. though, now data-flags only hold CSD_FLAG_LOCK, it's not so meaningful to use '|=' to set 1 bit, and '= ~' to clear 1 bit.