/kernel/linux/linux-6.6/io_uring/ |
H A D | openclose.c | 34 static bool io_openat_force_async(struct io_open *open) in io_openat_force_async() argument 37 * Don't bother trying for O_TRUNC, O_CREAT, or O_TMPFILE open, in io_openat_force_async() 42 return open->how.flags & (O_TRUNC | O_CREAT | __O_TMPFILE); in io_openat_force_async() 47 struct io_open *open = io_kiocb_to_cmd(req, struct io_open); in __io_openat_prep() local 56 /* open.how should be already initialised */ in __io_openat_prep() 57 if (!(open->how.flags & O_PATH) && force_o_largefile()) in __io_openat_prep() 58 open->how.flags |= O_LARGEFILE; in __io_openat_prep() 60 open->dfd = READ_ONCE(sqe->fd); in __io_openat_prep() 62 open->filename = getname(fname); in __io_openat_prep() 63 if (IS_ERR(open in __io_openat_prep() 82 struct io_open *open = io_kiocb_to_cmd(req, struct io_open); io_openat_prep() local 92 struct io_open *open = io_kiocb_to_cmd(req, struct io_open); io_openat2_prep() local 111 struct io_open *open = io_kiocb_to_cmd(req, struct io_open); io_openat2() local 177 struct io_open *open = io_kiocb_to_cmd(req, struct io_open); io_open_cleanup() local [all...] |
/kernel/linux/linux-5.10/sound/isa/sb/ |
H A D | sb8_midi.c | 41 if (chip->open & SB_OPEN_MIDI_INPUT_TRIGGER) { in snd_sb8dsp_midi_interrupt() 60 if (chip->open & ~valid_open_flags) { in snd_sb8dsp_midi_input_open() 64 chip->open |= SB_OPEN_MIDI_INPUT; in snd_sb8dsp_midi_input_open() 66 if (!(chip->open & SB_OPEN_MIDI_OUTPUT)) { in snd_sb8dsp_midi_input_open() 87 if (chip->open & ~valid_open_flags) { in snd_sb8dsp_midi_output_open() 91 chip->open |= SB_OPEN_MIDI_OUTPUT; in snd_sb8dsp_midi_output_open() 93 if (!(chip->open & SB_OPEN_MIDI_INPUT)) { in snd_sb8dsp_midi_output_open() 111 chip->open &= ~(SB_OPEN_MIDI_INPUT | SB_OPEN_MIDI_INPUT_TRIGGER); in snd_sb8dsp_midi_input_close() 113 if (!(chip->open & SB_OPEN_MIDI_OUTPUT)) { in snd_sb8dsp_midi_input_close() 130 chip->open in snd_sb8dsp_midi_output_close() [all...] |
/kernel/linux/linux-6.6/sound/isa/sb/ |
H A D | sb8_midi.c | 41 if (chip->open & SB_OPEN_MIDI_INPUT_TRIGGER) { in snd_sb8dsp_midi_interrupt() 60 if (chip->open & ~valid_open_flags) { in snd_sb8dsp_midi_input_open() 64 chip->open |= SB_OPEN_MIDI_INPUT; in snd_sb8dsp_midi_input_open() 66 if (!(chip->open & SB_OPEN_MIDI_OUTPUT)) { in snd_sb8dsp_midi_input_open() 87 if (chip->open & ~valid_open_flags) { in snd_sb8dsp_midi_output_open() 91 chip->open |= SB_OPEN_MIDI_OUTPUT; in snd_sb8dsp_midi_output_open() 93 if (!(chip->open & SB_OPEN_MIDI_INPUT)) { in snd_sb8dsp_midi_output_open() 111 chip->open &= ~(SB_OPEN_MIDI_INPUT | SB_OPEN_MIDI_INPUT_TRIGGER); in snd_sb8dsp_midi_input_close() 113 if (!(chip->open & SB_OPEN_MIDI_OUTPUT)) { in snd_sb8dsp_midi_input_close() 130 chip->open in snd_sb8dsp_midi_output_close() [all...] |
/kernel/uniproton/cmake/common/build_auxiliary_script/ |
H A D | Kconfig2macro.py | 30 with open(in_file, 'r') as fd_in: 40 with codecs.open(out_file, 113 with codecs.open(out_file, 'a+') as fd_out, open(in_file) as fd_in: 125 with open(filename, 'r', errors='ignore') as fp: 130 with codecs.open(file, 'a+') as fd_in: 138 with codecs.open(out_file, 'a+') as fd_out: 147 with codecs.open(out_file, 'a+') as fd_out: 157 with codecs.open(out_file, 'a+') as fd_out:
|
/kernel/linux/linux-5.10/tools/testing/selftests/wireguard/qemu/ |
H A D | init.c | 72 fd = open("/dev/urandom", O_WRONLY); in seed_rng() 74 panic("open(urandom)"); in seed_rng() 113 fd = open("/proc/sys/kernel/printk", O_WRONLY); in enable_logging() 119 fd = open("/proc/sys/debug/exception-trace", O_WRONLY); in enable_logging() 125 fd = open("/proc/sys/kernel/panic_on_warn", O_WRONLY); in enable_logging() 184 fd = open("/proc/cmdline", O_RDONLY); in launch_tests() 186 panic("open(/proc/cmdline)"); in launch_tests() 200 fd = open(success_dev, O_WRONLY); in launch_tests() 202 panic("open(success_dev)"); in launch_tests() 224 int fd = open("/de in ensure_console() [all...] |
/kernel/linux/linux-5.10/drivers/staging/fwserial/ |
H A D | dma_fifo.c | 27 * private helper fn to determine if check is in open interval (lo,hi) 79 fifo->open = 0; in dma_fifo_alloc() 126 fifo->open = 0; in dma_fifo_reset() 198 if (fifo->open == fifo->open_limit) in dma_fifo_out_pend() 223 ++fifo->open; in dma_fifo_out_pend() 225 if (FAIL(fifo, fifo->open > fifo->open_limit, in dma_fifo_out_pend() 226 "past open limit:%d (limit:%d)", in dma_fifo_out_pend() 227 fifo->open, fifo->open_limit)) in dma_fifo_out_pend() 250 if (list_empty(&fifo->pending) && fifo->open == 0) in dma_fifo_out_complete() 253 if (FAIL(fifo, list_empty(&fifo->pending) != (fifo->open in dma_fifo_out_complete() [all...] |
/base/security/dlp_permission_service/interfaces/inner_api/dlp_parse/test/ |
H A D | dlp_file_test.cpp | 680 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 707 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 734 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 767 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 802 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 837 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 1183 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 1206 int fd = open("/data/fuse_test.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 1245 int fdPlain = open("/data/fuse_test_plain.txt", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); in HWTEST_F() 1247 int fdDlp = open("/dat in HWTEST_F() [all...] |
H A D | dlp_zip_test.cpp | 112 int32_t fd = open(zipFile.c_str(), O_RDWR | O_CREAT, 0666); in HWTEST_F() 139 int32_t fd = open(zipFile.c_str(), O_RDWR | O_CREAT, 0666); in HWTEST_F() 142 int32_t fd2 = open(inZip.c_str(), O_RDWR | O_CREAT, 0666); in HWTEST_F() 172 int32_t fd = open(zipFile.c_str(), O_WRONLY | O_CREAT, 0666); in HWTEST_F() 176 int32_t fd2 = open(zipFile.c_str(), O_RDWR | O_CREAT, 0666); in HWTEST_F() 180 int32_t fd3 = open(inZip1.c_str(), O_RDWR | O_CREAT, 0666); in HWTEST_F() 185 int32_t fd4 = open(inZip2.c_str(), O_RDWR | O_CREAT, 0666); in HWTEST_F()
|
/kernel/linux/linux-6.6/fs/nfsd/ |
H A D | nfs4proc.c | 105 struct nfsd4_compound_state *cstate, struct nfsd4_open *open) in nfsd4_check_open_attributes() 109 if (open->op_create == NFS4_OPEN_CREATE) { in nfsd4_check_open_attributes() 110 if (open->op_createmode == NFS4_CREATE_UNCHECKED in nfsd4_check_open_attributes() 111 || open->op_createmode == NFS4_CREATE_GUARDED) in nfsd4_check_open_attributes() 113 open->op_bmval, nfsd_attrmask); in nfsd4_check_open_attributes() 114 else if (open->op_createmode == NFS4_CREATE_EXCLUSIVE4_1) in nfsd4_check_open_attributes() 116 open->op_bmval, nfsd41_ex_attrmask); in nfsd4_check_open_attributes() 123 is_create_with_attrs(struct nfsd4_open *open) in is_create_with_attrs() argument 125 return open->op_create == NFS4_OPEN_CREATE in is_create_with_attrs() 126 && (open in is_create_with_attrs() 104 nfsd4_check_open_attributes(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, struct nfsd4_open *open) nfsd4_check_open_attributes() argument 142 do_open_permission(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open, int accmode) do_open_permission() argument 179 nfsd4_set_open_owner_reply_cache(struct nfsd4_compound_state *cstate, struct nfsd4_open *open, struct svc_fh *resfh) nfsd4_set_open_owner_reply_cache() argument 194 nfsd4_vfs_create(struct svc_fh *fhp, struct dentry *child, struct nfsd4_open *open) nfsd4_vfs_create() argument 232 nfsd4_create_file(struct svc_rqst *rqstp, struct svc_fh *fhp, struct svc_fh *resfhp, struct nfsd4_open *open) nfsd4_create_file() argument 418 do_open_lookup(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, struct nfsd4_open *open, struct svc_fh **resfh) do_open_lookup() argument 485 do_open_fhandle(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, struct nfsd4_open *open) do_open_fhandle() argument 529 struct nfsd4_open *open = &u->open; nfsd4_open() local 653 struct nfsd4_open *open = &op->u.open; nfsd4_open_omfg() local [all...] |
/kernel/linux/linux-6.6/tools/testing/selftests/wireguard/qemu/ |
H A D | init.c | 66 fd = open("/dev/random", O_WRONLY); in seed_rng() 68 panic("open(random)"); in seed_rng() 114 fd = open("/proc/sys/kernel/printk", O_WRONLY); in enable_logging() 120 fd = open("/proc/sys/debug/exception-trace", O_WRONLY); in enable_logging() 179 fd = open("/proc/cmdline", O_RDONLY); in launch_tests() 181 panic("open(/proc/cmdline)"); in launch_tests() 195 fd = open(success_dev, O_WRONLY); in launch_tests() 197 panic("open(success_dev)"); in launch_tests() 219 int fd = open("/dev/console", O_RDWR); in ensure_console() 231 panic("Unable to open consol in ensure_console() [all...] |
/kernel/linux/linux-6.6/tools/testing/kunit/ |
H A D | kunit_tool_test.py | 101 with open(log_path) as file: 112 with open(log_path) as file: 141 with open(all_passed_log) as file: 148 with open(all_passed_log) as file: 155 with open(kselftest_log) as file: 162 with open(failed_log) as file: 169 with open(empty_log) as file: 179 with open(missing_plan_log) as file: 189 with open(header_log) as file: 198 with open(no_plan_lo [all...] |
/kernel/linux/build/test/unittest/accesstokenid/ |
H A D | accesstokenid_test.cpp | 74 fd = open("/dev/random", O_RDONLY); in GenRand64() 88 int fd = open(DEV_ACCESSTOKENID, O_RDWR); in GetTokenid() 90 printf("open %s failed\r\n", DEV_ACCESSTOKENID); in GetTokenid() 107 int fd = open(DEV_ACCESSTOKENID, O_RDWR); in SetTokenid() 109 printf("open %s failed\r\n", DEV_ACCESSTOKENID); in SetTokenid() 126 int fd = open(DEV_ACCESSTOKENID, O_RDWR); in GetfTokenid() 128 printf("open %s failed\r\n", DEV_ACCESSTOKENID); in GetfTokenid() 145 int fd = open(DEV_ACCESSTOKENID, O_RDWR); in SetfTokenid() 147 printf("open %s failed\r\n", DEV_ACCESSTOKENID); in SetfTokenid() 368 int fd = open(DEV_ACCESSTOKENI in HWTEST_F() [all...] |
/kernel/liteos_m/testsuites/unittest/posix/src/fs/api/ |
H A D | posix_fs_open_test.c | 35 * @tc.name open 43 int32_t fd = open(tmpFileName, O_CREAT | O_RDWR, TEST_MODE_HIGH); 49 fd = open(tmpFileName, O_CREAT | O_RDWR, TEST_MODE_NORMAL); 63 * @tc.name open 71 int32_t fd = open(tmpFileName1, O_CREAT | O_RDWR); 75 fd = open(tmpFileName2, O_CREAT | O_RDWR); 84 * @tc.name open 94 fd = open(tmpFileName, O_CREAT | O_RDWR);
|
/kernel/linux/linux-6.6/tools/testing/selftests/drivers/sdsi/ |
H A D | sdsi_test.py | 29 with open(file, mode='rb') as f: 49 f = open(file, "r") 121 f = open(folder + "provision_cap", "wb", 0) 128 f = open(folder + "provision_akc", "wb", 0) 141 f = open(folder + "registers", "rb") 159 f = open(node, 'wb', 0) 173 f = open(node, 'wb', 0) 174 g = open(node, 'wb', 0) 176 with open(driver_dir + 'unbind', 'w') as k: 211 with open(driver_di [all...] |
/base/update/packaging_tools/test/ |
H A D | test_utils.py | 63 with open('test.file', 'w') as w_f: 80 with open("./updater_specified_config_repeats.xml", "wb") as w_f: 102 with open('test.file', 'w') as w_f: 120 with open(VERSION_MBN_PATH, 'w') as w_f: 134 with open(VERSION_MBN_PATH, 'w') as w_f: 136 with open(BOARD_LIST_PATH, 'w') as w_f: 152 with open("./partition_file_conversion_failed.xml", "wb") as w_f:
|
H A D | test_update_package.py | 42 with open(VERSION_MBN_PATH) as om_second_f:
63 with open(VERSION_MBN_PATH) as om_third_f:
96 with open(VERSION_MBN_PATH, 'w') as w_f:
98 with open(BOARD_LIST_PATH, 'w') as w_f:
100 with open(VERSION_MBN_PATH) as om_first_f:
153 with open(package_path, 'wb') as w_f:
|
/kernel/linux/linux-5.10/tools/testing/kunit/ |
H A D | kunit_tool_test.py | 103 file = open(log_path) 116 with open(log_path) as file: 146 file = open(all_passed_log) 156 file = open(failed_log) 166 file = open(empty_log) 178 file = open(crash_log) 189 file = open(crashed_log) 199 with open(prefix_log) as file: 209 with open(prefix_log) as file: 219 with open(mixed_prefix_lo [all...] |
/base/update/packaging_tools/ |
H A D | build_pkcs7.py | 48 with open(CERT_PATH, 'rb') as cert_file: 64 with open(package_path, 'rb') as package_file: 77 with open(private_key_file, 'rb') as f_r: 101 with open(private_key_file, 'rb') as f_r: 136 package_fd = os.open(signed_package, os.O_RDWR | os.O_CREAT | os.O_TRUNC, 0o755) 140 with open(unsigned_package, 'rb') as f_unsign: 163 digest_fd = os.open("digest", os.O_RDWR | os.O_CREAT, 0o755) 168 signatute_fd = os.open("signature", os.O_RDWR | os.O_CREAT, 0o755)
|
/kernel/linux/linux-5.10/fs/nfsd/ |
H A D | nfs4proc.c | 69 * XXX: We should really fail the whole open, but we may in nfsd4_security_inode_setsecctx() 121 struct nfsd4_compound_state *cstate, struct nfsd4_open *open) in nfsd4_check_open_attributes() 125 if (open->op_create == NFS4_OPEN_CREATE) { in nfsd4_check_open_attributes() 126 if (open->op_createmode == NFS4_CREATE_UNCHECKED in nfsd4_check_open_attributes() 127 || open->op_createmode == NFS4_CREATE_GUARDED) in nfsd4_check_open_attributes() 129 open->op_bmval, nfsd_attrmask); in nfsd4_check_open_attributes() 130 else if (open->op_createmode == NFS4_CREATE_EXCLUSIVE4_1) in nfsd4_check_open_attributes() 132 open->op_bmval, nfsd41_ex_attrmask); in nfsd4_check_open_attributes() 139 is_create_with_attrs(struct nfsd4_open *open) in is_create_with_attrs() argument 141 return open in is_create_with_attrs() 120 nfsd4_check_open_attributes(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, struct nfsd4_open *open) nfsd4_check_open_attributes() argument 178 do_open_permission(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open, int accmode) do_open_permission() argument 218 nfsd4_set_open_owner_reply_cache(struct nfsd4_compound_state *cstate, struct nfsd4_open *open, struct svc_fh *resfh) nfsd4_set_open_owner_reply_cache() argument 227 do_open_lookup(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, struct nfsd4_open *open, struct svc_fh **resfh) do_open_lookup() argument 308 do_open_fhandle(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, struct nfsd4_open *open) do_open_fhandle() argument 355 struct nfsd4_open *open = &u->open; nfsd4_open() local 482 struct nfsd4_open *open = &op->u.open; nfsd4_open_omfg() local [all...] |
/base/security/appverify/interfaces/innerkits/appverify/test/unittest/src/ |
H A D | hap_verify_test.cpp | 88 appFile.open(errorFile.c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 99 hapFile.open(rightFile.c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 112 hapFile1.open(rightFile1.c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 126 hapFile2.open(invalidFile.c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 148 hapFile.open(filePath.c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 176 hapFile.open(filePath[i].c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 202 errorFile.open(errorfilePath[i].c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 214 errorFile.open(errorfilePath[i].c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 225 errorFile.open(errorfilePath[i].c_str(), std::ios::binary | std::ios::out | std::ios::trunc); in HWTEST_F() 246 hapFile.open(filePat in HWTEST_F() [all...] |
/base/security/dlp_permission_service/interfaces/inner_api/dlp_fuse/test/unittest/src/ |
H A D | dlp_fuse_test.cpp | 194 g_mountFd = open(FUSE_DEV.c_str(), O_RDWR); in PrepareDlpFuseFsMount() 199 DLP_LOG_ERROR(LABEL, "open fuse device failed."); in PrepareDlpFuseFsMount() 318 g_plainFileFd = open("/data/fuse_test.txt", O_CREAT | O_RDWR | O_TRUNC, S_IRWXU | S_IRWXG | S_IRWXO); in HWTEST_F() 319 g_dlpFileFd = open("/data/fuse_test.txt.dlp", O_CREAT | O_RDWR | O_TRUNC, S_IRWXU | S_IRWXG | S_IRWXO); in HWTEST_F() 337 // open link file in HWTEST_F() 338 int32_t linkfd = open(TEST_LINK_FILE_PATH.c_str(), O_RDWR); in HWTEST_F() 376 g_plainFileFd = open("/data/fuse_test.txt", O_CREAT | O_RDWR | O_TRUNC, S_IRWXU | S_IRWXG | S_IRWXO); in HWTEST_F() 377 g_dlpFileFd = open("/data/fuse_test.txt.dlp", O_CREAT | O_RDWR | O_TRUNC, S_IRWXU | S_IRWXG | S_IRWXO); in HWTEST_F() 391 // open link file in HWTEST_F() 392 int32_t linkfd = open(TEST_LINK_FILE_PAT in HWTEST_F() [all...] |
/kernel/linux/linux-5.10/tools/cgroup/ |
H A D | iocost_coef_gen.py | 102 with open(outfile.name, 'r') as f: 110 with open(elevator_path, 'w') as f: 112 with open(nomerges_path, 'w') as f: 142 with open(elevator_path, 'r') as f: 144 with open(nomerges_path, 'r') as f: 149 with open(elevator_path, 'w') as f: 151 with open(nomerges_path, 'w') as f:
|
/kernel/linux/linux-6.6/tools/cgroup/ |
H A D | iocost_coef_gen.py | 102 with open(outfile.name, 'r') as f: 110 with open(elevator_path, 'w') as f: 112 with open(nomerges_path, 'w') as f: 142 with open(elevator_path, 'r') as f: 144 with open(nomerges_path, 'r') as f: 149 with open(elevator_path, 'w') as f: 151 with open(nomerges_path, 'w') as f:
|
/base/security/access_token/interfaces/innerkits/token_setproc/src/ |
H A D | token_setproc.c | 39 int fd = open(TOKENID_DEVNODE, O_RDWR); in GetSelfTokenID() 55 int fd = open(TOKENID_DEVNODE, O_RDWR); in SetSelfTokenID() 72 int fd = open(TOKENID_DEVNODE, O_RDWR); in GetFirstCallerTokenID() 88 int fd = open(TOKENID_DEVNODE, O_RDWR); in SetFirstCallerTokenID()
|
/base/hiviewdfx/hiview/plugins/eventlogger/log_catcher/test/unittest/common/ |
H A D | event_logger_catcher_test.cpp | 80 auto fd = open("/data/test/catcherFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 100 auto fd = open("/data/test/testFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 129 auto fd = open("/data/test/testFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 154 auto fd = open("/data/test/testFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 210 auto fd = open("/data/test/catcherFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 230 auto fd = open("/data/test/catcherFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 250 auto fd = open("/data/test/FfrtCatcherFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 295 auto fd = open("/data/test/dmesgCatcherFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 326 auto fd = open("/data/test/dmesgCatcherFile", O_CREAT | O_WRONLY | O_TRUNC, DEFAULT_MODE); in HWTEST_F() 347 auto fd = open("/dat in HWTEST_F() [all...] |