• Home
  • Raw
  • Download

Lines Matching refs:Alloc

8 use crate::{Alloc, Error, Result};
30 allocs: HashMap<Alloc, (u64, u64, String)>,
71 alloc: Alloc, in allocate_with_align() argument
121 pub fn allocate(&mut self, size: u64, alloc: Alloc, tag: String) -> Result<u64> { in allocate() argument
129 pub fn allocate_at(&mut self, start: u64, size: u64, alloc: Alloc, tag: String) -> Result<()> { in allocate_at() argument
161 pub fn release(&mut self, alloc: Alloc) -> Result<()> { in release()
168 pub fn get(&self, alloc: &Alloc) -> Option<&(u64, u64, String)> { in get()
220 pub fn address_from_pci_offset(&self, alloc: Alloc, offset: u64, size: u64) -> Result<u64> { in address_from_pci_offset() argument
222 Alloc::PciBar { .. } => (), in address_from_pci_offset()
257 alloc: Alloc, in allocate_with_align() argument
271 pub fn allocate(&mut self, size: u64, alloc: Alloc, tag: String) -> Result<u64> { in allocate() argument
282 pub fn allocate_at(&mut self, start: u64, size: u64, alloc: Alloc, tag: String) -> Result<()> { in allocate_at() argument
293 pub fn release(&mut self, alloc: Alloc) -> Result<()> { in release()
304 pub fn get(&self, alloc: &Alloc) -> Option<&(u64, u64, String)> { in get()
314 pub fn address_from_pci_offset(&self, alloc: Alloc, offset: u64, size: u64) -> Result<u64> { in address_from_pci_offset() argument
354 pool.allocate(0x800, Alloc::Anon(0), String::from("bar0")), in allocate_fails_exising_alloc()
358 pool.allocate(0x800, Alloc::Anon(0), String::from("bar0")), in allocate_fails_exising_alloc()
359 Err(Error::ExistingAlloc(Alloc::Anon(0))) in allocate_fails_exising_alloc()
367 pool.allocate(0x800, Alloc::Anon(0), String::from("bar0")), in allocate_fails_not_enough_space()
371 pool.allocate(0x900, Alloc::Anon(1), String::from("bar1")), in allocate_fails_not_enough_space()
375 pool.allocate(0x800, Alloc::Anon(2), String::from("bar2")), in allocate_fails_not_enough_space()
384 pool.allocate(0x10, Alloc::Anon(0), String::from("bar0")), in allocate_with_special_alignment()
388 pool.allocate_at(0x1200, 0x100, Alloc::Anon(1), String::from("bar1")), in allocate_with_special_alignment()
392 pool.allocate_with_align(0x800, Alloc::Anon(2), String::from("bar2"), 0x800), in allocate_with_special_alignment()
401 pool.allocate_at(0x1200, 0x800, Alloc::Anon(0), String::from("bar0")), in allocate_and_split_allocate_at()
405 pool.allocate(0x800, Alloc::Anon(1), String::from("bar1")), in allocate_and_split_allocate_at()
409 pool.allocate(0x600, Alloc::Anon(2), String::from("bar2")), in allocate_and_split_allocate_at()
413 pool.allocate(0x200, Alloc::Anon(3), String::from("bar3")), in allocate_and_split_allocate_at()
422 pool.allocate(0x110, Alloc::Anon(0), String::from("bar0")), in allocate_alignment()
426 pool.allocate(0x100, Alloc::Anon(1), String::from("bar1")), in allocate_alignment()
435 pool.allocate(0x110, Alloc::Anon(0), String::from("bar0")), in allocate_retrieve_alloc()
439 pool.get(&Alloc::Anon(0)), in allocate_retrieve_alloc()
448 pool.allocate_with_align(0x110, Alloc::Anon(0), String::from("bar0"), 0x1), in allocate_with_alignment_allocator_alignment()
452 pool.allocate_with_align(0x100, Alloc::Anon(1), String::from("bar1"), 0x1), in allocate_with_alignment_allocator_alignment()
461 pool.allocate_with_align(0x110, Alloc::Anon(0), String::from("bar0"), 0x100), in allocate_with_alignment_custom_alignment()
465 pool.allocate_with_align(0x100, Alloc::Anon(1), String::from("bar1"), 0x100), in allocate_with_alignment_custom_alignment()
474 pool.allocate_with_align(0x110, Alloc::Anon(0), String::from("bar0"), 0x100), in allocate_with_alignment_no_allocator_alignment()
478 pool.allocate_with_align(0x100, Alloc::Anon(1), String::from("bar1"), 0x100), in allocate_with_alignment_no_allocator_alignment()
487 .allocate_with_align(0x110, Alloc::Anon(0), String::from("bar0"), 200) in allocate_with_alignment_alignment_non_power_of_two()
495 pool.allocate_with_align(0x100, Alloc::Anon(0), String::from("bar0"), 0x100), in allocate_with_release()
498 assert!(pool.release(Alloc::Anon(0)).is_ok()); in allocate_with_release()
500 pool.allocate_with_align(0x1000, Alloc::Anon(0), String::from("bar0"), 0x100), in allocate_with_release()
514 pool.allocate(0x3000, Alloc::Anon(0), String::from("bar0")), in coalescing_and_overlap()
527 pool.allocate(0x1004, Alloc::Anon(0), String::from("bar0")), in coalescing_single_addresses()
535 let pci_bar0 = Alloc::PciBar { in allocate_and_verify_pci_offset()
541 let pci_bar1 = Alloc::PciBar { in allocate_and_verify_pci_offset()
547 let pci_bar2 = Alloc::PciBar { in allocate_and_verify_pci_offset()
553 let anon = Alloc::Anon(1); in allocate_and_verify_pci_offset()