aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/scsi/zfcp_def.h
diff options
context:
space:
mode:
authorChristof Schmitt <christof.schmitt@de.ibm.com>2008-05-06 05:00:05 -0400
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-06-05 10:23:42 -0400
commitc9615858a81d2424c78b10a2f689ba24b156937c (patch)
tree34af50eaeb958a95d13b4f1b6ec9da7ea89f7024 /drivers/s390/scsi/zfcp_def.h
parent688864e29869a71a8183e4e2f96ccf9f2de1375f (diff)
[SCSI] zfcp: Track fabric and channel latencies provided by FCP adapter
Add the infrastructure to retrieve the fabric and channel latencies from FSF commands for each SCSI command that has been processed. For each unit, the sum, min, max and number of requests is tracked. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/s390/scsi/zfcp_def.h')
-rw-r--r--drivers/s390/scsi/zfcp_def.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/drivers/s390/scsi/zfcp_def.h b/drivers/s390/scsi/zfcp_def.h
index bda8c77b22da..306fcd0cae31 100644
--- a/drivers/s390/scsi/zfcp_def.h
+++ b/drivers/s390/scsi/zfcp_def.h
@@ -708,6 +708,24 @@ struct zfcp_erp_action {
708 struct timer_list timer; 708 struct timer_list timer;
709}; 709};
710 710
711struct fsf_latency_record {
712 u32 min;
713 u32 max;
714 u64 sum;
715};
716
717struct latency_cont {
718 struct fsf_latency_record channel;
719 struct fsf_latency_record fabric;
720 u64 counter;
721};
722
723struct zfcp_latencies {
724 struct latency_cont read;
725 struct latency_cont write;
726 struct latency_cont cmd;
727 spinlock_t lock;
728};
711 729
712struct zfcp_adapter { 730struct zfcp_adapter {
713 struct list_head list; /* list of adapters */ 731 struct list_head list; /* list of adapters */
@@ -723,6 +741,7 @@ struct zfcp_adapter {
723 u32 adapter_features; /* FCP channel features */ 741 u32 adapter_features; /* FCP channel features */
724 u32 connection_features; /* host connection features */ 742 u32 connection_features; /* host connection features */
725 u32 hardware_version; /* of FCP channel */ 743 u32 hardware_version; /* of FCP channel */
744 u16 timer_ticks; /* time int for a tick */
726 struct Scsi_Host *scsi_host; /* Pointer to mid-layer */ 745 struct Scsi_Host *scsi_host; /* Pointer to mid-layer */
727 struct list_head port_list_head; /* remote port list */ 746 struct list_head port_list_head; /* remote port list */
728 struct list_head port_remove_lh; /* head of ports to be 747 struct list_head port_remove_lh; /* head of ports to be
@@ -822,6 +841,7 @@ struct zfcp_unit {
822 struct scsi_device *device; /* scsi device struct pointer */ 841 struct scsi_device *device; /* scsi device struct pointer */
823 struct zfcp_erp_action erp_action; /* pending error recovery */ 842 struct zfcp_erp_action erp_action; /* pending error recovery */
824 atomic_t erp_counter; 843 atomic_t erp_counter;
844 struct zfcp_latencies latencies;
825}; 845};
826 846
827/* FSF request */ 847/* FSF request */