Home
last modified time | relevance | path

Searched full:guard (Results 1 – 25 of 753) sorted by relevance

12345678910>>...31

/linux-6.12.1/rust/kernel/sync/
Dcondvar.rs8 use super::{lock::Backend, lock::Guard, LockClassKey};
60 /// let mut guard = e.value.lock();
61 /// while *guard != v {
62 /// e.value_changed.wait(&mut guard);
119 guard: &mut Guard<'_, T, B>, in wait_internal()
133 let ret = guard.do_unlocked(|| unsafe { bindings::schedule_timeout(timeout_in_jiffies) }); in wait_internal()
143 /// Atomically releases the given lock (whose ownership is proven by the guard) and puts the
147 pub fn wait<T: ?Sized, B: Backend>(&self, guard: &mut Guard<'_, T, B>) { in wait()
148 self.wait_internal(TASK_UNINTERRUPTIBLE, guard, MAX_SCHEDULE_TIMEOUT); in wait()
158 pub fn wait_interruptible<T: ?Sized, B: Backend>(&self, guard: &mut Guard<'_, T, B>) -> bool { in wait_interruptible()
[all …]
Dlock.rs3 //! Generic kernel lock and guard.
5 //! It contains a generic Rust lock and guard that allow for different backends (e.g., mutexes,
124 pub fn lock(&self) -> Guard<'_, T, B> { in lock()
129 unsafe { Guard::new(self, state) } in lock()
133 /// A lock guard.
136 /// when a guard goes out of scope. It also provides a safe and convenient way to access the data
138 #[must_use = "the lock unlocks immediately when the guard is unused"]
139 pub struct Guard<'a, T: ?Sized, B: Backend> { struct
145 // SAFETY: `Guard` is sync when the data protected by the lock is also sync. argument
146 unsafe impl<T: Sync + ?Sized, B: Backend> Sync for Guard<'_, T, B> {} implementation
[all …]
Dlocked_by.rs56 /// let guard = dir.inner.lock();
57 /// let inner_file = file.inner.access(&guard);
58 /// pr_info!("{} {}", guard.bytes_used, inner_file.bytes_used);
63 /// let mut guard = dir.inner.lock();
64 /// guard.bytes_used += 10;
66 /// let file_inner = file.inner.access_mut(&mut guard);
/linux-6.12.1/drivers/virt/coco/
Dtsm.c104 guard(rwsem_write)(&tsm_rwsem); in tsm_report_privlevel_store()
117 guard(rwsem_read)(&tsm_rwsem); in tsm_report_privlevel_floor_show()
130 guard(rwsem_write)(&tsm_rwsem); in tsm_report_service_provider_store()
154 guard(rwsem_write)(&tsm_rwsem); in tsm_report_service_guid_store()
180 guard(rwsem_write)(&tsm_rwsem); in tsm_report_service_manifest_version_store()
196 guard(rwsem_write)(&tsm_rwsem); in tsm_report_inblob_write()
212 guard(rwsem_read)(&tsm_rwsem); in tsm_report_generation_show()
219 guard(rwsem_read)(&tsm_rwsem); in tsm_report_provider_show()
256 guard(rwsem_read)(&tsm_rwsem); in read_cached_report()
284 guard(rwsem_write)(&tsm_rwsem); in tsm_report_read()
[all …]
/linux-6.12.1/drivers/char/tpm/
Dtpm_tis_i2c.c33 /* Default Guard Time of 250µs until interface capability register is read */
37 /* Guard Time of 250µs after I2C slave NACK */
41 /* Guard Time bit masks; SR is repeated start, RW is read then write, etc. */
277 * Guard Time:
282 * Before the Guard Time is read (or after the TPM failed to send an I2C NACK),
283 * a Guard Time of 250µs applies.
285 * Various flags in the same register indicate if a guard time is needed:
286 * - SR: <I2C read with repeated start> <guard time> <I2C read>
287 * - RR: <I2C read> <guard time> <I2C read>
288 * - RW: <I2C read> <guard time> <I2C write>
[all …]
/linux-6.12.1/include/rdma/
Dsignature.h33 * enum ib_t10_dif_bg_type - Signature T10-DIF block-guard types
45 * @bg_type: T10-DIF block guard type (CRC|CSUM)
47 * @bg: seed of guard computation.
48 * @app_tag: application tag of guard block
49 * @ref_tag: initial guard block reference tag.
103 * | GUARD | APPTAG | REFTAG |
/linux-6.12.1/Documentation/mm/
Dvmalloced-kernel-stacks.rst25 Virtually mapped kernel stacks with guard pages cause kernel stack
30 support for virtually mapped stacks with guard pages. This feature
53 - If the stack overflows into a guard page, something reasonable
64 with guard pages. This causes kernel stack overflows to be caught
123 Leading and trailing guard pages help detect stack overflows. When the stack
124 overflows into the guard pages, handlers have to be careful not to overflow
131 Testing VMAP allocation with guard pages
135 and trailing guard page? The following lkdtm tests can help detect any
/linux-6.12.1/drivers/gpio/
Dgpiolib.c366 CLASS(gpio_chip_guard, guard)(desc); in gpiod_get_direction()
367 if (!guard.gc) in gpiod_get_direction()
381 if (!guard.gc->get_direction) in gpiod_get_direction()
384 ret = guard.gc->get_direction(guard.gc, offset); in gpiod_get_direction()
468 guard(srcu)(&gpio_devices_srcu); in gpio_name_to_desc()
472 guard(srcu)(&gdev->srcu); in gpio_name_to_desc()
817 guard(srcu)(&gpio_devices_srcu); in gpiochip_setup_devs()
1193 guard(srcu)(&gpio_devices_srcu); in gpio_device_find()
1200 guard(srcu)(&gdev->srcu); in gpio_device_find()
2280 CLASS(gpio_chip_guard, guard)(desc); in gpiod_request_commit()
[all …]
Dgpiolib-sysfs.c175 CLASS(gpio_chip_guard, guard)(desc); in gpio_sysfs_request_irq()
176 if (!guard.gc) in gpio_sysfs_request_irq()
203 ret = gpiochip_lock_as_irq(guard.gc, gpio_chip_hwgpio(desc)); in gpio_sysfs_request_irq()
217 gpiochip_unlock_as_irq(guard.gc, gpio_chip_hwgpio(desc)); in gpio_sysfs_request_irq()
233 CLASS(gpio_chip_guard, guard)(desc); in gpio_sysfs_free_irq()
234 if (!guard.gc) in gpio_sysfs_free_irq()
239 gpiochip_unlock_as_irq(guard.gc, gpio_chip_hwgpio(desc)); in gpio_sysfs_free_irq()
470 CLASS(gpio_chip_guard, guard)(desc); in export_store()
471 if (!guard.gc) in export_store()
475 if (!gpiochip_line_is_valid(guard.gc, offset)) { in export_store()
[all …]
Dgpio-tangier.c101 guard(raw_spinlock_irqsave)(&priv->lock); in tng_gpio_set()
115 guard(raw_spinlock_irqsave)(&priv->lock); in tng_gpio_direction_input()
134 guard(raw_spinlock_irqsave)(&priv->lock); in tng_gpio_direction_output()
166 guard(raw_spinlock_irqsave)(&priv->lock); in tng_gpio_set_debounce()
206 guard(raw_spinlock_irqsave)(&priv->lock); in tng_irq_ack()
219 guard(raw_spinlock_irqsave)(&priv->lock); in tng_irq_unmask_mask()
261 guard(raw_spinlock_irqsave)(&priv->lock); in tng_irq_set_type()
317 guard(raw_spinlock_irqsave)(&priv->lock); in tng_irq_set_wake()
470 guard(raw_spinlock_irqsave)(&priv->lock); in tng_gpio_suspend()
493 guard(raw_spinlock_irqsave)(&priv->lock); in tng_gpio_resume()
/linux-6.12.1/arch/parisc/math-emu/
Dcnv_float.h88 #define Dbl_to_sgl_mantissa(srcA,srcB,dest,inexact,guard,sticky,odd) \ argument
90 guard = Dbit3p2(srcB); \
92 inexact = guard | sticky; \
95 #define Dbl_to_sgl_denormalized(srcA,srcB,exp,dest,inexact,guard,sticky,odd,tiny) \ argument
101 guard = inexact >> 31; \
124 if (guard && (sticky || odd)) { \
134 guard = odd; \
136 inexact |= guard; \
144 guard = inexact >> 31; \
157 guard = inexact >> 31; \
[all …]
/linux-6.12.1/sound/core/seq/
Dseq_timer.c81 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_defaults()
112 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_reset()
163 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_set_tempo()
184 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_set_tempo_ppq()
207 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_set_position_tick()
221 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_set_position_time()
238 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_set_skew()
330 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_stop()
381 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_start()
404 guard(spinlock_irqsave)(&tmr->lock); in snd_seq_timer_continue()
[all …]
/linux-6.12.1/drivers/gpu/drm/i915/
Di915_vma_resource.h82 * @guard: The size of guard area preceding and trailing the bind.
129 u32 guard; member
194 * @guard: The size of the guard area preceding and trailing the bind.
214 u32 guard) in i915_vma_resource_init() argument
232 vma_res->guard = guard; in i915_vma_resource_init()
/linux-6.12.1/include/linux/
Dcleanup.h43 * dropped when the scope where guard() is invoked ends::
47 * guard(pci_dev)(dev);
49 * The lifetime of the lock obtained by the guard() helper follows the
56 * guard(pci_dev)(dev); // pci_dev_lock() invoked here
64 * Now, when a function uses both __free() and guard(), or multiple
109 * guard(mutex)(&lock);
123 * That bug is fixed by changing init() to call guard() and define +
126 * guard(mutex)(&lock);
272 * guard(name):
273 * an anonymous instance of the (guard) class, not recommended for
[all …]
Dt10-pi.h14 * Type 1 defines the contents of the guard and reference tags
16 * Type 2 defines the contents of the guard and reference tags and
19 * Type 3 defines the contents of the guard tag only
/linux-6.12.1/Documentation/devicetree/bindings/display/
Datmel,lcdc-display.yaml28 - required: [ 'atmel,guard-time' ]
39 atmel,guard-time:
41 description: lcd guard time (Delay in frame periods)
74 - atmel,guard-time
86 atmel,guard-time = <9>;
/linux-6.12.1/arch/x86/include/asm/
Dcpu_entry_area.h35 /* The exception stacks' physical storage. No guard pages required */
40 /* The effective cpu entry area mapping with guard pages. */
95 * a read-only guard page. On 32-bit the GDT must be writeable, so
96 * it needs an extra guard page.
116 * Exception stacks used for IST entries with guard pages.
/linux-6.12.1/scripts/
Dsyscallnr.sh57 guard=_ASM_$(basename "$outfile" |
62 echo "#ifndef $guard"
63 echo "#define $guard"
73 echo "#endif /* $guard */"
Dgcc-x86_32-has-stack-protector.sh5 # -mstack-protector-guard-reg, added by
8 …| $* -S -x c -m32 -O0 -fstack-protector -mstack-protector-guard-reg=fs -mstack-protector-guard-sym…
Dsyscallhdr.sh68 guard=_UAPI_ASM_$(basename "$outfile" |
73 echo "#ifndef $guard"
74 echo "#define $guard"
97 echo "#endif /* $guard */"
/linux-6.12.1/drivers/media/dvb-frontends/
Dlgs8gxx_priv.h20 u16 curr_gi; /* current guard interval */
42 #define GI_MASK 0x03 /* Guard Interval Mask */
43 #define GI_420 0x00 /* 1/9 Guard Interval */
45 #define GI_945 0x02 /* 1/4 Guard Interval */
/linux-6.12.1/drivers/thermal/testing/
Dzone.c114 guard(tt_zone)(tt_zone); in tt_zone_tz_temp_get()
127 guard(tt_zone)(tt_zone); in tt_zone_tz_temp_set()
180 guard(mutex)(&tt_thermal_zones_lock); in tt_add_tz_work_fn()
230 guard(tt_zone)(tt_zone); in tt_zone_unregister_tz()
253 guard(mutex)(&tt_thermal_zones_lock); in tt_del_tz()
289 guard(mutex)(&tt_thermal_zones_lock); in tt_get_tt_zone()
308 guard(mutex)(&tt_thermal_zones_lock); in tt_put_tt_zone()
363 guard(tt_zone)(tt_zone); in tt_zone_add_trip()
399 guard(tt_zone)(tt_zone); in tt_zone_register_tz()
/linux-6.12.1/drivers/infiniband/sw/rxe/
Drxe_verbs.h82 spinlock_t sq_lock; /* guard queue */
89 spinlock_t producer_lock; /* guard queue producer */
90 spinlock_t consumer_lock; /* guard queue consumer */
252 spinlock_t state_lock; /* guard requester and completer */
367 spinlock_t port_lock; /* guard port */
397 spinlock_t pending_lock; /* guard pending_mmaps */
400 spinlock_t mmap_offset_lock; /* guard mmap_offset */
/linux-6.12.1/drivers/iio/accel/
Dadxl380.c337 guard(mutex)(&st->lock); in adxl380_set_act_inact_threshold()
355 guard(mutex)(&st->lock); in adxl380_set_tap_threshold_value()
400 guard(mutex)(&st->lock); in adxl380_write_tap_time_us()
437 guard(mutex)(&st->lock); in adxl380_read_chn()
513 guard(mutex)(&st->lock); in adxl380_set_odr()
572 guard(mutex)(&st->lock); in adxl380_get_lpf()
590 guard(mutex)(&st->lock); in adxl380_set_lpf()
619 guard(mutex)(&st->lock); in adxl380_get_hpf()
638 guard(mutex)(&st->lock); in adxl380_set_hpf()
693 guard(mutex)(&st->lock); in adxl380_set_act_inact_time_ms()
[all …]
/linux-6.12.1/drivers/iio/
Dinkern.c54 guard(mutex)(&iio_map_list_lock); in iio_map_array_register()
79 guard(mutex)(&iio_map_list_lock); in iio_map_array_unregister()
461 guard(mutex)(&iio_map_list_lock); in iio_channel_get_all()
579 guard(mutex)(&iio_dev_opaque->info_exist_lock); in iio_read_channel_raw()
591 guard(mutex)(&iio_dev_opaque->info_exist_lock); in iio_read_channel_average_raw()
683 guard(mutex)(&iio_dev_opaque->info_exist_lock); in iio_convert_raw_to_processed()
697 guard(mutex)(&iio_dev_opaque->info_exist_lock); in iio_read_channel_attribute()
717 guard(mutex)(&iio_dev_opaque->info_exist_lock); in iio_read_channel_processed_scale()
774 guard(mutex)(&iio_dev_opaque->info_exist_lock); in iio_read_avail_channel_attribute()
847 guard(mutex)(&iio_dev_opaque->info_exist_lock); in iio_read_max_channel_raw()
[all …]

12345678910>>...31