target_core_tmr.h 1008 B

123456789101112131415161718192021222324252627282930313233343536
  1. #ifndef TARGET_CORE_TMR_H
  2. #define TARGET_CORE_TMR_H
  3. /* fabric independent task management function values */
  4. enum tcm_tmreq_table {
  5. TMR_ABORT_TASK = 1,
  6. TMR_ABORT_TASK_SET = 2,
  7. TMR_CLEAR_ACA = 3,
  8. TMR_CLEAR_TASK_SET = 4,
  9. TMR_LUN_RESET = 5,
  10. TMR_TARGET_WARM_RESET = 6,
  11. TMR_TARGET_COLD_RESET = 7,
  12. TMR_FABRIC_TMR = 255,
  13. };
  14. /* fabric independent task management response values */
  15. enum tcm_tmrsp_table {
  16. TMR_FUNCTION_COMPLETE = 0,
  17. TMR_TASK_DOES_NOT_EXIST = 1,
  18. TMR_LUN_DOES_NOT_EXIST = 2,
  19. TMR_TASK_STILL_ALLEGIANT = 3,
  20. TMR_TASK_FAILOVER_NOT_SUPPORTED = 4,
  21. TMR_TASK_MGMT_FUNCTION_NOT_SUPPORTED = 5,
  22. TMR_FUNCTION_AUTHORIZATION_FAILED = 6,
  23. TMR_FUNCTION_REJECTED = 255,
  24. };
  25. extern struct kmem_cache *se_tmr_req_cache;
  26. extern struct se_tmr_req *core_tmr_alloc_req(struct se_cmd *, void *, u8);
  27. extern void core_tmr_release_req(struct se_tmr_req *);
  28. extern int core_tmr_lun_reset(struct se_device *, struct se_tmr_req *,
  29. struct list_head *, struct se_cmd *);
  30. #endif /* TARGET_CORE_TMR_H */