RE: [PATCH 1/3] alarmtimer: Replace the spinlock rtcdev_lock with mutex

2012-11-01 Thread Liu, Chuansheng
> It's safe to do in any code path which wants to use rtcdev: > > if (!rtcdev) > return -ENODEV: > do_something(rtcdev); > Really thanks your analysis and sharing, learn something. And preparing a new patch with your comments for this point. Subject: [PATCH] alarmtimer: Removing

RE: [PATCH 1/3] alarmtimer: Replace the spinlock rtcdev_lock with mutex

2012-11-01 Thread Thomas Gleixner
On Thu, 1 Nov 2012, Liu, Chuansheng wrote: > > From: Oliver Neukum [mailto:oneu...@suse.de] > > On Thursday 01 November 2012 00:20:55 Chuansheng Liu wrote: > > > When do code reviewing, found no special requirement to > > > use spin_lock_irqsave/spin_unlock_irqrestore, because > > > alarmtimer_get_

RE: [PATCH 1/3] alarmtimer: Replace the spinlock rtcdev_lock with mutex

2012-10-31 Thread Liu, Chuansheng
bject: Re: [PATCH 1/3] alarmtimer: Replace the spinlock rtcdev_lock with > mutex > > On Thursday 01 November 2012 00:20:55 Chuansheng Liu wrote: > > When do code reviewing, found no special requirement to > > use spin_lock_irqsave/spin_unlock_irqrestore, because > >

Re: [PATCH 1/3] alarmtimer: Replace the spinlock rtcdev_lock with mutex

2012-10-31 Thread Oliver Neukum
On Thursday 01 November 2012 00:20:55 Chuansheng Liu wrote: > When do code reviewing, found no special requirement to > use spin_lock_irqsave/spin_unlock_irqrestore, because > alarmtimer_get_rtcdev() is called by posix clock interface. > So would like to use mutex to replace it. What is gained the