| /linux/drivers/misc/ |
| H A D | sram-exec.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * SRAM protect-exec region helper functions 5 * Copyright (C) 2017 Texas Instruments Incorporated - https://www.ti.com/ 25 unsigned long base = (unsigned long)part->base; in sram_check_protect_exec() 26 unsigned long end = base + block->size; in sram_check_protect_exec() 29 dev_err(sram->dev, in sram_check_protect_exec() 30 "SRAM pool marked with 'protect-exec' is not page aligned and will not be created.\n"); in sram_check_protect_exec() 31 return -ENOMEM; in sram_check_protect_exec() 40 list_add_tail(&part->list, &exec_pool_list); in sram_add_protect_exec() 47 * sram_exec_copy - copy data to a protected executable region of sram [all …]
|
| /linux/drivers/gpu/drm/xe/ |
| H A D | xe_hw_engine_group_types.h | 1 /* SPDX-License-Identifier: MIT */ 14 * enum xe_hw_engine_group_execution_mode - possible execution modes of a hw 17 * @EXEC_MODE_LR: execution in long-running mode 26 * struct xe_hw_engine_group - Hardware engine group 33 * @exec_queue_list: list of exec queues attached to this 37 /** @resume_work: worker to resume faulting LR exec queues */ 39 /** @resume_wq: workqueue to resume faulting LR exec queues */ 42 * @mode_sem: used to protect this group's hardware resources and ensure
|
| H A D | xe_userptr.c | 1 // SPDX-License-Identifier: MIT 16 lockdep_assert(lockdep_is_held_type(&vm->svm.gpusvm.notifier_lock, 0) || in xe_userptr_assert_in_notifier() 17 (lockdep_is_held(&vm->lock) && in xe_userptr_assert_in_notifier() 18 lockdep_is_held_type(&vm->svm.gpusvm.notifier_lock, 1) && in xe_userptr_assert_in_notifier() 23 * xe_vma_userptr_check_repin() - Advisory check for repin needed 28 * without the vm->svm.gpusvm.notifier_lock held. There is no guarantee that the 32 * Return: 0 if userptr vma is valid, -EAGAIN otherwise; repin recommended. 36 return mmu_interval_check_retry(&uvma->userptr.notifier, in xe_vma_userptr_check_repin() 37 uvma->userptr.pages.notifier_seq) ? in xe_vma_userptr_check_repin() 38 -EAGAIN : 0; in xe_vma_userptr_check_repin() [all …]
|
| H A D | xe_tlb_inval_job.c | 1 // SPDX-License-Identifier: MIT 19 /** struct xe_tlb_inval_job - TLB invalidation job */ 25 /** @q: exec queue issuing the invalidate */ 34 * @fence: dma fence to indicate completion. 1 way relationship - job 53 container_of(job->fence, typeof(*ifence), base); in xe_tlb_inval_job_run() 56 if (xe_page_reclaim_list_valid(&job->prl)) { in xe_tlb_inval_job_run() 57 prl_sa = xe_page_reclaim_create_prl_bo(job->tlb_inval, &job->prl, ifence); in xe_tlb_inval_job_run() 62 xe_tlb_inval_range(job->tlb_inval, ifence, job->start, in xe_tlb_inval_job_run() 63 job->end, job->vm->usm.asid, prl_sa); in xe_tlb_inval_job_run() 65 return job->fence; in xe_tlb_inval_job_run() [all …]
|
| /linux/tools/testing/selftests/exec/ |
| H A D | check-exec-tests.sh | 2 # SPDX-License-Identifier: GPL-2.0 7 # samples/check-exec/inc.c 11 set -u -e -o pipefail 14 exec 2>/dev/null 16 DIR="$(dirname $(readlink -f "$0"))" 29 if [[ ${ret} -ne ${expect} ]]; then 33 if [[ ${ret} -eq 0 && "${out}" != "${EXPECTED_OUTPUT}" ]]; then 49 if [[ ${ret} -ne ${expect} ]]; then 53 if [[ ${ret} -eq 0 && "${out}" != "${EXPECTED_OUTPUT}" ]]; then 67 out="$("$@" ./inc -i < "${script}")" || ret=$? [all …]
|
| /linux/Documentation/gpu/ |
| H A D | drm-vm-bind-locking.rst | 1 .. SPDX-License-Identifier: (GPL-2.0+ OR MIT) 30 meta-data. Typically one per client (DRM file-private), or one per 33 associated meta-data. The backing storage of a gpu_vma can either be 34 a GEM object or anonymous or page-cache pages mapped also into the CPU 40 is anonymous or page-cache pages as described above. 43 page-table entries point to that backing store. 47 the :doc:`dma-buf doc </driver-api/dma-buf>`. 53 allows deadlock-safe locking of multiple dma_resvs in arbitrary 55 :doc:`dma-buf doc </driver-api/dma-buf>`. 56 * ``exec function``: An exec function is a function that revalidates all [all …]
|
| /linux/Documentation/userspace-api/ |
| H A D | check_exec.rst | 1 .. SPDX-License-Identifier: GPL-2.0 12 `samples/check-exec/inc.c`_ example. 41 Programs should always perform this check to apply kernel-level checks against 60 To avoid race conditions leading to time-of-check to time-of-use issues, 76 securebits but without relying on any other user-controlled configuration. 103 of any exec securebits: 122 users. That can protect against unintended script executions (e.g. ``sh 123 /tmp/*.sh``). This makes sense for (semi-restricted) user sessions. 131 dm-verity/IPE) but where access rights might not be ready yet. Indeed, 143 .. _samples/check-exec/inc.c: [all …]
|
| /linux/Documentation/devicetree/bindings/arm/omap/ |
| H A D | mpu.txt | 1 * TI - MPU (Main Processor Unit) subsystem 8 - compatible : Should be "ti,omap3-mpu" for OMAP3 9 Should be "ti,omap4-mpu" for OMAP4 10 Should be "ti,omap5-mpu" for OMAP5 11 - ti,hwmods: "mpu" 14 - sram: Phandle to the ocmcram node 17 - pm-sram: Phandles to ocmcram nodes to be used for power management. 18 First should be type 'protect-exec' for the driver to use to copy 25 - For an OMAP5 SMP system: 28 compatible = "ti,omap5-mpu"; [all …]
|
| /linux/Documentation/devicetree/bindings/memory-controllers/ti/ |
| H A D | emif.txt | 3 EMIF - External Memory Interface - is an SDRAM controller used in 11 - compatible : Should be of the form "ti,emif-<ip-rev>" where <ip-rev> 14 "ti,emif-am3352" 15 "ti,emif-am4372" 16 "ti,emif-dra7xx" 17 "ti,emif-keystone" 19 - phy-type : <u32> indicating the DDR phy type. Following are the 24 - device-handle : phandle to a "lpddr2" node representing the memory part 26 - ti,hwmods : For TI hwmods processing and omap device creation 29 - interrupts : interrupt used by the controller [all …]
|
| /linux/kernel/futex/ |
| H A D | pi.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 17 if (likely(current->futex.pi_state_cache)) in refill_pi_state_cache() 23 return -ENOMEM; in refill_pi_state_cache() 25 INIT_LIST_HEAD(&pi_state->list); in refill_pi_state_cache() 27 pi_state->owner = NULL; in refill_pi_state_cache() 28 refcount_set(&pi_state->refcount, 1); in refill_pi_state_cache() 29 pi_state->key = FUTEX_KEY_INIT; in refill_pi_state_cache() 31 current->futex.pi_state_cache = pi_state; in refill_pi_state_cache() 38 struct futex_pi_state *pi_state = current->futex.pi_state_cache; in alloc_pi_state() 41 current->futex.pi_state_cache = NULL; in alloc_pi_state() [all …]
|
| /linux/drivers/gpu/drm/amd/amdgpu/ |
| H A D | amdgpu_gem.c | 33 #include <linux/dma-buf.h> 34 #include <linux/dma-fence-unwrap.h> 71 ret = -EINVAL; in amdgpu_gem_add_input_fence() 103 return -ENOENT; in amdgpu_gem_update_timeline_node() 113 return -ENOMEM; in amdgpu_gem_update_timeline_node() 121 struct ttm_buffer_object *bo = vmf->vma->vm_private_data; in amdgpu_gem_fault() 122 struct drm_device *ddev = bo->base.dev; in amdgpu_gem_fault() 137 ret = ttm_bo_vm_fault_reserved(vmf, vmf->vma->vm_page_prot, in amdgpu_gem_fault() 142 ret = ttm_bo_vm_dummy_page(vmf, vmf->vma->vm_page_prot); in amdgpu_gem_fault() 144 if (ret == VM_FAULT_RETRY && !(vmf->flags & FAULT_FLAG_RETRY_NOWAIT)) in amdgpu_gem_fault() [all …]
|
| H A D | amdgpu_amdkfd_gpuvm.c | 1 // SPDX-License-Identifier: MIT 3 * Copyright 2014-2018 Advanced Micro Devices, Inc. 23 #include <linux/dma-buf.h> 73 #define domain_string(domain) domain_bit_to_string[ffs(domain)-1] 82 list_for_each_entry(entry, &mem->attachments, list) in kfd_mem_is_attached() 83 if (entry->bo_va->base.vm == avm) in kfd_mem_is_attached() 90 * reuse_dmamap() - Check whether adev can share the original 104 return (adev->ram_is_direct_mapped && bo_adev->ram_is_direct_mapped) || in reuse_dmamap() 105 (adev->dev->iommu_group == bo_adev->dev->iommu_group); in reuse_dmamap() 109 * System (TTM + userptr) memory - 15/16th System RAM [all …]
|
| /linux/include/linux/ |
| H A D | rseq.h | 1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */ 14 return IS_ENABLED(CONFIG_GENERIC_IRQ_ENTRY) && likely(t->rseq.event.has_rseq > 1); in rseq_v2() 21 if (current->rseq.event.slowpath) in rseq_handle_slowpath() 24 if (current->rseq.event.sched_switch && current->rseq.event.has_rseq) in rseq_handle_slowpath() 39 if (current->rseq.event.user_irq) in rseq_signal_deliver() 40 __rseq_signal_deliver(ksig->sig, regs); in rseq_signal_deliver() 42 if (current->rseq.event.has_rseq) in rseq_signal_deliver() 43 __rseq_signal_deliver(ksig->sig, regs); in rseq_signal_deliver() 55 struct rseq_event *ev = &t->rseq.event; in rseq_sched_switch_event() 69 * was via interrupt from user space. ev->has_rseq does not have in rseq_sched_switch_event() [all …]
|
| /linux/fs/ |
| H A D | exec.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * linux/fs/exec.c 9 * #!-checking implemented by tytso. 12 * Demand-loading implemented 01.12.91 - no need to read anything but 14 * "current->executable", and page faults do the actual loading. Clean. 17 * was less than 2 hours work to get demand-loading completely implemented. 20 * current->executable is only used by the procfs. This allows a dispatch 83 /* For vma exec functions. */ 96 insert ? list_add(&fmt->lh, &formats) : in __register_binfmt() 97 list_add_tail(&fmt->lh, &formats); in __register_binfmt() [all …]
|
| /linux/tools/testing/selftests/drivers/net/ |
| H A D | stats.py | 2 # SPDX-License-Identifier: GPL-2.0 24 def check_pause(cfg) -> None: 31 ethnl.pause_get({"header": {"dev-index": cfg.ifindex}}) 37 data = ethnl.pause_get({"header": {"dev-index": cfg.ifindex, 42 def check_fec(cfg) -> None: 49 ethnl.fec_get({"header": {"dev-index": cfg.ifindex}}) 55 data = ethnl.fec_get({"header": {"dev-index": cfg.ifindex, 60 def check_fec_hist(cfg) -> Non [all...] |
| /linux/Documentation/filesystems/ |
| H A D | affs.rst | 1 .. SPDX-License-Identifier: GPL-2.0 19 in file names are case-insensitive, as they ought to be. 44 protect 107 Amiga -> Linux: 111 - R maps to r for user, group and others. On directories, R implies x. 113 - W maps to w. 115 - E maps to x. 117 - D is ignored. 119 - H, S and P are always retained and ignored under Linux. 121 - A is cleared when a file is written to. [all …]
|
| /linux/io_uring/ |
| H A D | cancel.c | 1 // SPDX-License-Identifier: GPL-2.0 41 bool match_user_data = cd->flags & IORING_ASYNC_CANCEL_USERDATA; in io_cancel_req_match() 43 if (req->ctx != cd->ctx) in io_cancel_req_match() 46 if (!(cd->flags & (IORING_ASYNC_CANCEL_FD | IORING_ASYNC_CANCEL_OP))) in io_cancel_req_match() 49 if (cd->flags & IORING_ASYNC_CANCEL_ANY) in io_cancel_req_match() 51 if (cd->flags & IORING_ASYNC_CANCEL_FD) { in io_cancel_req_match() 52 if (req->file != cd->file) in io_cancel_req_match() 55 if (cd->flags & IORING_ASYNC_CANCEL_OP) { in io_cancel_req_match() 56 if (req->opcode != cd->opcode) in io_cancel_req_match() 59 if (match_user_data && req->cqe.user_data != cd->data) in io_cancel_req_match() [all …]
|
| /linux/drivers/gpu/drm/panthor/ |
| H A D | panthor_mmu.c | 1 // SPDX-License-Identifier: GPL-2.0 or MIT 19 #include <linux/dma-mapping.h> 23 #include <linux/io-pgtable.h> 47 * struct panthor_as_slot - Address space slot 55 * struct panthor_mmu - MMU related data 68 * us to re-assign them to re-assign slots on-demand. 114 * struct panthor_vm_pool - VM pool object 133 * struct panthor_vma - GPU mapping object 156 * struct panthor_vm_op_ctx - VM operation context 158 * With VM operations potentially taking place in a dma-signaling path, we [all …]
|
| /linux/include/linux/sched/ |
| H A D | signal.h | 1 /* SPDX-License-Identifier: GPL-2.0 */ 13 #include <linux/posix-timers.h> 18 * Types defining task->signal and task->sighand and APIs using them: 29 * Per-process accounting stats: 61 * struct thread_group_cputimer - thread group interval timer counts 103 /* current thread group signal load-balancing target: */ 126 * manager, to re-parent orphan (double-forking) child processes 213 * getrlimit/setrlimit use task_lock(current->group_leader) to 214 * protect this instead of the siglock, because they really 220 struct pacct_struct pacct; /* per-process accounting information */ [all …]
|
| /linux/drivers/net/ethernet/mellanox/mlx5/core/lib/ |
| H A D | crypto.c | 1 // SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB 7 #define MLX5_CRYPTO_DEK_POOLS_NUM (MLX5_ACCEL_OBJ_TYPE_KEY_NUM - 1) 8 #define type2idx(type) ((type) - 1) 17 _a->num_deks - _a->avail_deks - _a->in_use_deks; }) 24 _bulk->avail_deks == _bulk->num_deks; }) 36 struct mutex lock; /* protect the following lists, and the bulks */ 41 /* No in-used keys, and all need to be synced. 50 spinlock_t destroy_lock; /* protect destroy_list */ 87 return dek->obj_id; in mlx5_crypto_dek_get_id() 105 return -EINVAL; in mlx5_crypto_dek_get_key_sz() [all …]
|
| /linux/fs/nfs/ |
| H A D | internal.h | 1 /* SPDX-License-Identifier: GPL-2.0 */ 25 if (!nfs_fsid_equal(&NFS_SB(parent)->fsid, &fattr->fsid)) in nfs_attr_check_mountpoint() 26 fattr->valid |= NFS_ATTR_FATTR_MOUNTPOINT; in nfs_attr_check_mountpoint() 31 if (((fattr->valid & NFS_ATTR_FATTR_MOUNTED_ON_FILEID) == 0) || in nfs_attr_use_mounted_on_fileid() 32 (((fattr->valid & NFS_ATTR_FATTR_MOUNTPOINT) == 0) && in nfs_attr_use_mounted_on_fileid() 33 ((fattr->valid & NFS_ATTR_FATTR_V4_REFERRAL) == 0))) in nfs_attr_use_mounted_on_fileid() 40 if (!(NFS_SB(dentry->d_sb)->flags & NFS_MOUNT_SOFTREVAL)) in nfs_lookup_is_soft_revalidate() 42 if (!d_is_positive(dentry) || !NFS_FH(d_inode(dentry))->size) in nfs_lookup_is_soft_revalidate() 66 #define NFS_UNSPEC_PORT (-1) 92 * In-kernel mount arguments [all …]
|
| /linux/include/linux/mtd/ |
| H A D | rawnand.h | 1 /* SPDX-License-Identifier: GPL-2.0-only */ 3 * Copyright © 2000-2010 David Woodhouse <dwmw2@infradead.org> 75 #define NAND_CMD_NONE -1 84 #define NAND_DATA_IFACE_CHECK_ONLY -1 98 * ecc.correct() returns -EBADMSG. 124 * Chip requires ready check on read (for auto-incremented sequential read). 142 #define NAND_HAS_SUBPAGE_READ(chip) ((chip->options & NAND_SUBPAGE_READ)) 168 * This option could be defined by controller drivers to protect against 174 * In case your controller is implementing ->legacy.cmd_ctrl() and is relying 175 * on the default ->cmdfunc() implementation, you may want to let the core [all …]
|
| /linux/arch/arm/boot/dts/ti/omap/ |
| H A D | am33xx.dtsi | 1 // SPDX-License-Identifier: GPL-2.0-only 5 * Copyright (C) 2012 Texas Instruments Incorporated - https://www.ti.com/ 8 #include <dt-bindings/bus/ti-sysc.h> 9 #include <dt-bindings/gpio/gpio.h> 10 #include <dt-bindings/pinctrl/am33xx.h> 11 #include <dt-bindings/clock/am3.h> 15 interrupt-parent = <&intc>; 16 #address-cells = <1>; 17 #size-cells = <1>; 30 d-can0 = &dcan0; [all …]
|
| /linux/mm/ |
| H A D | rmap.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * mm/rmap.c - physical to virtual reverse mappings 23 * inode->i_rwsem (while writing or truncating, not reading or faulting) 24 * mm->mmap_lock 25 * mapping->invalidate_lock (in filemap_fault) 29 * mapping->i_mmap_rwsem 30 * anon_vma->rwsem 31 * mm->page_table_loc [all...] |
| /linux/arch/arm64/kernel/ |
| H A D | fpsimd.c | 1 // SPDX-License-Identifier: GPL-2.0-only 70 * we add the per-cpu variable 'fpsimd_last_state' (below), which contains the 86 * loaded on the CPU, allowing the state to be saved if a FPSIMD-aware 94 * is necessary to protect any manipulation of a task's fpsimd_state or 99 * - the task gets scheduled in; if both the task's fpsimd_cpu field 100 * contains the id of the current CPU, and the CPU's fpsimd_last_state per-cpu 104 * - the task returns to userland; if TIF_FOREIGN_FPSTATE is set, the task's 110 * - the task executes an ordinary syscall; upon return to userland, the 114 * - the task executes a syscall which executes some NEON instructions; this is 116 * register contents to memory, clears the fpsimd_last_state per-cpu variable [all …]
|