18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */
28c2ecf20Sopenharmony_ci#ifndef ISCSI_TARGET_ERL1_H
38c2ecf20Sopenharmony_ci#define ISCSI_TARGET_ERL1_H
48c2ecf20Sopenharmony_ci
58c2ecf20Sopenharmony_ci#include <linux/types.h>
68c2ecf20Sopenharmony_ci#include <scsi/iscsi_proto.h> /* itt_t */
78c2ecf20Sopenharmony_ci
88c2ecf20Sopenharmony_cistruct iscsi_cmd;
98c2ecf20Sopenharmony_cistruct iscsi_conn;
108c2ecf20Sopenharmony_cistruct iscsi_datain_req;
118c2ecf20Sopenharmony_cistruct iscsi_ooo_cmdsn;
128c2ecf20Sopenharmony_cistruct iscsi_pdu;
138c2ecf20Sopenharmony_cistruct iscsi_session;
148c2ecf20Sopenharmony_ci
158c2ecf20Sopenharmony_ciextern int iscsit_dump_data_payload(struct iscsi_conn *, u32, int);
168c2ecf20Sopenharmony_ciextern int iscsit_create_recovery_datain_values_datasequenceinorder_yes(
178c2ecf20Sopenharmony_ci			struct iscsi_cmd *, struct iscsi_datain_req *);
188c2ecf20Sopenharmony_ciextern int iscsit_create_recovery_datain_values_datasequenceinorder_no(
198c2ecf20Sopenharmony_ci			struct iscsi_cmd *, struct iscsi_datain_req *);
208c2ecf20Sopenharmony_ciextern int iscsit_handle_recovery_datain_or_r2t(struct iscsi_conn *, unsigned char *,
218c2ecf20Sopenharmony_ci			itt_t, u32, u32, u32);
228c2ecf20Sopenharmony_ciextern int iscsit_handle_status_snack(struct iscsi_conn *, itt_t, u32,
238c2ecf20Sopenharmony_ci			u32, u32);
248c2ecf20Sopenharmony_ciextern int iscsit_handle_data_ack(struct iscsi_conn *, u32, u32, u32);
258c2ecf20Sopenharmony_ciextern int iscsit_dataout_datapduinorder_no_fbit(struct iscsi_cmd *, struct iscsi_pdu *);
268c2ecf20Sopenharmony_ciextern int iscsit_recover_dataout_sequence(struct iscsi_cmd *, u32, u32);
278c2ecf20Sopenharmony_ciextern void iscsit_clear_ooo_cmdsns_for_conn(struct iscsi_conn *);
288c2ecf20Sopenharmony_ciextern void iscsit_free_all_ooo_cmdsns(struct iscsi_session *);
298c2ecf20Sopenharmony_ciextern int iscsit_execute_ooo_cmdsns(struct iscsi_session *);
308c2ecf20Sopenharmony_ciextern int iscsit_execute_cmd(struct iscsi_cmd *, int);
318c2ecf20Sopenharmony_ciextern int iscsit_handle_ooo_cmdsn(struct iscsi_session *, struct iscsi_cmd *, u32);
328c2ecf20Sopenharmony_ciextern void iscsit_remove_ooo_cmdsn(struct iscsi_session *, struct iscsi_ooo_cmdsn *);
338c2ecf20Sopenharmony_ciextern void iscsit_handle_dataout_timeout(struct timer_list *t);
348c2ecf20Sopenharmony_ciextern void iscsit_mod_dataout_timer(struct iscsi_cmd *);
358c2ecf20Sopenharmony_ciextern void iscsit_start_dataout_timer(struct iscsi_cmd *, struct iscsi_conn *);
368c2ecf20Sopenharmony_ciextern void iscsit_stop_dataout_timer(struct iscsi_cmd *);
378c2ecf20Sopenharmony_ci
388c2ecf20Sopenharmony_ci#endif /* ISCSI_TARGET_ERL1_H */
39