Home
last modified time | relevance | path

Searched refs:str (Results 1 – 25 of 112) sorted by relevance

12345

/DragonOS/kernel/src/libs/
H A Dprintk.c25 static char *write_num(char *str, ul num, int base, int field_width, int precision, int flags);
27 static char *write_float_point_num(char *str, double num, int field_width, int precision, int flags…
60 char *str = NULL, *s = NULL, *end = NULL; in __do_vsprintf() local
62 str = buf; in __do_vsprintf()
80 *str = *fmt; in __do_vsprintf()
81 ++str; in __do_vsprintf()
185 *str++ = '%'; in __do_vsprintf()
195 *str = ' '; in __do_vsprintf()
196 ++str; in __do_vsprintf()
200 *str++ = (unsigned char)va_arg(args, int); in __do_vsprintf()
[all …]
/DragonOS/kernel/src/filesystem/vfs/
H A Dutils.rs16 pub fn split_path(path: &str) -> (&str, Option<&str>) { in split_path() argument
17 let mut path_split: core::str::SplitN<&str> = path.trim_matches('/').splitn(2, "/"); in split_path()
27 pub fn rsplit_path(path: &str) -> (&str, Option<&str>) { in rsplit_path() argument
28 let mut path_split: core::str::RSplitN<&str> = path.trim_matches('/').rsplitn(2, "/"); in rsplit_path()
43 path: &str, in user_path_at() argument
125 impl From<&str> for DName {
126 fn from(value: &str) -> Self { in from()
143 impl AsRef<str> for DName {
144 fn as_ref(&self) -> &str { in as_ref() argument
H A Dmod.rs232 name: &str, in create() argument
251 _name: &str, in create_with_data() argument
267 fn link(&self, _name: &str, _other: &Arc<dyn IndexNode>) -> Result<(), SystemError> { in link() argument
278 fn unlink(&self, _name: &str) -> Result<(), SystemError> { in unlink()
289 fn rmdir(&self, _name: &str) -> Result<(), SystemError> { in rmdir()
299 _old_name: &str, in move_to() argument
301 _new_name: &str, in move_to() argument
313 fn find(&self, _name: &str) -> Result<Arc<dyn IndexNode>, SystemError> { in find()
494 _filename: &str, in mknod() argument
516 fn mkdir(&self, name: &str, mode: ModeType) -> Result<Arc<dyn IndexNode>, SystemError> { in mkdir() argument
[all …]
H A Dmount.rs166 fn do_find(&self, name: &str) -> Result<Arc<MountFSInode>, SystemError> { in do_find()
242 name: &str, in create_with_data() argument
309 name: &str, in create() argument
321 fn link(&self, name: &str, other: &Arc<dyn IndexNode>) -> Result<(), SystemError> { in link() argument
327 fn unlink(&self, name: &str) -> Result<(), SystemError> { in unlink()
339 fn rmdir(&self, name: &str) -> Result<(), SystemError> { in rmdir()
355 old_name: &str, in move_to() argument
357 new_name: &str, in move_to() argument
362 fn find(&self, name: &str) -> Result<Arc<dyn IndexNode>, SystemError> { in find()
469 filename: &str, in mknod() argument
[all …]
/DragonOS/kernel/src/driver/net/
H A Dsysfs.rs46 fn name(&self) -> Option<&str> { in name() argument
93 fn name(&self) -> &str { in name() argument
120 fn name(&self) -> &str { in name() argument
142 fn name(&self) -> &str { in name() argument
164 fn name(&self) -> &str { in name() argument
190 fn name(&self) -> &str { in name() argument
212 fn name(&self) -> &str { in name() argument
234 fn name(&self) -> &str { in name() argument
261 fn name(&self) -> &str { in name() argument
290 fn name(&self) -> &str { in name() argument
[all …]
/DragonOS/user/apps/test_socket/src/
H A Dtest_unix_stream.rs4 use std::{fs, str};
6 const SOCKET_PATH: &str = "/test.socket";
7 const MSG: &str = "Hello, unix stream socket!";
31 let received_msg = str::from_utf8(&buffer[..nbytes]).unwrap(); in test_unix_stream()
H A Dtest_unix_stream_pair.rs3 use std::str;
5 const MSG: &str = "Hello, unix stream socketpair!";
14 let received_msg = str::from_utf8(&buffer[..nbytes]).unwrap(); in test_unix_stream_pair()
/DragonOS/user/apps/test_uart/
H A Dmain.c25 char *str = "------fuck-----"; in main() local
26 int len = write(fd, str, strlen(str)); in main()
/DragonOS/kernel/src/arch/x86_64/interrupt/
H A Dtrap.rs255 const ERR_MSG_1: &str = in do_invalid_TSS()
257 const ERR_MSG_2: &str = "Refers to a descriptor in the IDT.\n"; in do_invalid_TSS()
258 const ERR_MSG_3: &str = "Refers to a descriptor in the current LDT.\n"; in do_invalid_TSS()
259 const ERR_MSG_4: &str = "Refers to a descriptor in the GDT.\n"; in do_invalid_TSS()
261 let msg1: &str = if (error_code & 0x1) != 0 { in do_invalid_TSS()
267 let msg2: &str = if (error_code & 0x02) != 0 { in do_invalid_TSS()
319 …const ERR_MSG_1: &str = "The exception occurred during delivery of an event external to the progra… in do_general_protection()
320 const ERR_MSG_2: &str = "Refers to a gate descriptor in the IDT;\n"; in do_general_protection()
321 const ERR_MSG_3: &str = "Refers to a descriptor in the GDT or the current LDT;\n"; in do_general_protection()
322 const ERR_MSG_4: &str = "Refers to a segment or gate descriptor in the LDT;\n"; in do_general_protection()
[all …]
/DragonOS/kernel/src/driver/base/platform/
H A Dmod.rs41 pub struct CompatibleTable(BTreeSet<&'static str>);
50 pub fn new(id_vec: Vec<&'static str>) -> CompatibleTable { in new()
65 pub fn add_device(&mut self, devices: Vec<&'static str>) { in add_device() argument
66 for str in devices { in add_device()
67 self.0.insert(str); in add_device()
/DragonOS/build-scripts/kernel_build/src/constant/
H A Dmod.rs1 pub const ARCH_DIR_X86_64: &str = "src/arch/x86_64";
2 pub const ARCH_DIR_RISCV64: &str = "src/arch/riscv64";
/DragonOS/user/apps/user-manage/src/executor/
H A Dexecutor.rs39 fn open_file(file_path: &str) -> File { in open_file()
107 let mut field = line.split(":").collect::<Vec<&str>>(); in write_group_file()
108 let mut users = field.last().unwrap().split(",").collect::<Vec<&str>>(); in write_group_file()
112 .collect::<Vec<&str>>(); in write_group_file()
149 let mut field = line.split(":").collect::<Vec<&str>>(); in write_gshadow_file()
150 let mut users = field.last().unwrap().split(",").collect::<Vec<&str>>(); in write_gshadow_file()
154 .collect::<Vec<&str>>(); in write_gshadow_file()
200 let lines: Vec<&str> = content.lines().collect(); in update_passwd_file()
204 let field = line.split(':').collect::<Vec<&str>>(); in update_passwd_file()
207 .collect::<Vec<&str>>() in update_passwd_file()
[all …]
/DragonOS/kernel/src/driver/video/fbdev/base/
H A Dfbsysfs.rs20 fn name(&self) -> Option<&str> { in name() argument
52 fn name(&self) -> &str { in name() argument
76 fn name(&self) -> &str { in name() argument
106 fn name(&self) -> &str { in name() argument
129 fn name(&self) -> &str { in name() argument
156 fn name(&self) -> &str { in name() argument
183 fn name(&self) -> &str { in name() argument
212 fn name(&self) -> &str { in name() argument
244 fn name(&self) -> &str { in name() argument
268 fn name(&self) -> &str { in name() argument
[all …]
/DragonOS/kernel/crates/unified-init/src/
H A Dlib.rs11 name: &'static str,
16 name: &'static str, in new() argument
28 pub const fn name(&self) -> &'static str { in name() argument
/DragonOS/tools/
H A Dbatch_delete_loop.py7 print("Deleting: " + str(i))
8 os.system("sudo losetup -d /dev/loop" + str(i))
H A Dlist_contributors.py9 parser.add_argument('--since', type=str, help='Since date')
10 parser.add_argument('--until', type=str, help='Until date')
11 parser.add_argument('--mode', type=str, help='脚本的运行模式 可选:<all> 输出所有信息\n' +
/DragonOS/tools/debugging/logmonitor/src/
H A Dapp.rs13 pub title: &'a str,
27 pub stateful_logs: StatefulList<(&'a str, &'a str)>,
34 pub fn new(title: &'a str) -> Self { in new()
108 pub titles: Vec<&'a str>,
113 pub fn new(titles: Vec<&'a str>) -> TabsState { in new()
/DragonOS/kernel/src/debug/
H A Dkallsyms.c53 char str[512] = {0}; in read_symbol() local
54 char *s = fgets(str, sizeof(str), filp); in read_symbol()
55 if (s != str) in read_symbol()
61 int retval = sscanf(str, "%llx %c %512c", &entry->vaddr, &entry->type, symbol_name); in read_symbol()
/DragonOS/user/apps/test_lo/src/
H A Dmain.rs2 use std::str;
14 let received_msg = str::from_utf8(&buf[..amt]).expect("Could not read buffer as UTF-8"); in main()
/DragonOS/kernel/src/driver/pci/
H A Dattr.rs21 fn name(&self) -> Option<&str> { in name() argument
46 fn name(&self) -> &str { in name() argument
77 fn name(&self) -> &str { in name() argument
108 fn name(&self) -> &str { in name() argument
139 fn name(&self) -> &str { in name() argument
/DragonOS/kernel/src/driver/firmware/efi/
H A Dfdt.rs59 fn prop_name(&self) -> &'static str { in prop_name() argument
64 impl From<FdtPropType> for &'static str { implementation
76 impl TryFrom<&str> for FdtPropType {
79 fn try_from(value: &str) -> Result<Self, Self::Error> { in try_from()
93 path: &'static str,
/DragonOS/kernel/src/exception/
H A Dsysfs.rs61 fn name(&self) -> Option<&str> { in name() argument
139 fn name(&self) -> &str { in name() argument
170 fn name(&self) -> &str { in name() argument
196 fn name(&self) -> &str { in name() argument
227 fn name(&self) -> &str { in name() argument
253 fn name(&self) -> &str { in name() argument
283 fn name(&self) -> &str { in name() argument
/DragonOS/kernel/crates/intertrait/tests/
H A Don-trait-impl-assoc-type2.rs20 type I2 = &'static str; variable
33 let concat = source.cast::<dyn Concat<I1 = i32, I2 = &'static str>>(); in test_cast_to_on_trait_impl_with_assoc_type2() variable
H A Don-trait-impl-assoc-type3.rs20 type I2 = &'static str; variable
33 let concat = source.cast::<dyn Concat<String, I1 = i32, I2 = &'static str>>(); in test_cast_to_on_trait_impl_with_assoc_type3() variable
/DragonOS/tools/debugging/logmonitor/src/backend/monitor/
H A Dlogset.rs95 fn before_insert(&mut self, _log_set_name: &str, _log: &V) {} in before_insert() argument
97 fn after_insert(&mut self, _log_set_name: &str, _log: &V) {} in after_insert() argument
110 fn before_insert(&mut self, _log_set_name: &str, _log: &V) {} in before_insert() argument
112 fn after_insert(&mut self, _log_set_name: &str, _log: &V) {} in after_insert() argument

12345