/linux/tools/testing/selftests/vm/ |
A D | hugepage-shm.c | 59 char *shmaddr; in main() local 68 shmaddr = shmat(shmid, ADDR, SHMAT_FLAGS); in main() 69 if (shmaddr == (char *)-1) { in main() 74 printf("shmaddr: %p\n", shmaddr); in main() 78 shmaddr[i] = (char)(i); in main() 86 if (shmaddr[i] != (char)i) { in main() 92 if (shmdt((const void *)shmaddr) != 0) { in main()
|
A D | write_to_hugetlbfs.c | 31 static char *shmaddr; variable 51 if (shmdt((const void *)shmaddr) != 0) { in sig_handler()
|
/linux/tools/testing/selftests/powerpc/benchmarks/ |
A D | context_switch.c | 329 void *shmaddr; in futex_setup() local 337 shmaddr = shmat(shmid, NULL, 0); in futex_setup() 338 if (shmaddr == (char *)-1) { in futex_setup() 346 m1 = shmaddr; in futex_setup() 347 m2 = shmaddr + sizeof(*m1); in futex_setup()
|
/linux/Documentation/sparc/ |
A D | adi.rst | 187 char *shmaddr, *tmp_addr, *end, *veraddr, *clraddr; 219 shmaddr = shmat(shmid, NULL, 0); 220 if (shmaddr == (char *)-1) { 226 if (mprotect(shmaddr, BUFFER_SIZE, PROT_READ|PROT_WRITE|PROT_ADI)) { 234 tmp_addr = shmaddr; 235 end = shmaddr + BUFFER_SIZE; 248 tmp_addr = (void *) ((unsigned long)shmaddr << adi_nbits); 270 if (mprotect(shmaddr, BUFFER_SIZE, PROT_READ|PROT_WRITE)) { 275 if (shmdt((const void *)shmaddr) != 0) 282 if (shmdt((const void *)shmaddr) != 0)
|
/linux/include/linux/ |
A D | shm.h | 17 long do_shmat(int shmid, char __user *shmaddr, int shmflg, unsigned long *addr, 27 static inline long do_shmat(int shmid, char __user *shmaddr, in do_shmat() argument
|
A D | syscalls.h | 838 asmlinkage long sys_shmat(int shmid, char __user *shmaddr, int shmflg); 839 asmlinkage long sys_shmdt(char __user *shmaddr); 1376 long ksys_shmdt(char __user *shmaddr);
|
A D | security.h | 454 int security_shm_shmat(struct kern_ipc_perm *shp, char __user *shmaddr, int shmflg); 1266 char __user *shmaddr, int shmflg) in security_shm_shmat() argument
|
A D | lsm_hook_defs.h | 247 LSM_HOOK(int, 0, shm_shmat, struct kern_ipc_perm *perm, char __user *shmaddr,
|
A D | compat.h | 776 asmlinkage long compat_sys_shmat(int shmid, compat_uptr_t shmaddr, int shmflg);
|
/linux/arch/xtensa/kernel/ |
A D | syscall.c | 39 asmlinkage long xtensa_shmat(int shmid, char __user *shmaddr, int shmflg) in xtensa_shmat() argument 44 err = do_shmat(shmid, shmaddr, shmflg, &ret, SHMLBA); in xtensa_shmat()
|
/linux/ipc/ |
A D | shm.c | 1506 long do_shmat(int shmid, char __user *shmaddr, int shmflg, in do_shmat() argument 1510 unsigned long addr = (unsigned long)shmaddr; in do_shmat() 1579 err = security_shm_shmat(&shp->shm_perm, shmaddr, shmflg); in do_shmat() 1680 SYSCALL_DEFINE3(shmat, int, shmid, char __user *, shmaddr, int, shmflg) in SYSCALL_DEFINE3() argument 1685 err = do_shmat(shmid, shmaddr, shmflg, &ret, SHMLBA); in SYSCALL_DEFINE3() 1698 COMPAT_SYSCALL_DEFINE3(shmat, int, shmid, compat_uptr_t, shmaddr, int, shmflg) in COMPAT_SYSCALL_DEFINE3() argument 1703 err = do_shmat(shmid, compat_ptr(shmaddr), shmflg, &ret, COMPAT_SHMLBA); in COMPAT_SYSCALL_DEFINE3() 1715 long ksys_shmdt(char __user *shmaddr) in ksys_shmdt() argument 1719 unsigned long addr = (unsigned long)shmaddr; in ksys_shmdt() 1822 SYSCALL_DEFINE1(shmdt, char __user *, shmaddr) in SYSCALL_DEFINE1() argument [all …]
|
/linux/Documentation/ia64/ |
A D | err_inject.rst | 305 void *shmaddr; 336 shmaddr = shmat(shmid, (void *)SHM_VA, 0); 337 if (shmaddr == (void*)-1) { 342 memset(shmaddr, 0, SHM_SIZE); 343 mlock(shmaddr, SHM_SIZE); 350 munlock(shmaddr, SHM_SIZE); 351 shmdt(shmaddr); 865 va1=shmaddr+parameters[i].cpu*PAGE_SIZE; 866 va2=shmaddr+parameters[i].cpu*PAGE_SIZE+PAGE_SIZE;
|
/linux/security/ |
A D | security.c | 1996 int security_shm_shmat(struct kern_ipc_perm *shp, char __user *shmaddr, int shmflg) in security_shm_shmat() argument 1998 return call_int_hook(shm_shmat, 0, shp, shmaddr, shmflg); in security_shm_shmat()
|
/linux/security/smack/ |
A D | smack_lsm.c | 3014 static int smack_shm_shmat(struct kern_ipc_perm *isp, char __user *shmaddr, in smack_shm_shmat() argument
|
/linux/security/selinux/ |
A D | hooks.c | 6259 char __user *shmaddr, int shmflg) in selinux_shm_shmat() argument
|