/kernel/liteos_a/testsuites/unittest/basic/mem/vm/smoke/ |
D | mprotect_test_001.cpp | 36 int pageSize; in Testcase() local 39 pageSize = getpagesize(); in Testcase() 41 ret = mprotect(0, pageSize, PROT_NONE); in Testcase() 45 ret = mprotect(0, pageSize, 0xffff); in Testcase() 49 ret = mprotect((void *)0x1000, pageSize, PROT_READ | PROT_WRITE); in Testcase() 53 ret = mprotect((void *)0xffffff, pageSize, PROT_READ | PROT_WRITE); in Testcase() 57 p = (char *)mmap(NULL, pageSize * 3, PROT_READ, MAP_ANONYMOUS | MAP_PRIVATE, -1, 0); in Testcase() 60 ret = mprotect(p, pageSize * 4, PROT_READ | PROT_WRITE); in Testcase() 64 ret = mprotect(p, pageSize, PROT_READ | PROT_WRITE); in Testcase() 66 (void)memset_s(p, pageSize, 0xf, pageSize); in Testcase() [all …]
|
D | mmap_test_003.cpp | 40 int fd, pageSize; in Testcase() local 43 pageSize = getpagesize(); in Testcase() 47 p1 = (char *)mmap(NULL, pageSize, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in Testcase() 49 (void)memset_s(p1, pageSize, 0, pageSize); in Testcase() 51 p2 = (char *)mmap(NULL, pageSize, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in Testcase() 53 (void)memset_s(p2, pageSize, 0, pageSize); in Testcase() 55 ret = memcmp(p1, p2, pageSize); in Testcase() 64 p3 = (char *)mmap(NULL, pageSize, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in Testcase() 68 ret = munmap(p1, pageSize); in Testcase() 70 ret = munmap(p2, pageSize); in Testcase() [all …]
|
D | mmap_test_004.cpp | 40 int fd, pageSize; in Testcase() local 43 pageSize = getpagesize(); in Testcase() 47 p1 = (char *)mmap(NULL, pageSize, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); in Testcase() 49 (void)memset_s(p1, pageSize, 0, pageSize); in Testcase() 51 p2 = (char *)mmap(NULL, pageSize, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); in Testcase() 53 (void)memset_s(p2, pageSize, 0, pageSize); in Testcase() 55 ret = memcmp(p1, p2, pageSize); in Testcase() 64 p3 = (char *)mmap(NULL, pageSize, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); in Testcase() 68 ret = munmap(p1, pageSize); in Testcase() 70 ret = munmap(p2, pageSize); in Testcase() [all …]
|
D | mmap_test_002.cpp | 38 int pageSize = getpagesize(); in CheckedMmap() local 41 if (pageSize < 0) { in CheckedMmap() 45 p = mmap(NULL, pageSize, prot, flags, fd, 0); in CheckedMmap() 49 ret = munmap(p, pageSize); in CheckedMmap() 60 int pageSize = getpagesize(); in Testcase() local 66 if (pageSize <= 0) { in Testcase() 70 if (pageSize <= 0) { in Testcase() 74 buf = static_cast<char *>(malloc(pageSize)); in Testcase() 76 (void)memset_s(buf, pageSize, 0xf, pageSize); in Testcase() 78 count = write(shmfd, buf, pageSize); in Testcase() [all …]
|
D | mremap_test_001.cpp | 37 int pageSize; in Testcase() local 41 pageSize = getpagesize(); in Testcase() 42 size = pageSize << 1; in Testcase() 57 newAddr = mremap(p, size, pageSize, MREMAP_MAYMOVE, 0); in Testcase() 61 newAddr = mremap(p, pageSize, pageSize, MREMAP_MAYMOVE, 0); in Testcase() 65 newAddr = mremap(p, pageSize, size, MREMAP_MAYMOVE, 0); in Testcase() 69 newAddr = mremap(p, size, pageSize, MREMAP_MAYMOVE | MREMAP_FIXED, p + pageSize); in Testcase() 73 newAddr = mremap(p, size, size, MREMAP_MAYMOVE | MREMAP_FIXED, p - pageSize); in Testcase() 77 newAddr = mremap(p, size, size + pageSize, MREMAP_MAYMOVE | MREMAP_FIXED, p - pageSize); in Testcase()
|
/kernel/liteos_a/testsuites/unittest/basic/mem/shm/full/ |
D | shm_test_013.cpp | 39 int pageSize = getpagesize(); in testcase() local 46 writebuf = static_cast<char *>(malloc(pageSize)); in testcase() 48 readbuf = static_cast<char *>(malloc(pageSize)); in testcase() 51 (void)memset_s(writebuf, pageSize, 0xf, pageSize); in testcase() 53 count = write(shmfd, writebuf, pageSize); in testcase() 54 ICUNIT_GOTO_EQUAL(count, pageSize, count, EXIT); in testcase() 58 count = read(shmfd, readbuf, pageSize); in testcase() 59 ICUNIT_GOTO_EQUAL(count, pageSize, count, EXIT); in testcase()
|
D | shm_test_014.cpp | 41 int pageSize = getpagesize(); in testcase() local 52 writebuf = static_cast<char *>(malloc(pageSize)); in testcase() 54 readbuf = static_cast<char *>(malloc(pageSize)); in testcase() 56 (void)memset_s(writebuf, pageSize, 0xf, pageSize); in testcase() 60 count = write(shmfd, writebuf, pageSize); in testcase() 71 count = write(shmfd, writebuf, pageSize); in testcase() 72 ICUNIT_ASSERT_EQUAL(count, pageSize, count); in testcase() 75 count = read(shmfd, readbuf, pageSize); in testcase()
|
/kernel/linux/patches/linux-5.10/imx8mm_patch/patches/drivers/ |
D | 0038_linux_drivers_mxc.patch | 46863 + gctUINT32 pageSize = Hardware->kernel->command->pageSize; 46894 + resume & (pageSize - 1), 54118 + gctSIZE_T pageSize = 0; 54119 + gckOS_GetPageSize(Kernel->os, &pageSize); 54124 + bytes = gcmALIGN(bytes, pageSize); 58939 + gctSIZE_T pageSize; 58944 + gcmkVERIFY_OK(gckOS_GetPageSize(Kernel->os, &pageSize)); 58946 + pageMask = (gctUINT32)pageSize - 1; 59750 + gctUINT32 pageSize; 62833 + gctSIZE_T pageSize; [all …]
|