Lines Matching refs:hwlock
61 int hwspin_lock_free(struct hwspinlock *hwlock);
67 int hwspin_lock_timeout(struct hwspinlock *hwlock, unsigned int timeout);
79 int hwspin_lock_timeout_irq(struct hwspinlock *hwlock, unsigned int timeout);
90 int hwspin_lock_timeout_irqsave(struct hwspinlock *hwlock, unsigned int to,
103 int hwspin_trylock(struct hwspinlock *hwlock);
114 int hwspin_trylock_irq(struct hwspinlock *hwlock);
124 int hwspin_trylock_irqsave(struct hwspinlock *hwlock, unsigned long *flags);
135 void hwspin_unlock(struct hwspinlock *hwlock);
141 void hwspin_unlock_irq(struct hwspinlock *hwlock);
149 hwspin_unlock_irqrestore(struct hwspinlock *hwlock, unsigned long *flags);
157 int hwspin_lock_get_id(struct hwspinlock *hwlock);
162 Returns the hwspinlock id number, or -EINVAL if hwlock is null.
171 struct hwspinlock *hwlock;
175 hwlock = hwspin_lock_request();
176 if (!hwlock)
179 id = hwspin_lock_get_id(hwlock);
183 ret = hwspin_lock_timeout(hwlock, 1000);
192 hwspin_unlock(hwlock);
195 ret = hwspin_lock_free(hwlock);
204 struct hwspinlock *hwlock;
211 hwlock = hwspin_lock_request_specific(PREDEFINED_LOCK_ID);
212 if (!hwlock)
216 ret = hwspin_trylock(hwlock);
227 hwspin_unlock(hwlock);
230 ret = hwspin_lock_free(hwlock);