Advertisement
Guest User

Untitled

a guest
Dec 11th, 2017
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.14 KB | None | 0 0
  1. 1. void* init_ring(void* this, uint64_t alignment, IOMapper* mapper, ...) {
  2. 2. ...
  3. 3. IOOptionBits options = kIOMemoryTypeVirtual | kIODirectionOutIn;
  4. 4. IOBufferMemoryDescriptor* desc =
  5. 5. IOBufferMemoryDescriptor::inTaskWithOptions(kernel_task,
  6. 6. options,
  7. 7. capacity,
  8. 8. alignment);
  9. 9. ...
  10. 10. IODMACommand* cmd = IODMACommand::withSpecification(
  11. 11. IODMACommand::OutputLittle64, //outSegFunc
  12. 11. 0, //numAddressBits
  13. 12. 0, //maxSegmentSize
  14. 13. 0, //mappingOptions
  15. 14. 0, //maxTransferSize
  16. 15. 1, //alignment
  17. 16. mapper, //mapper
  18. 17. 0); //refCon
  19. 18 ...
  20. 19. cmd->setMemoryDescriptor(desc, true);
  21. 20. ...
  22. 21. }
  23. function 0xFFFFFFF006D1C074
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement