STRUCT ISCSI_TRANSPORT(9)
β¨ NAME β¨
struct iscsi_transport β iSCSI Transport template. This is the struct iscsi_transport(9) page from the Kernel API Manual, bestie π
πΈ SYNOPSIS πΈ
Here's the whole struct, verbatim, no cap:
struct iscsi_transport {
struct module *owner;
char *name;
unsigned int caps;
struct iscsi_cls_session *(*create_session) (struct iscsi_endpoint *ep, uint16_t cmds_max, uint16_t qdepth, uint32_t sn);
void (*destroy_session) (struct iscsi_cls_session *session);
struct iscsi_cls_conn *(*create_conn) (struct iscsi_cls_session *sess, uint32_t cid);
void (*unbind_conn) (struct iscsi_cls_conn *conn, bool is_active);
int (*bind_conn) (struct iscsi_cls_session *session, struct iscsi_cls_conn *cls_conn, uint64_t transport_eph, int is_leading);
int (*start_conn) (struct iscsi_cls_conn *conn);
void (*stop_conn) (struct iscsi_cls_conn *conn, int flag);
void (*destroy_conn) (struct iscsi_cls_conn *conn);
int (*set_param) (struct iscsi_cls_conn *conn, enum iscsi_param param, char *buf, int buflen);
int (*get_ep_param) (struct iscsi_endpoint *ep, enum iscsi_param param, char *buf);
int (*get_conn_param) (struct iscsi_cls_conn *conn, enum iscsi_param param, char *buf);
int (*get_session_param) (struct iscsi_cls_session *session, enum iscsi_param param, char *buf);
int (*get_host_param) (struct Scsi_Host *shost, enum iscsi_host_param param, char *buf);
int (*set_host_param) (struct Scsi_Host *shost, enum iscsi_host_param param, char *buf, int buflen);
int (*send_pdu) (struct iscsi_cls_conn *conn, struct iscsi_hdr *hdr, char *data, uint32_t data_size);
void (*get_stats) (struct iscsi_cls_conn *conn, struct iscsi_stats *stats);
int (*init_task) (struct iscsi_task *task);
int (*xmit_task) (struct iscsi_task *task);
void (*cleanup_task) (struct iscsi_task *task);
int (*alloc_pdu) (struct iscsi_task *task, uint8_t opcode);
int (*xmit_pdu) (struct iscsi_task *task);
int (*init_pdu) (struct iscsi_task *task, unsigned int offset, unsigned int count);
void (*parse_pdu_itt) (struct iscsi_conn *conn, itt_t itt, int *index, int *age);
void (*session_recovery_timedout) (struct iscsi_cls_session *session);
struct iscsi_endpoint *(*ep_connect) (struct Scsi_Host *shost, struct sockaddr *dst_addr, int non_blocking);
int (*ep_poll) (struct iscsi_endpoint *ep, int timeout_ms);
void (*ep_disconnect) (struct iscsi_endpoint *ep);
int (*tgt_dscvr) (struct Scsi_Host *shost, enum iscsi_tgt_dscvr type, uint32_t enable, struct sockaddr *dst_addr);
int (*set_path) (struct Scsi_Host *shost, struct iscsi_path *params);
int (*set_iface_param) (struct Scsi_Host *shost, void *data, uint32_t len);
int (*get_iface_param) (struct iscsi_iface *iface, enum iscsi_param_type param_type, int param, char *buf);
umode_t (*attr_is_visible)(int param_type, int param);
int (*bsg_request)(struct bsg_job *job);
int (*send_ping) (struct Scsi_Host *shost, uint32_t iface_num, uint32_t iface_type, uint32_t payload_size, uint32_t pid, struct sockaddr *dst_addr);
int (*get_chap) (struct Scsi_Host *shost, uint16_t chap_tbl_idx, uint32_t *num_entries, char *buf);
int (*delete_chap) (struct Scsi_Host *shost, uint16_t chap_tbl_idx);
int (*set_chap) (struct Scsi_Host *shost, void *data, int len);
int (*get_flashnode_param) (struct iscsi_bus_flash_session *fnode_sess, int param, char *buf);
int (*set_flashnode_param) (struct iscsi_bus_flash_session *fnode_sess, struct iscsi_bus_flash_conn *fnode_conn, void *data, int len);
int (*new_flashnode) (struct Scsi_Host *shost, const char *buf, int len);
int (*del_flashnode) (struct iscsi_bus_flash_session *fnode_sess);
int (*login_flashnode) (struct iscsi_bus_flash_session *fnode_sess, struct iscsi_bus_flash_conn *fnode_conn);
int (*logout_flashnode) (struct iscsi_bus_flash_session *fnode_sess, struct iscsi_bus_flash_conn *fnode_conn);
int (*logout_flashnode_sid) (struct iscsi_cls_session *cls_sess);
int (*get_host_stats) (struct Scsi_Host *shost, char *buf, int len);
u8 (*check_protection)(struct iscsi_task *task, sector_t *sector);
};
π«Ά Members π«Ά
nameβ transport name. Literally the name, bestie.capsβ iSCSI Data-Path capabilities β¨create_sessionβ create new iSCSI session object.destroy_sessionβ destroy existing iSCSI session object.create_connβ create new iSCSI connection.bind_connβ associate this connection with existing iSCSI session and specified transport descriptor.start_connβ set connection to be operational.stop_connβ suspend/recover/terminate connection.destroy_connβ destroy inactive iSCSI connection.set_paramβ set iSCSI parameter. Return0on success,-ENODATAwhenparamis not supported, and a-Exxvalue on other error. Then the page slides right intoget_paramβ get iSCSI parameter. Must return number of bytes copied to buffer on success,-ENODATAwhenparamis not supported, and a-Exxvalue on other error.send_pduβ send iSCSI PDU, Login, Logout, NOP-Out, Reject, Text.init_taskβ Initialize aiscsi_taskand any internal structs. When offloading the data path, this is called fromqueuecommandwith the session lock, or from theiscsi_conn_send_pducontext with the session lock. When not offloading the data path, this is called from thescsi work queuewithout the session lock.xmit_taskβ Requests LLD to transfer cmd task. Returns0or the number of bytes transferred on success, and-Exyzvalue on error. When offloading the data path, this is called fromqueuecommandwith the session lock, or from theiscsi_conn_send_pducontext with the session lock. When not offloading the data path, this is called from thescsi work queuewithout the session lock.cleanup_taskβ requests LLD to fail task. Called with session lock and after the connection has been suspended and terminated during recovery. If called from abort task then connection is not suspended or terminated butsk_callback_lockis held.session_recovery_timedoutβ notify LLD a block during recovery timed out.
π Description π
Template API provided by iSCSI Transport β that's the whole vibe. This struct is the template API that iSCSI Transport hands you, periodt π«Ά
π SEE ALSO π
Kernel file ./include/scsi/scsi_transport_iscsi.h β go peek, iykyk π₯
Signed with love from ./include/scsi, dated October 2026, all about struct iscsi_transport(9) πβ¨π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms