From: chenguohua@jari.cn
To: lduncan@suse.com, cleech@redhat.com, michael.christie@oracle.com,
jejb@linux.ibm.com, martin.petersen@oracle.com
Cc: open-iscsi@googlegroups.com, linux-scsi@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: [PATCH] scsi: iscsi: Clean up errors in libiscsi_tcp.c
Date: Wed, 27 Sep 2023 16:31:34 +0800 (GMT+08:00) [thread overview]
Message-ID: <7db9a4b1.889.18ad5c3d0ef.Coremail.chenguohua@jari.cn> (raw)
Fix the following errors reported by checkpatch:
ERROR: "(foo*)" should be "(foo *)"
ERROR: space required before the open parenthesis '('
ERROR: space required before the open brace '{'
Signed-off-by: GuoHua Cheng <chenguohua@jari.cn>
---
drivers/scsi/libiscsi_tcp.c | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/drivers/scsi/libiscsi_tcp.c b/drivers/scsi/libiscsi_tcp.c
index c182aa83f2c9..11b9cd41fc1f 100644
--- a/drivers/scsi/libiscsi_tcp.c
+++ b/drivers/scsi/libiscsi_tcp.c
@@ -462,16 +462,16 @@ void iscsi_tcp_cleanup_task(struct iscsi_task *task)
spin_lock_bh(&tcp_task->queue2pool);
/* flush task's r2t queues */
- while (kfifo_out(&tcp_task->r2tqueue, (void*)&r2t, sizeof(void*))) {
- kfifo_in(&tcp_task->r2tpool.queue, (void*)&r2t,
- sizeof(void*));
+ while (kfifo_out(&tcp_task->r2tqueue, (void *)&r2t, sizeof(void *))) {
+ kfifo_in(&tcp_task->r2tpool.queue, (void *)&r2t,
+ sizeof(void *));
ISCSI_DBG_TCP(task->conn, "pending r2t dropped\n");
}
r2t = tcp_task->r2t;
if (r2t != NULL) {
- kfifo_in(&tcp_task->r2tpool.queue, (void*)&r2t,
- sizeof(void*));
+ kfifo_in(&tcp_task->r2tpool.queue, (void *)&r2t,
+ sizeof(void *));
tcp_task->r2t = NULL;
}
spin_unlock_bh(&tcp_task->queue2pool);
@@ -496,7 +496,7 @@ static int iscsi_tcp_data_in(struct iscsi_conn *conn, struct iscsi_task *task)
* is status.
*/
if (!(rhdr->flags & ISCSI_FLAG_DATA_STATUS))
- iscsi_update_cmdsn(conn->session, (struct iscsi_nopin*)rhdr);
+ iscsi_update_cmdsn(conn->session, (struct iscsi_nopin *)rhdr);
if (tcp_conn->in.datalen == 0)
return 0;
@@ -580,7 +580,7 @@ static int iscsi_tcp_r2t_rsp(struct iscsi_conn *conn, struct iscsi_hdr *hdr)
tcp_task = task->dd_data;
r2tsn = be32_to_cpu(rhdr->r2tsn);
- if (tcp_task->exp_datasn != r2tsn){
+ if (tcp_task->exp_datasn != r2tsn) {
ISCSI_DBG_TCP(conn, "task->exp_datasn(%d) != rhdr->r2tsn(%d)\n",
tcp_task->exp_datasn, r2tsn);
rc = ISCSI_ERR_R2TSN;
@@ -638,7 +638,7 @@ static int iscsi_tcp_r2t_rsp(struct iscsi_conn *conn, struct iscsi_hdr *hdr)
r2t->sent = 0;
tcp_task->exp_datasn = r2tsn + 1;
- kfifo_in(&tcp_task->r2tqueue, (void*)&r2t, sizeof(void*));
+ kfifo_in(&tcp_task->r2tqueue, (void *)&r2t, sizeof(void *));
conn->r2t_pdus_cnt++;
spin_unlock(&tcp_task->pool2queue);
@@ -715,7 +715,7 @@ iscsi_tcp_hdr_dissect(struct iscsi_conn *conn, struct iscsi_hdr *hdr)
ISCSI_DBG_TCP(conn, "opcode 0x%x ahslen %d datalen %d\n",
opcode, ahslen, tcp_conn->in.datalen);
- switch(opcode) {
+ switch (opcode) {
case ISCSI_OP_SCSI_DATA_IN:
spin_lock(&conn->session->back_lock);
task = iscsi_itt_to_ctask(conn, hdr->itt);
@@ -1178,7 +1178,7 @@ int iscsi_tcp_r2tpool_alloc(struct iscsi_session *session)
/* R2T xmit queue */
if (kfifo_alloc(&tcp_task->r2tqueue,
- session->max_r2t * 4 * sizeof(void*), GFP_KERNEL)) {
+ session->max_r2t * 4 * sizeof(void *), GFP_KERNEL)) {
iscsi_pool_free(&tcp_task->r2tpool);
goto r2t_alloc_fail;
}
--
2.17.1
reply other threads:[~2023-09-27 8:33 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=7db9a4b1.889.18ad5c3d0ef.Coremail.chenguohua@jari.cn \
--to=chenguohua@jari.cn \
--cc=cleech@redhat.com \
--cc=jejb@linux.ibm.com \
--cc=lduncan@suse.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
--cc=michael.christie@oracle.com \
--cc=open-iscsi@googlegroups.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
all inboxes | Powered by JetHome®