Lines Matching +full:sleep +full:- +full:hardware +full:- +full:state
2 Hardware Spinlock Framework
8 Hardware spinlock modules provide hardware assistance for synchronization
12 For example, OMAP4 has dual Cortex-A9, dual Cortex-M3 and a C64x+ DSP,
17 A generic hwspinlock framework allows platform-independent drivers to use
22 This is necessary, for example, for Inter-processor communications:
23 on OMAP4, cpu-intensive multimedia tasks are offloaded by the host to the
26 To achieve fast message-based communications, a minimal kernel support
35 A common hwspinlock interface makes it possible to have generic, platform-
50 Should be called from a process context (might sleep).
61 Should be called from a process context (might sleep).
67 Retrieve the global lock id for an OF phandle-based specific lock.
72 The function returns a lock id number on success, -EPROBE_DEFER if
76 Should be called from a process context (might sleep).
82 Free a previously-assigned hwspinlock; returns 0 on success, or an
83 appropriate error code on failure (e.g. -EINVAL if the hwspinlock
86 Should be called from a process context (might sleep).
94 (e.g. -EOPNOTSUPP if the bust operation is not defined for the specific
97 Should be called from a process context (might sleep).
103 Lock a previously-assigned hwspinlock with a timeout limit (specified in
107 the caller must not sleep, and is advised to release the hwspinlock as
109 hardware interconnect.
112 notably -ETIMEDOUT if the hwspinlock is still busy after timeout msecs).
113 The function will never sleep.
119 Lock a previously-assigned hwspinlock with a timeout limit (specified in
123 interrupts are disabled, so the caller must not sleep, and is advised to
127 notably -ETIMEDOUT if the hwspinlock is still busy after timeout msecs).
128 The function will never sleep.
135 Lock a previously-assigned hwspinlock with a timeout limit (specified in
139 local interrupts are disabled and their previous state is saved at the
140 given flags placeholder. The caller must not sleep, and is advised to
144 notably -ETIMEDOUT if the hwspinlock is still busy after timeout msecs).
146 The function will never sleep.
152 Lock a previously-assigned hwspinlock with a timeout limit (specified in
156 Caution: User must protect the routine of getting hardware lock with mutex
157 or spinlock to avoid dead-lock, that will let user can do some time-consuming
158 or sleepable operations under the hardware lock.
161 notably -ETIMEDOUT if the hwspinlock is still busy after timeout msecs).
163 The function will never sleep.
169 Lock a previously-assigned hwspinlock with a timeout limit (specified in
177 notably -ETIMEDOUT if the hwspinlock is still busy after timeout msecs).
179 The function will never sleep.
186 Attempt to lock a previously-assigned hwspinlock, but immediately fail if
190 caller must not sleep, and is advised to release the hwspinlock as soon as
191 possible, in order to minimize remote cores polling on the hardware
195 notably -EBUSY if the hwspinlock was already taken).
196 The function will never sleep.
203 Attempt to lock a previously-assigned hwspinlock, but immediately fail if
207 interrupts are disabled so caller must not sleep, and is advised to
211 notably -EBUSY if the hwspinlock was already taken).
213 The function will never sleep.
219 Attempt to lock a previously-assigned hwspinlock, but immediately fail if
223 the local interrupts are disabled and their previous state is saved
224 at the given flags placeholder. The caller must not sleep, and is advised
228 notably -EBUSY if the hwspinlock was already taken).
229 The function will never sleep.
235 Attempt to lock a previously-assigned hwspinlock, but immediately fail if
238 Caution: User must protect the routine of getting hardware lock with mutex
239 or spinlock to avoid dead-lock, that will let user can do some time-consuming
240 or sleepable operations under the hardware lock.
243 notably -EBUSY if the hwspinlock was already taken).
244 The function will never sleep.
250 Attempt to lock a previously-assigned hwspinlock, but immediately fail if
256 notably -EBUSY if the hwspinlock was already taken).
257 The function will never sleep.
263 Unlock a previously-locked hwspinlock. Always succeed, and can be called
275 Unlock a previously-locked hwspinlock and enable local interrupts.
280 interrupts are enabled. This function will never sleep.
287 Unlock a previously-locked hwspinlock.
292 and the state of the local interrupts is restored to the state saved at
293 the given flags. This function will never sleep.
299 Unlock a previously-locked hwspinlock.
303 This function will never sleep.
309 Unlock a previously-locked hwspinlock.
313 This function will never sleep.
324 Returns the hwspinlock id number, or -EINVAL if hwlock is null.
353 * we took the lock, do our thing now, but do NOT sleep
373 * assign a specific hwspinlock id - this should be called early
384 return -EBUSY;
388 * we took the lock, do our thing now, but do NOT sleep
411 To be called from the underlying platform-specific implementation, in
414 might sleep).
422 To be called from the underlying vendor-specific implementation, in order
426 Should be called from a process context (this function might sleep).
435 of hardware locks. It is registered by the underlying hwspinlock
441 * struct hwspinlock_device - a device which usually spans numerous hwspinlocks
443 * @ops: platform-specific hwspinlock handlers
457 of which represents a single hardware lock::
460 * struct hwspinlock - this struct represents a single hwspinlock instance
463 * @priv: private data, owned by the underlying platform-specific hwspinlock drv
488 The ->trylock() callback should make a single attempt to take the lock, and
489 return 0 on failure and 1 on success. This callback may **not** sleep.
491 The ->unlock() callback releases the lock. It always succeed, and it, too,
492 may **not** sleep.
494 The ->relax() callback is optional. It is called by hwspinlock core while
496 a delay between two successive invocations of ->trylock(). It may **not** sleep.