Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 08da5a32 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
  [SCSI] fix up documentation for change in ->queuecommand to lockless calling
  [SCSI] bfa: rename log_level to bfa_log_level
parents eda4b716 29687512
Loading
Loading
Loading
Loading
+31 −28
Original line number Diff line number Diff line
@@ -1044,9 +1044,9 @@ Details:


/**
 *      queuecommand - queue scsi command, invoke 'done' on completion
 *      queuecommand - queue scsi command, invoke scp->scsi_done on completion
 *      @shost: pointer to the scsi host object
 *      @scp: pointer to scsi command object
 *      @done: function pointer to be invoked on completion
 *
 *      Returns 0 on success.
 *
@@ -1074,42 +1074,45 @@ Details:
 *
 *      Other types of errors that are detected immediately may be
 *      flagged by setting scp->result to an appropriate value,
 *      invoking the 'done' callback, and then returning 0 from this
 *      function. If the command is not performed immediately (and the
 *      LLD is starting (or will start) the given command) then this
 *      function should place 0 in scp->result and return 0.
 *      invoking the scp->scsi_done callback, and then returning 0
 *      from this function. If the command is not performed
 *      immediately (and the LLD is starting (or will start) the given
 *      command) then this function should place 0 in scp->result and
 *      return 0.
 *
 *      Command ownership.  If the driver returns zero, it owns the
 *      command and must take responsibility for ensuring the 'done'
 *      callback is executed.  Note: the driver may call done before
 *      returning zero, but after it has called done, it may not
 *      return any value other than zero.  If the driver makes a
 *      non-zero return, it must not execute the command's done
 *      callback at any time.
 *
 *      Locks: struct Scsi_Host::host_lock held on entry (with "irqsave")
 *             and is expected to be held on return.
 *      command and must take responsibility for ensuring the
 *      scp->scsi_done callback is executed.  Note: the driver may
 *      call scp->scsi_done before returning zero, but after it has
 *      called scp->scsi_done, it may not return any value other than
 *      zero.  If the driver makes a non-zero return, it must not
 *      execute the command's scsi_done callback at any time.
 *
 *      Locks: up to and including 2.6.36, struct Scsi_Host::host_lock
 *             held on entry (with "irqsave") and is expected to be
 *             held on return. From 2.6.37 onwards, queuecommand is
 *             called without any locks held.
 *
 *      Calling context: in interrupt (soft irq) or process context
 *
 *      Notes: This function should be relatively fast. Normally it will
 *      not wait for IO to complete. Hence the 'done' callback is invoked 
 *      (often directly from an interrupt service routine) some time after
 *      this function has returned. In some cases (e.g. pseudo adapter 
 *      drivers that manufacture the response to a SCSI INQUIRY)
 *      the 'done' callback may be invoked before this function returns.
 *      If the 'done' callback is not invoked within a certain period
 *      the SCSI mid level will commence error processing.
 *      If a status of CHECK CONDITION is placed in "result" when the
 *      'done' callback is invoked, then the LLD driver should 
 *      perform autosense and fill in the struct scsi_cmnd::sense_buffer
 *      Notes: This function should be relatively fast. Normally it
 *      will not wait for IO to complete. Hence the scp->scsi_done
 *      callback is invoked (often directly from an interrupt service
 *      routine) some time after this function has returned. In some
 *      cases (e.g. pseudo adapter drivers that manufacture the
 *      response to a SCSI INQUIRY) the scp->scsi_done callback may be
 *      invoked before this function returns.  If the scp->scsi_done
 *      callback is not invoked within a certain period the SCSI mid
 *      level will commence error processing.  If a status of CHECK
 *      CONDITION is placed in "result" when the scp->scsi_done
 *      callback is invoked, then the LLD driver should perform
 *      autosense and fill in the struct scsi_cmnd::sense_buffer
 *      array. The scsi_cmnd::sense_buffer array is zeroed prior to
 *      the mid level queuing a command to an LLD.
 *
 *      Defined in: LLD
 **/
    int queuecommand(struct scsi_cmnd * scp, 
                     void (*done)(struct scsi_cmnd *))
    int queuecommand(struct Scsi_Host *shost, struct scsi_cmnd * scp)


/**
+2 −2
Original line number Diff line number Diff line
@@ -677,7 +677,7 @@ bfa_fcs_fabric_sm_isolated(struct bfa_fcs_fabric_s *fabric,
	bfa_trc(fabric->fcs, event);
	wwn2str(pwwn_ptr, fabric->bport.port_cfg.pwwn);

	BFA_LOG(KERN_INFO, bfad, log_level,
	BFA_LOG(KERN_INFO, bfad, bfa_log_level,
		"Port is isolated due to VF_ID mismatch. "
		"PWWN: %s Port VF_ID: %04x switch port VF_ID: %04x.",
		pwwn_ptr, fabric->fcs->port_vfid,
@@ -1411,7 +1411,7 @@ bfa_fcs_fabric_set_fabric_name(struct bfa_fcs_fabric_s *fabric,
		wwn2str(pwwn_ptr, bfa_fcs_lport_get_pwwn(&fabric->bport));
		wwn2str(fwwn_ptr,
			bfa_fcs_lport_get_fabric_name(&fabric->bport));
		BFA_LOG(KERN_WARNING, bfad, log_level,
		BFA_LOG(KERN_WARNING, bfad, bfa_log_level,
			"Base port WWN = %s Fabric WWN = %s\n",
			pwwn_ptr, fwwn_ptr);
	}
+3 −3
Original line number Diff line number Diff line
@@ -261,7 +261,7 @@ bfa_fcs_itnim_sm_hcb_online(struct bfa_fcs_itnim_s *itnim,
		bfa_fcb_itnim_online(itnim->itnim_drv);
		wwn2str(lpwwn_buf, bfa_fcs_lport_get_pwwn(itnim->rport->port));
		wwn2str(rpwwn_buf, itnim->rport->pwwn);
		BFA_LOG(KERN_INFO, bfad, log_level,
		BFA_LOG(KERN_INFO, bfad, bfa_log_level,
		"Target (WWN = %s) is online for initiator (WWN = %s)\n",
		rpwwn_buf, lpwwn_buf);
		break;
@@ -301,11 +301,11 @@ bfa_fcs_itnim_sm_online(struct bfa_fcs_itnim_s *itnim,
		wwn2str(lpwwn_buf, bfa_fcs_lport_get_pwwn(itnim->rport->port));
		wwn2str(rpwwn_buf, itnim->rport->pwwn);
		if (bfa_fcs_lport_is_online(itnim->rport->port) == BFA_TRUE)
			BFA_LOG(KERN_ERR, bfad, log_level,
			BFA_LOG(KERN_ERR, bfad, bfa_log_level,
			"Target (WWN = %s) connectivity lost for "
			"initiator (WWN = %s)\n", rpwwn_buf, lpwwn_buf);
		else
			BFA_LOG(KERN_INFO, bfad, log_level,
			BFA_LOG(KERN_INFO, bfad, bfa_log_level,
			"Target (WWN = %s) offlined by initiator (WWN = %s)\n",
			rpwwn_buf, lpwwn_buf);
		break;
+5 −5
Original line number Diff line number Diff line
@@ -491,7 +491,7 @@ bfa_fcs_lport_online_actions(struct bfa_fcs_lport_s *port)
	__port_action[port->fabric->fab_type].online(port);

	wwn2str(lpwwn_buf, bfa_fcs_lport_get_pwwn(port));
	BFA_LOG(KERN_INFO, bfad, log_level,
	BFA_LOG(KERN_INFO, bfad, bfa_log_level,
		"Logical port online: WWN = %s Role = %s\n",
		lpwwn_buf, "Initiator");

@@ -512,11 +512,11 @@ bfa_fcs_lport_offline_actions(struct bfa_fcs_lport_s *port)

	wwn2str(lpwwn_buf, bfa_fcs_lport_get_pwwn(port));
	if (bfa_fcs_fabric_is_online(port->fabric) == BFA_TRUE)
		BFA_LOG(KERN_ERR, bfad, log_level,
		BFA_LOG(KERN_ERR, bfad, bfa_log_level,
		"Logical port lost fabric connectivity: WWN = %s Role = %s\n",
		lpwwn_buf, "Initiator");
	else
		BFA_LOG(KERN_INFO, bfad, log_level,
		BFA_LOG(KERN_INFO, bfad, bfa_log_level,
		"Logical port taken offline: WWN = %s Role = %s\n",
		lpwwn_buf, "Initiator");

@@ -573,7 +573,7 @@ bfa_fcs_lport_deleted(struct bfa_fcs_lport_s *port)
	char    lpwwn_buf[BFA_STRING_32];

	wwn2str(lpwwn_buf, bfa_fcs_lport_get_pwwn(port));
	BFA_LOG(KERN_INFO, bfad, log_level,
	BFA_LOG(KERN_INFO, bfad, bfa_log_level,
		"Logical port deleted: WWN = %s Role = %s\n",
		lpwwn_buf, "Initiator");

@@ -878,7 +878,7 @@ bfa_fcs_lport_init(struct bfa_fcs_lport_s *lport,
					vport ? vport->vport_drv : NULL);

	wwn2str(lpwwn_buf, bfa_fcs_lport_get_pwwn(lport));
	BFA_LOG(KERN_INFO, bfad, log_level,
	BFA_LOG(KERN_INFO, bfad, bfa_log_level,
		"New logical port created: WWN = %s Role = %s\n",
		lpwwn_buf, "Initiator");

+3 −3
Original line number Diff line number Diff line
@@ -2056,7 +2056,7 @@ bfa_fcs_rport_online_action(struct bfa_fcs_rport_s *rport)
	wwn2str(lpwwn_buf, bfa_fcs_lport_get_pwwn(port));
	wwn2str(rpwwn_buf, rport->pwwn);
	if (!BFA_FCS_PID_IS_WKA(rport->pid))
		BFA_LOG(KERN_INFO, bfad, log_level,
		BFA_LOG(KERN_INFO, bfad, bfa_log_level,
		"Remote port (WWN = %s) online for logical port (WWN = %s)\n",
		rpwwn_buf, lpwwn_buf);
}
@@ -2075,12 +2075,12 @@ bfa_fcs_rport_offline_action(struct bfa_fcs_rport_s *rport)
	wwn2str(rpwwn_buf, rport->pwwn);
	if (!BFA_FCS_PID_IS_WKA(rport->pid)) {
		if (bfa_fcs_lport_is_online(rport->port) == BFA_TRUE)
			BFA_LOG(KERN_ERR, bfad, log_level,
			BFA_LOG(KERN_ERR, bfad, bfa_log_level,
				"Remote port (WWN = %s) connectivity lost for "
				"logical port (WWN = %s)\n",
				rpwwn_buf, lpwwn_buf);
		else
			BFA_LOG(KERN_INFO, bfad, log_level,
			BFA_LOG(KERN_INFO, bfad, bfa_log_level,
				"Remote port (WWN = %s) offlined by "
				"logical port (WWN = %s)\n",
				rpwwn_buf, lpwwn_buf);
Loading