Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

blocktrans.h 754B

1234567891011121314151617181920212223242526272829303132333435363738
  1. #ifndef _IPXE_BLOCKTRANS_H
  2. #define _IPXE_BLOCKTRANS_H
  3. /** @file
  4. *
  5. * Block device translator
  6. *
  7. */
  8. FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
  9. #include <stdint.h>
  10. #include <ipxe/refcnt.h>
  11. #include <ipxe/interface.h>
  12. #include <ipxe/xferbuf.h>
  13. #include <ipxe/uaccess.h>
  14. /** A block device translator */
  15. struct block_translator {
  16. /** Reference count */
  17. struct refcnt refcnt;
  18. /** Block device interface */
  19. struct interface block;
  20. /** Data transfer interface */
  21. struct interface xfer;
  22. /** Data transfer buffer */
  23. struct xfer_buffer xferbuf;
  24. /** Data buffer */
  25. userptr_t buffer;
  26. /** Block size */
  27. size_t blksize;
  28. };
  29. extern int block_translate ( struct interface *block,
  30. userptr_t buffer, size_t size );
  31. #endif /* _IPXE_BLOCKTRANS_H */