Date: Tue, 17 May 2016 08:55:22 +0000 (UTC) From: Edward Tomasz Napierala <trasz@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r300040 - in head/sys/dev: cxgbe/cxgbei iscsi Message-ID: <201605170855.u4H8tMbs062632@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: trasz Date: Tue May 17 08:55:21 2016 New Revision: 300040 URL: https://svnweb.freebsd.org/changeset/base/300040 Log: Extend the ICL interface to include the PDU pointer in the task_setup method. This is required for upcoming iSER support. Obtained from: Mellanox Technologies (earlier version) MFC after: 1 month Sponsored by: The FreeBSD Foundation Modified: head/sys/dev/cxgbe/cxgbei/icl_cxgbei.c head/sys/dev/iscsi/icl_conn_if.m head/sys/dev/iscsi/icl_soft.c head/sys/dev/iscsi/icl_wrappers.h head/sys/dev/iscsi/iscsi.c Modified: head/sys/dev/cxgbe/cxgbei/icl_cxgbei.c ============================================================================== --- head/sys/dev/cxgbe/cxgbei/icl_cxgbei.c Tue May 17 08:43:50 2016 (r300039) +++ head/sys/dev/cxgbe/cxgbei/icl_cxgbei.c Tue May 17 08:55:21 2016 (r300040) @@ -777,8 +777,8 @@ icl_cxgbei_conn_close(struct icl_conn *i } int -icl_cxgbei_conn_task_setup(struct icl_conn *ic, struct ccb_scsiio *csio, - uint32_t *task_tagp, void **prvp) +icl_cxgbei_conn_task_setup(struct icl_conn *ic, struct icl_pdu *ip, + struct ccb_scsiio *csio, uint32_t *task_tagp, void **prvp) { void *prv; Modified: head/sys/dev/iscsi/icl_conn_if.m ============================================================================== --- head/sys/dev/iscsi/icl_conn_if.m Tue May 17 08:43:50 2016 (r300039) +++ head/sys/dev/iscsi/icl_conn_if.m Tue May 17 08:55:21 2016 (r300040) @@ -84,6 +84,7 @@ METHOD void close { METHOD int task_setup { struct icl_conn *_ic; + struct icl_pdu *_ip; struct ccb_scsiio *_csio; uint32_t *_task_tag; void **_prvp; Modified: head/sys/dev/iscsi/icl_soft.c ============================================================================== --- head/sys/dev/iscsi/icl_soft.c Tue May 17 08:43:50 2016 (r300039) +++ head/sys/dev/iscsi/icl_soft.c Tue May 17 08:55:21 2016 (r300040) @@ -1424,8 +1424,8 @@ icl_soft_conn_close(struct icl_conn *ic) } int -icl_soft_conn_task_setup(struct icl_conn *ic, struct ccb_scsiio *csio, - uint32_t *task_tagp, void **prvp) +icl_soft_conn_task_setup(struct icl_conn *ic, struct icl_pdu *ip, + struct ccb_scsiio *csio, uint32_t *task_tagp, void **prvp) { return (0); Modified: head/sys/dev/iscsi/icl_wrappers.h ============================================================================== --- head/sys/dev/iscsi/icl_wrappers.h Tue May 17 08:43:50 2016 (r300039) +++ head/sys/dev/iscsi/icl_wrappers.h Tue May 17 08:55:21 2016 (r300040) @@ -106,11 +106,11 @@ icl_conn_close(struct icl_conn *ic) } static inline int -icl_conn_task_setup(struct icl_conn *ic, struct ccb_scsiio *csio, - uint32_t *task_tagp, void **prvp) +icl_conn_task_setup(struct icl_conn *ic, struct icl_pdu *ip, + struct ccb_scsiio *csio, uint32_t *task_tagp, void **prvp) { - return (ICL_CONN_TASK_SETUP(ic, csio, task_tagp, prvp)); + return (ICL_CONN_TASK_SETUP(ic, ip, csio, task_tagp, prvp)); } static inline void Modified: head/sys/dev/iscsi/iscsi.c ============================================================================== --- head/sys/dev/iscsi/iscsi.c Tue May 17 08:43:50 2016 (r300039) +++ head/sys/dev/iscsi/iscsi.c Tue May 17 08:55:21 2016 (r300040) @@ -172,7 +172,8 @@ static void iscsi_poll(struct cam_sim *s static struct iscsi_outstanding *iscsi_outstanding_find(struct iscsi_session *is, uint32_t initiator_task_tag); static struct iscsi_outstanding *iscsi_outstanding_add(struct iscsi_session *is, - union ccb *ccb, uint32_t *initiator_task_tagp); + struct icl_pdu *request, union ccb *ccb, + uint32_t *initiator_task_tagp); static void iscsi_outstanding_remove(struct iscsi_session *is, struct iscsi_outstanding *io); @@ -2012,7 +2013,7 @@ iscsi_outstanding_find_ccb(struct iscsi_ } static struct iscsi_outstanding * -iscsi_outstanding_add(struct iscsi_session *is, +iscsi_outstanding_add(struct iscsi_session *is, struct icl_pdu *request, union ccb *ccb, uint32_t *initiator_task_tagp) { struct iscsi_outstanding *io; @@ -2027,7 +2028,7 @@ iscsi_outstanding_add(struct iscsi_sessi return (NULL); } - error = icl_conn_task_setup(is->is_conn, &ccb->csio, + error = icl_conn_task_setup(is->is_conn, request, &ccb->csio, initiator_task_tagp, &io->io_icl_prv); if (error != 0) { ISCSI_SESSION_WARN(is, @@ -2093,7 +2094,7 @@ iscsi_action_abort(struct iscsi_session initiator_task_tag = is->is_initiator_task_tag++; - io = iscsi_outstanding_add(is, NULL, &initiator_task_tag); + io = iscsi_outstanding_add(is, request, NULL, &initiator_task_tag); if (io == NULL) { icl_pdu_free(request); ccb->ccb_h.status = CAM_RESRC_UNAVAIL; @@ -2152,7 +2153,7 @@ iscsi_action_scsiio(struct iscsi_session } initiator_task_tag = is->is_initiator_task_tag++; - io = iscsi_outstanding_add(is, ccb, &initiator_task_tag); + io = iscsi_outstanding_add(is, request, ccb, &initiator_task_tag); if (io == NULL) { icl_pdu_free(request); if ((ccb->ccb_h.status & CAM_DEV_QFRZN) == 0) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201605170855.u4H8tMbs062632>