Home
last modified time | relevance | path

Searched refs:Some (Results 1 – 25 of 648) sorted by relevance

12345678910>>...26

/linux/rust/kernel/debugfs/
H A Dfile_ops.rs103 unsafe { bindings::single_open(file, Some(writer_act::<T>), data) } in writer_act()
134 read: Some(bindings::seq_read),
135 llseek: Some(bindings::seq_lseek),
136 release: Some(bindings::single_release),
137 open: Some(writer_open::<Self>),
185 open: Some(writer_open::<T>),
186 read: Some(bindings::seq_read),
187 write: Some(write::<T>),
188 llseek: Some(bindings::seq_lseek),
189 release: Some(binding
[all...]
/linux/rust/zerocopy/src/util/
H A Dmacro_util.rs217 Some(
981 test!(#[repr(C)] #[repr(transparent)] #[repr(packed)](; u8) => Some(0)); in test_trailing_field_offset()
982 test!(#[repr(C)] #[repr(transparent)] #[repr(packed)](; [u8]) => Some(0)); in test_trailing_field_offset()
983 test!(#[repr(C)] #[repr(C, packed)] (u8; u8) => Some(1)); in test_trailing_field_offset()
984 test!(#[repr(C)] (; AU64) => Some(0)); in test_trailing_field_offset()
985 test!(#[repr(C)] (; [AU64]) => Some(0)); in test_trailing_field_offset()
986 test!(#[repr(C)] (u8; AU64) => Some(8)); in test_trailing_field_offset()
987 test!(#[repr(C)] (u8; [AU64]) => Some(8)); in test_trailing_field_offset()
998 test!(#[repr(C)] (; Nested<u8, AU64>) => Some(0)); in test_trailing_field_offset()
999 test!(#[repr(C)] (; Nested<u8, [AU64]>) => Some(0)); in test_trailing_field_offset()
[all …]
/linux/rust/proc-macro2/
H A Dparse.rs161 Some(ch) if is_ident_continue(ch) => Err(Reject), in word_break()
162 Some(_) | None => Ok(input), in word_break()
186 Some(first) => first, in token_stream()
190 Some((lo, _frame)) => { in token_stream()
196 Some(_frame) => return Err(LexError { span: Span {} }), in token_stream()
200 if let Some(open_delimiter) = match first { in token_stream()
201 b'(' if !input.starts_with(ERROR) => Some(Delimiter::Parenthesis), in token_stream()
202 b'[' => Some(Delimiter::Bracket), in token_stream()
203 b'{' => Some(Delimiter::Brace), in token_stream()
212 } else if let Some(close_delimiter) = match first { in token_stream()
[all …]
/linux/rust/macros/
H A Dmodule.rs112 let Some(params) = &info.params else { in emit_params()
255 stringify!($key) => $name = Some($parser),
445 if let Some(authors) = authors { in module()
450 if let Some(description) = description { in module()
454 if let Some(aliases) = alias { in module()
459 if let Some(firmware) = firmware { in module()
464 if let Some(imports) = imports_ns { in module()
109 let Some(params) = &info.params else { emit_params() localVariable
H A Dhelpers.rs
H A Dfmt.rs16 let Some((mut first_str, first_span)) = (match first_opt.as_ref() { in fmt()
17 Some(TokenTree::Literal(first_lit)) => { in fmt()
19 Some(first_owned_str.as_str()).and_then(|first| { in fmt()
22 Some((first, first_lit.span())) in fmt()
33 while let Some((_, rest)) = first_str.split_once('{') { in fmt()
35 if let Some(rest) = first_str.strip_prefix('{') { in fmt()
39 if let Some((name, rest)) = first_str.split_once('}') { in fmt()
60 while let Some(tt) = current.next() { in fmt()
66 return (Some(acc), current.collect::<TokenStream>()); in fmt()
14 let Some((mut first_str, first_span)) = (match first_opt.as_ref() { fmt() localVariable
H A Dvtable.rs
H A Dpaste.rs12 Some(TokenTree::Literal(lit)) => { in concat_helper()
21 Some(TokenTree::Ident(ident)) => { in concat_helper()
28 Some(TokenTree::Punct(p)) if p.as_char() == ':' => { in concat_helper()
29 let Some(TokenTree::Ident(ident)) = tokens.next() else { in concat_helper() localVariable
41 span = Some(sp); in concat_helper()
49 Some(TokenTree::Group(group)) if group.delimiter() == Delimiter::None => { in concat_helper()
/linux/rust/kernel/drm/gem/
H A Dshmem.rs131 free: Some(Self::free_callback), in new()
132 open: Some(super::open_callback::<T>), in new()
133 close: Some(super::close_callback::<T>), in new()
134 print_info: Some(bindings::drm_gem_shmem_object_print_info), in new()
136 pin: Some(bindings::drm_gem_shmem_object_pin), in new()
137 unpin: Some(bindings::drm_gem_shmem_object_unpin), in new()
138 get_sg_table: Some(bindings::drm_gem_shmem_object_get_sg_table), in new()
139 vmap: Some(bindings::drm_gem_shmem_object_vmap), in new()
140 vunmap: Some(bindings::drm_gem_shmem_object_vunmap), in new()
141 mmap: Some(binding in new()
[all...]
H A Dmod.rs266 free: Some(Self::free_callback),
267 open: Some(open_callback::<T>),
268 close: Some(close_callback::<T>), in new()
391 fops.open = Some(bindings::drm_open);
392 fops.release = Some(bindings::drm_release);
393 fops.unlocked_ioctl = Some(bindings::drm_ioctl);
396 fops.compat_ioctl = Some(bindings::drm_compat_ioctl);
398 fops.poll = Some(bindings::drm_poll);
399 fops.read = Some(bindings::drm_read);
400 fops.llseek = Some(binding
[all...]
/linux/rust/kernel/
H A Dbitmap.rs140 /// assert_eq!(Some(0), b.next_bit(0));
141 /// assert_eq!(Some(1), b.next_zero_bit(0));
142 /// assert_eq!(Some(4), b.next_bit(1));
143 /// assert_eq!(Some(5), b.next_zero_bit(4));
144 /// assert_eq!(Some(12), b.last_bit());
411 /// assert_eq!(Some(7), long_bitmap.last_bit());
440 /// Some(idx) => {
456 Some(index) in last_bit()
477 Some(index) in next_bit()
497 Some(inde in next_zero_bit()
[all...]
H A Dcpufreq.rs645 Some(unsafe { T::borrow(self.as_ref().driver_data.cast()) })
669 let data = Some( in clear_data()
935 init: Some(Self::init_callback),
936 verify: Some(Self::verify_callback),
940 Some(Self::setpolicy_callback)
945 Some(Self::target_callback)
950 Some(Self::target_index_callback)
955 Some(Self::fast_switch_callback)
960 Some(Self::adjust_perf_callback)
965 Some(Sel
[all...]
H A Did_pool.rs162 let Some(bit) = self.map.last_bit() else { in shrink_request() localVariable
163 return Some(ReallocRequest { in shrink_request()
171 Some(ReallocRequest { num_ids }) in shrink_request()
182 let Some(updated) = self.shrink_request() else { in shrink() localVariable
204 Some(ReallocRequest { num_ids }) in grow_request()
232 Some(UnusedId { in find_unused_id()
/linux/rust/syn/
H A Dparse.rs268 if let Some((unexpected_span, delimiter)) = span_of_unexpected_ignoring_nones(self.cursor()) in drop()
272 inner.set(Unexpected::Some(unexpected_span, delimiter)); in drop()
397 unexpected: Cell::new(Some(unexpected)), in new_parse_buffer()
403 Some(Span, Delimiter), enumerator
417 Unexpected::Some(span, delimiter) => Unexpected::Some(*span, *delimiter), in clone()
437 Unexpected::Some(span, delimiter) => return (unexpected, Some((span, delimiter))), in inner_unexpected()
451 while let Some((inner, _span, rest)) = cursor.group(Delimiter::None) { in span_of_unexpected_ignoring_nones()
452 if let Some(unexpected) = span_of_unexpected_ignoring_nones(inner) { in span_of_unexpected_ignoring_nones()
453 return Some(unexpected); in span_of_unexpected_ignoring_nones()
460 Some((cursor.span(), cursor.scope_delimiter())) in span_of_unexpected_ignoring_nones()
[all …]
H A Ddiscouraged.rs180 (Some((span, delimiter)), None) => { in advance_to()
181 self_unexp.set(Unexpected::Some(span, delimiter)); in advance_to()
192 .set(Some(Rc::new(Cell::new(Unexpected::None)))); in advance_to()
195 (_, Some(_)) => {} in advance_to()
216 if let Some((content, delimiter, span, rest)) = cursor.any_group() { in parse_any_delimiter()
H A Dbuffer.rs194 Entry::Ident(ident) => Some((ident.clone(), unsafe { self.bump_ignore_group() })), in ident()
205 Some((punct.clone(), unsafe { self.bump_ignore_group() })) in punct()
216 Entry::Literal(literal) => Some((literal.clone(), unsafe { self.bump_ignore_group() })), in literal()
233 Some((lifetime, rest)) in lifetime()
255 return Some((inside_of_group, span, after_group)); in group()
271 return Some((inside_of_group, delimiter, span, after_group)); in any_group()
281 return Some((group.clone(), after_group)); in any_group_token()
292 while let Some((tt, rest)) = cursor.token_tree() { in token_stream()
316 Some((tree, rest)) in token_tree()
370 Some(unsafe { Cursor::create(self.ptr.add(len), self.scope) }) in skip()
[all …]
H A Dpunctuated.rs99 if let Some((value, _punct)) = self.inner.get(index) { in get()
100 Some(value) in get()
111 if let Some((value, _punct)) = self.inner.get_mut(index) { in get_mut()
112 Some(value) in get_mut()
186 self.last = Some(Box::new(value)); in push_value()
223 self.last = Some(Box::new(t)); in pop_punct()
224 Some(p) in pop_punct()
450 if let Some(last) = &self.last { in fmt()
511 punctuated.last = Some(Box::new(a)); in do_extend()
578 (self.len(), Some(self.len())) in size_hint()
[all …]
/linux/rust/zerocopy-derive/derive/
H A Dfrom_bytes.rs27 let mut next_negative_discriminant = Some(0); in find_zero_variant()
42 Some(0) => return Ok(i), in find_zero_variant()
44 Some(n) => *n -= 1, in find_zero_variant()
49 Some((_, Expr::Lit(ExprLit { lit: Lit::Int(int), .. }))) => { in find_zero_variant()
51 Some(0) => return Ok(i), in find_zero_variant()
52 Some(_) => next_negative_discriminant = None, in find_zero_variant()
61 Some((_, Expr::Unary(ExprUnary { op: UnOp::Neg(_), expr, .. }))) => match &**expr { in find_zero_variant()
64 Some(0) => return Ok(i), in find_zero_variant()
66 Some(x) => next_negative_discriminant = Some(x - 1), in find_zero_variant()
/linux/rust/zerocopy-derive/
H A Drepr.rs129 if let Compound(_, Some(Spanned { t: Packed(p), span: _ })) = self { in get_packed()
130 Some(p) in get_packed()
139 if let Compound(_, Some(Spanned { t: Align(n), span })) = self { in get_align()
140 Some(Spanned::new(*n, *span)) in get_align()
155 if let Some(n) = self.get_align().filter(|n| n.t.get() > 1) { in unaligned_validate_no_align_gt_1()
178 Some(p) in get_primitive()
186 matches!(self.get_primitive(), Some(PrimitiveRepr::U8)) in is_u8()
191 matches!(self.get_primitive(), Some(PrimitiveRepr::I8)) in is_i8()
206 if let Some(align) = align { in to_tokens()
401 if let Some(found) = found { in try_from_raw_reprs()
[all …]
/linux/Documentation/ABI/testing/
H A Dsysfs-class-regulator6 Some regulator directories will contain a field called
32 Some regulator directories will contain a field called
96 Some regulator directories will contain a field called
111 Some regulator directories will contain a field called
126 Some regulator directories will contain a field called
151 Some regulator directories will contain a field called
166 Some regulator directories will contain a field called
181 Some regulator directories will contain a field called
196 Some regulator directories will contain a field called
234 Some regulator directories will contain a field called
[all …]
/linux/drivers/android/binder/range_alloc/
H A Dtree.rs67 desc.state = Some((range.state, free_res)); in from_array()
117 Some(state) => &state.0, in debug_print()
160 Some(new_oneway_space) => new_oneway_space, in reserve_new()
172 Some(desc) => { in reserve_new()
180 desc.state = Some(( in reserve_new()
229 Some((DescriptorState::Reserved(reservation), free_node_res)) => { in reservation_abort()
270 Some((_, next)) if next.state.is_none() => { in reservation_abort()
289 Some((_, prev)) if prev.state.is_none() => { in reservation_abort()
313 Some((DescriptorState::Reserved(reservation), free_node_res)) => ( in reservation_commit()
314 Some(( in reservation_commit()
[all …]
/linux/rust/zerocopy/src/
H A Dlayout.rs77 Some(match *self { in try_to_nonzero_elem_size()
80 if let Some(elem_size) = NonZeroUsize::new(elem_size) { in try_to_nonzero_elem_size()
108 Some(min_align) => min_align,
119 Some(max_align) => max_align,
132 Some(max_align) => max_align,
139 Some(max_align) => max_align,
187 Some(align) => align, in new_zst()
216 Some(align) => align, in for_type()
253 Some(align) => align, in for_slice()
347 Some(max_align) => max_align, in extend()
[all …]
/linux/rust/zerocopy/src/pointer/
H A Dptr.rs1431 if let Some(want) = meta { in test()
1447 if let Some(want) = meta { in test()
1487 test::<[$ty], _, N>([Some(0), Some(1), Some(2), Some(3)]);
1488 test::<SliceDst<$ty>, _, N>([Some(0), Some(1), Some(2), Some(3)]);
1490 test::<[$ty], _, N>([None, Some(0), Some(1), Some(2), Some(3)]);
1491 test::<SliceDst<$ty>, _, N>([None, Some(0), Some(1), Some(2), Some(3)]);
1514 ptr.try_cast_into::<$ty, BecauseImmutable>(CastType::Prefix, Some($elems)); in test_try_cast_into_explicit_count()
1515 if let Some(expect) = $expect { in test_try_cast_into_explicit_count()
1531 test!(ZstDst, 8, 0, Some(0)); in test_try_cast_into_explicit_count()
1534 test!(ZstDst, 8, usize::MAX, Some(usize::MAX)); in test_try_cast_into_explicit_count()
[all …]
/linux/samples/rust/
H A Drust_driver_i2c.rs37 const ACPI_ID_TABLE: Option<acpi::IdTable<Self::IdInfo>> = Some(&ACPI_TABLE);
38 const I2C_ID_TABLE: Option<i2c::IdTable<Self::IdInfo>> = Some(&I2C_TABLE);
39 const OF_ID_TABLE: Option<of::IdTable<Self::IdInfo>> = Some(&OF_TABLE);
49 if let Some(info) = info { in probe()
/linux/drivers/android/binder/
H A Derror.rs52 source: Some(source), in from()
67 source: Some(ENOMEM), in from()
76 Some(source) => source.fmt(f), in fmt()
84 Some(source) => source.fmt(f), in fmt()

12345678910>>...26