public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Christof Schmitt <christof.schmitt@de.ibm.com>
To: James.Bottomley@HansenPartnership.com
Cc: linux-scsi@vger.kernel.org, linux-s390@vger.kernel.org,
	Martin Peschke <mp3@de.ibm.com>,
	Christof Schmitt <christof.schmitt@de.ibm.com>
Subject: [patch 06/11] zfcp: Rename sbal_last.
Date: Mon, 19 May 2008 12:17:42 +0200	[thread overview]
Message-ID: <20080519101830.223670000@de.ibm.com> (raw)
In-Reply-To: 20080519101736.590943000@de.ibm.com

[-- Attachment #1: zfcp_rename_sbal_last.diff --]
[-- Type: text/plain, Size: 1911 bytes --]

From: Martin Peschke <mp3@de.ibm.com>

sbal_last is confusing, as it is not the last one actually used,
but just a limit. sbal_limit is a better name.

Signed-off-by: Martin Peschke <mp3@de.ibm.com> 
Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com>
---
 drivers/s390/scsi/zfcp_def.h  |    2 +-
 drivers/s390/scsi/zfcp_qdio.c |    8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)

--- a/drivers/s390/scsi/zfcp_def.h	2008-05-19 11:28:32.000000000 +0200
+++ b/drivers/s390/scsi/zfcp_def.h	2008-05-19 11:34:36.000000000 +0200
@@ -851,7 +851,7 @@ struct zfcp_fsf_req {
 	struct zfcp_adapter    *adapter;       /* adapter request belongs to */
 	u8		       sbal_number;    /* nr of SBALs free for use */
 	u8		       sbal_first;     /* first SBAL for this request */
-	u8		       sbal_last;      /* last possible SBAL for
+	u8		       sbal_limit;      /* last possible SBAL for
 						  this reuest */
 	u8		       sbal_curr;      /* current SBAL during creation
 						  of request */
--- a/drivers/s390/scsi/zfcp_qdio.c	2008-05-19 11:22:35.000000000 +0200
+++ b/drivers/s390/scsi/zfcp_qdio.c	2008-05-19 11:34:36.000000000 +0200
@@ -432,9 +432,9 @@ zfcp_qdio_sbal_limit(struct zfcp_fsf_req
 {
 	int count = atomic_read(&fsf_req->adapter->request_queue.free_count);
 	count = min(count, max_sbals);
-	fsf_req->sbal_last  = fsf_req->sbal_first;
-	fsf_req->sbal_last += (count - 1);
-	fsf_req->sbal_last %= QDIO_MAX_BUFFERS_PER_Q;
+	fsf_req->sbal_limit  = fsf_req->sbal_first;
+	fsf_req->sbal_limit += (count - 1);
+	fsf_req->sbal_limit %= QDIO_MAX_BUFFERS_PER_Q;
 }
 
 /**
@@ -455,7 +455,7 @@ zfcp_qdio_sbal_chain(struct zfcp_fsf_req
 	sbale->flags |= SBAL_FLAGS_LAST_ENTRY;
 
 	/* don't exceed last allowed SBAL */
-	if (fsf_req->sbal_curr == fsf_req->sbal_last)
+	if (fsf_req->sbal_curr == fsf_req->sbal_limit)
 		return NULL;
 
 	/* set chaining flag in first SBALE of current SBAL */

-- 

  parent reply	other threads:[~2008-05-19 10:19 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-19 10:17 [patch 00/11] zfcp fixes and improvements Christof Schmitt
2008-05-19 10:17 ` [patch 01/11] zfcp: receiving an unsolicted status can lead to I/O stall Christof Schmitt
2008-05-19 10:17 ` [patch 02/11] zfcp: Fix mempool pointer for GID_PN request allocation Christof Schmitt
2008-05-19 10:17 ` [patch 03/11] zfcp: Fix fsf_status_read return code handling Christof Schmitt
2008-05-19 10:17 ` [patch 04/11] zfcp: Remove some sparse warnings Christof Schmitt
2008-05-19 10:17 ` [patch 05/11] zfcp: Remove field sbal_last from trace record Christof Schmitt
2008-05-19 10:17 ` Christof Schmitt [this message]
2008-05-19 10:17 ` [patch 07/11] zfcp: Rename sbal_curr to sbal_last Christof Schmitt
2008-05-19 10:17 ` [patch 08/11] zfcp: Add information about interrupt to trace Christof Schmitt
2008-05-19 10:17 ` [patch 09/11] zfcp: Refine trace levels of some recovery related events Christof Schmitt
2008-05-19 10:17 ` [patch 10/11] zfcp: remove some __attribute__ ((packed)) Christof Schmitt
2008-05-19 10:17 ` [patch 11/11] zfcp: Fix sparse warning by providing new entry in dbf Christof Schmitt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080519101830.223670000@de.ibm.com \
    --to=christof.schmitt@de.ibm.com \
    --cc=James.Bottomley@HansenPartnership.com \
    --cc=linux-s390@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mp3@de.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox