Home
last modified time | relevance | path

Searched +full:lock +full:- +full:offset (Results 1 – 25 of 1043) sorted by relevance

12345678910>>...42

/freebsd/contrib/llvm-project/compiler-rt/lib/tsan/rtl/
H A Dtsan_interceptors_mac.cpp1 //===-- tsan_interceptors_mac.cpp -----------------------------------------===//
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
11 // Mac-specific interceptors.
12 //===----------------------------------------------------------------------===//
26 #include <objc/objc-sync.h>
27 #include <os/lock.h>
43 // The non-barrier versions of OSAtomic* functions are semantically mo_relaxed,
47 // conservative and treat the non-barrier versions as mo_acq_rel.
74 return tsan_atomic_f((volatile tsan_t *)ptr, 1, mo) - 1; \
[all …]
/freebsd/sys/ufs/ufs/
H A Dufs_dirhash.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
29 * This implements a hash-based lookup scheme for UFS directories.
40 #include <sys/lock.h>
65 #define WRAPDECR(val, limit) (((val) == 0) ? ((limit) - 1) : ((val) - 1))
95 static void ufsdirhash_adjfree(struct dirhash *dh, doff_t offset, int diff);
98 doff_t offset);
99 static doff_t ufsdirhash_getprev(struct direct *dp, doff_t offset);
111 sx_assert(&(dh)->dh_lock, SA_LOCKED)
113 /* Dirhash list; recently-used entries are near the tail. */
[all …]
/freebsd/lib/libsys/
H A Dlockf.345 function allows sections of a file to be locked with advisory-mode locks.
48 from other processes which attempt to lock the locked file section will
55 The file descriptor must have been opened either for write-only
67 .Bl -tag -width F_ULOCKXX -compact -offset indent
73 lock a section for exclusive use
75 test and lock a section for exclusive use
85 both lock a section of a file if the section is available;
87 detects if a lock by another process is present on the specified section.
94 offset in the file and extends forward for a positive size or backward
96 current offset).
[all …]
H A Dfcntl.258 .Bl -tag -width F_DUP2FD_CLOEXEC
62 .Bl -bullet -compact -offset 4n
69 New descriptor shares the same file offset if the object
77 The close-on-exec flag
95 .Bd -literal -offset indent
116 Get the close-on-exec flag associated with the file descriptor
130 Set the close-on-exec flag associated with
180 is non-zero.
214 .Bl -tag -width O_NONBLOCKX
216 Non-blocking I/O; if no data is available to a
[all …]
/freebsd/sys/dev/nvmf/controller/
H A Dnvmft_controller.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
4 * Copyright (c) 2023-2024 Chelsio Communications, Inc.
11 #include <sys/lock.h>
38 sbuf_printf(&sb, "nvmft%u: ", ctrlr->cntlid); in nvmft_printf()
57 ctrlr->cntlid = cntlid; in nvmft_controller_alloc()
59 TAILQ_INSERT_TAIL(&np->controllers, ctrlr, link); in nvmft_controller_alloc()
60 ctrlr->np = np; in nvmft_controller_alloc()
61 mtx_init(&ctrlr->lock, "nvmft controller", NULL, MTX_DEF); in nvmft_controller_alloc()
62 callout_init(&ctrlr->ka_timer, 1); in nvmft_controller_alloc()
[all …]
/freebsd/share/man/man9/
H A DVOP_LOCK.91 .\" -*- nroff -*-
56 .Bl -tag -width flags
60 One of the lock request types:
62 .Bl -tag -width ".Dv LK_CANRECURSE" -offset indent -compact
64 Shared lock.
66 Exclusive lock.
68 Shared-to-exclusive upgrade.
70 Exclusive-to-shared downgrade.
72 Release any type of lock.
74 Wait for all lock activity to end.
[all …]
/freebsd/sys/contrib/openzfs/module/zfs/
H A Dzfs_rlock.c9 * or https://opensource.org/licenses/CDDL-1.0.
35 * ---------
42 * --------------------
45 * freed etc and zp_size reset. zp_size must be set within range lock.
50 * to ensure the file size is at least the offset last written.
56 * --------
59 * The starting range offset is used for searching and sorting the tree.
62 * -----------
69 * ---------------------------------------
70 * The avl code only allows one node at a particular offset. Also it's very
[all …]
/freebsd/usr.bin/lockf/
H A Dlockf.130 .Nd execute a command while holding a file lock
45 utility acquires an exclusive lock on a
51 While holding the lock, it executes a
59 releases the lock, and removes the
64 .Bx Ns -style
69 is not considered to constitute a lock.
90 This can be used to lock inside a shell script.
98 This will guarantee lock ordering, as well as implement
100 with concurrent unlink, drop and re-acquire activity.
104 option is not used, then no guarantees around lock ordering can be made.
[all …]
/freebsd/sys/geom/bde/
H A Dg_bde_crypt.c
/freebsd/contrib/llvm-project/lldb/source/Expression/
H A DIRMemoryMap.cpp1 //===-- IRMemoryMap.cpp ---------------------------------------------------===//
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
25 m_process_wp = target_sp->GetProcessSP(); in IRMemoryMap()
29 lldb::ProcessSP process_sp = m_process_wp.lock(); in ~IRMemoryMap()
38 if (iter->second.m_leak) in ~IRMemoryMap()
41 Free(iter->first, err); in ~IRMemoryMap()
59 lldb::TargetSP target_sp = m_target_wp.lock(); in FindSpace()
60 lldb::ProcessSP process_sp = m_process_wp.lock(); in FindSpace()
62 const bool process_is_alive = process_sp && process_sp->IsAlive(); in FindSpace()
[all …]
/freebsd/contrib/ofed/libmlx5/
H A Dmlx5.h14 * - Redistributions of source code must retain the above
18 * - Redistributions in binary form must reproduce the above
45 #include "mlx5-abi.h"
112 MLX5_QP_TABLE_MASK = (1 << MLX5_QP_TABLE_SHIFT) - 1,
113 MLX5_QP_TABLE_SIZE = 1 << (24 - MLX5_QP_TABLE_SHIFT),
118 MLX5_UIDX_TABLE_MASK = (1 << MLX5_UIDX_TABLE_SHIFT) - 1,
119 MLX5_UIDX_TABLE_SIZE = 1 << (24 - MLX5_UIDX_TABLE_SHIFT),
124 MLX5_SRQ_TABLE_MASK = (1 << MLX5_SRQ_TABLE_SHIFT) - 1,
125 MLX5_SRQ_TABLE_SIZE = 1 << (24 - MLX5_SRQ_TABLE_SHIFT),
203 pthread_spinlock_t lock; member
[all …]
/freebsd/sys/dev/mlx4/mlx4_core/
H A Dmlx4_alloc.c15 * - Redistributions of source code must retain the above
19 * - Redistributions in binary form must reproduce the above
38 #include <linux/dma-mapping.h>
47 spin_lock(&bitmap->lock); in mlx4_bitmap_alloc()
49 obj = find_next_zero_bit(bitmap->table, bitmap->max, bitmap->last); in mlx4_bitmap_alloc()
50 if (obj >= bitmap->max) { in mlx4_bitmap_alloc()
51 bitmap->top = (bitmap->top + bitmap->max + bitmap->reserved_top) in mlx4_bitmap_alloc()
52 & bitmap->mask; in mlx4_bitmap_alloc()
53 obj = find_first_zero_bit(bitmap->table, bitmap->max); in mlx4_bitmap_alloc()
56 if (obj < bitmap->max) { in mlx4_bitmap_alloc()
[all …]
/freebsd/sys/dev/clk/allwinner/
H A Dccu_a64.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
47 #include <dt-bindings/clock/sun50i-a64-ccu.h>
48 #include <dt-bindings/reset/sun50i-a64-ccu.h>
50 /* Non-exported clocks */
141 CCU_GATE(CLK_BUS_MIPI_DSI, "bus-mipi-dsi", "ahb1", 0x60, 1)
142 CCU_GATE(CLK_BUS_CE, "bus-ce", "ahb1", 0x60, 5)
143 CCU_GATE(CLK_BUS_DMA, "bus-dma", "ahb1", 0x60, 6)
144 CCU_GATE(CLK_BUS_MMC0, "bus-mmc0", "ahb1", 0x60, 8)
145 CCU_GATE(CLK_BUS_MMC1, "bus-mmc1", "ahb1", 0x60, 9)
[all …]
H A Dccu_a31.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
47 #include <dt-bindings/clock/sun6i-a31-ccu.h>
48 #include <dt-bindings/reset/sun6i-a31-ccu.h>
50 /* Non-exported clocks */
148 CCU_GATE(CLK_AHB1_MIPIDSI, "ahb1-mipidsi", "ahb1", 0x60, 1)
149 CCU_GATE(CLK_AHB1_SS, "ahb1-ss", "ahb1", 0x60, 5)
150 CCU_GATE(CLK_AHB1_DMA, "ahb1-dma", "ahb1", 0x60, 6)
151 CCU_GATE(CLK_AHB1_MMC0, "ahb1-mmc0", "ahb1", 0x60, 8)
152 CCU_GATE(CLK_AHB1_MMC1, "ahb1-mmc1", "ahb1", 0x60, 9)
[all …]
H A Dccu_h6.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
47 #include <dt-bindings/clock/sun50i-h6-ccu.h>
48 #include <dt-bindings/reset/sun50i-h6-ccu.h>
50 /* Non-exported clocks */
117 CCU_GATE(CLK_BUS_PSI, "bus-psi", "psi_ahb1_ahb2", 0x79c, 0)
120 CCU_GATE(CLK_BUS_MMC0, "bus-mmc0", "ahb3", 0x84c, 0)
121 CCU_GATE(CLK_BUS_MMC1, "bus-mmc1", "ahb3", 0x84c, 1)
122 CCU_GATE(CLK_BUS_MMC2, "bus-mmc2", "ahb3", 0x84c, 2)
125 /* CCU_GATE(CLK_BUS_UART0, "bus-uart0", "apb2", 0x90c, 0) */
[all …]
/freebsd/crypto/openssl/crypto/asn1/
H A Dtasn_utl.c2 * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
22 /* Add 'offset' to 'addr' */
23 #define offset2ptr(addr, offset) (void *)(((char *) addr) + offset) argument
31 int *sel = offset2ptr(*pval, it->utype); in ossl_asn1_get_choice_selector()
39 int *sel = offset2ptr(*pval, it->utype); in ossl_asn1_get_choice_selector_const()
53 sel = offset2ptr(*pval, it->utype); in ossl_asn1_set_choice_selector()
62 * If |op| is 0, lock is initialised and count is set to 1.
63 * If |op| is -1, count is decremented and the return value is the current
65 * It returns -1 on initialisation error.
72 CRYPTO_RWLOCK **lock; in ossl_asn1_do_lock() local
[all …]
/freebsd/sys/vm/
H A Dvm_object.h1 /*-
2 * SPDX-License-Identifier: (BSD-3-Clause AND MIT-CMU)
8 * The Mach Operating System project at Carnegie-Mellon University.
35 * Copyright (c) 1987, 1990 Carnegie-Mellon University.
55 * Pittsburgh PA 15213-3890
86 * (o) per-object lock
97 struct rwlock lock; member
117 vm_ooffset_t backing_object_offset;/* Offset in backing object */
125 * vnp_size - current size of file
135 * devp_pglist - list of allocated pages
[all …]
/freebsd/sys/dev/ocs_fc/
H A Docs_os.h1 /*-
54 #include <sys/lock.h>
81 /* OCS_OS_MAX_ISR_TIME_MSEC - maximum time driver code should spend in an interrupt
112 #define B32_NEXT_POWER_OF_2(x) (B32((x)-1) + 1)
115 * likely/unlikely - branch prediction hint
138 * - OCS_INCLUDE_DEBUG include low-level SLI debug support
170 * @brief return the lower 32-bits of a bus address
173 * @return lower 32-bits of a bus address
188 * @brief return the upper 32-bits of a bus address
191 * @return upper 32-bits of a bus address
[all …]
/freebsd/sys/dev/qlnx/qlnxe/
H A Decore_hw.c2 * Copyright (c) 2017-2018 Cavium, Inc.
56 #define ECORE_BAR_INVALID_OFFSET (OSAL_CPU_TO_LE32(-1))
67 osal_spinlock_t lock; /* ptt synchronized access */ member
73 OSAL_FREE(p_hwfn->p_dev, p_hwfn->p_ptt_pool); in __ecore_ptt_pool_free()
74 p_hwfn->p_ptt_pool = OSAL_NULL; in __ecore_ptt_pool_free()
79 struct ecore_ptt_pool *p_pool = OSAL_ALLOC(p_hwfn->p_dev, in ecore_ptt_pool_alloc()
87 OSAL_LIST_INIT(&p_pool->free_list); in ecore_ptt_pool_alloc()
89 p_pool->ptts[i].idx = i; in ecore_ptt_pool_alloc()
90 p_pool->ptts[i].pxp.offset = ECORE_BAR_INVALID_OFFSET; in ecore_ptt_pool_alloc()
91 p_pool->ptts[i].pxp.pretend.control = 0; in ecore_ptt_pool_alloc()
[all …]
/freebsd/sys/dev/qat/qat_common/
H A Dadf_freebsd_uio.c1 /* SPDX-License-Identifier: BSD-3-Clause */
2 /* Copyright(c) 2007-2022 Intel Corporation */
24 #include <sys/lock.h>
32 #define ADF_UIO_GET_NAME(accel_dev) (GET_HW_DATA(accel_dev)->dev_class->name)
33 #define ADF_UIO_GET_TYPE(accel_dev) (GET_HW_DATA(accel_dev)->dev_class->type)
35 (GET_HW_DATA(accel_dev)->get_etr_bar_id(GET_HW_DATA(accel_dev)))
62 accel = handle->accel; in adf_release_bundle()
63 bundle = &accel->bundle[handle->bundle]; in adf_release_bundle()
65 mutex_lock(&bundle->lock); in adf_release_bundle()
66 adf_uio_do_cleanup_orphan(bundle->hardware_bundle_number, accel); in adf_release_bundle()
[all …]
/freebsd/sys/contrib/device-tree/Bindings/c6x/
H A Ddscr.txt2 ------------------------------------
9 more configuration registers often protected by a lock register where one or
10 more key values must be written to a lock register in order to unlock the
24 - compatible: must be "ti,c64x+dscr"
25 - reg: register area base and size
34 - ti,dscr-devstat
35 offset of the devstat register
37 - ti,dscr-silicon-rev
38 offset, start bit, and bitsize of silicon revision field
40 - ti,dscr-rmii-resets
[all …]
/freebsd/contrib/processor-trace/libipt/src/
H A Dpt_section.c2 * Copyright (c) 2013-2019, Intel Corporation
33 #include "intel-pt.h"
41 uint64_t offset, uint64_t size) in pt_mk_section() argument
51 return -pte_internal; in pt_mk_section()
55 return -pte_invalid; in pt_mk_section()
61 return -pte_nomem; in pt_mk_section()
69 /* Fail if the requested @offset lies beyond the end of @file. */ in pt_mk_section()
70 if (fsize <= offset) { in pt_mk_section()
71 errcode = -pte_invalid; in pt_mk_section()
76 fsize -= offset; in pt_mk_section()
[all …]
H A Dpt_section_file.c2 * Copyright (c) 2013-2019, Intel Corporation
32 #include "intel-pt.h"
41 return -pte_internal; in fmap_init()
49 errcode = mtx_init(&mapping->lock, mtx_plain); in fmap_init()
51 return -pte_bad_lock; in fmap_init()
63 fclose(mapping->file); in fmap_fini()
67 mtx_destroy(&mapping->lock); in fmap_fini()
75 return -pte_internal; in fmap_lock()
81 errcode = mtx_lock(&mapping->lock); in fmap_lock()
83 return -pte_bad_lock; in fmap_lock()
[all …]
/freebsd/sys/dev/cxgbe/iw_cxgbe/
H A Dev.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
4 * Copyright (c) 2009-2013 Chelsio, Inc. All rights reserved.
16 * - Redistributions of source code must retain the above
20 * - Redistributions in binary form must reproduce the above
50 G_FW_RI_TPTE_VALID(ntohl(tpte->valid_to_pdid)), in print_tpte()
51 G_FW_RI_TPTE_STAGKEY(ntohl(tpte->valid_to_pdid)), in print_tpte()
52 G_FW_RI_TPTE_STAGSTATE(ntohl(tpte->valid_to_pdid)), in print_tpte()
53 G_FW_RI_TPTE_PDID(ntohl(tpte->valid_to_pdid)), in print_tpte()
54 G_FW_RI_TPTE_PERM(ntohl(tpte->locread_to_qpid)), in print_tpte()
[all …]
/freebsd/sys/dev/sound/pci/
H A Dhdsp-pcm.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
4 * Copyright (c) 2012-2021 Ruslan Bukin <br@bsdpad.com>
5 * Copyright (c) 2023-2024 Florian Walpen <dev@submerge.ch>
31 * RME HDSP driver for FreeBSD (pcm-part).
130 return (slots & (~(slots - 1))); /* Extract first bit set. */ in hdsp_slot_first()
141 return (slots & (ends ^ (ends - 1))); in hdsp_slot_first_row()
150 --n; in hdsp_slot_first_n()
166 return (hdsp_slot_count(hdsp_slot_first(slots) - 1)); in hdsp_slot_offset()
177 preceding = slots & (hdsp_slot_first(subset) - 1); in hdsp_slot_channel_offset()
[all …]

12345678910>>...42