All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/9] qla2xxx: Cleanup for target code.
@ 2016-12-18  9:02 Himanshu Madhani
  2016-12-18  9:02 ` [PATCH 1/9] qla2xxx: Move cmd search out of qla during ABTS Himanshu Madhani
                   ` (9 more replies)
  0 siblings, 10 replies; 23+ messages in thread
From: Himanshu Madhani @ 2016-12-18  9:02 UTC (permalink / raw)
  To: target-devel, bart.vanassche, hch, nab
  Cc: giridhar.malavali, linux-scsi, himanshu.madhani

Hi Christoph, Bart,

I am submitting this reworked series of patches which were consolidated
and modified in a single patch in previous submission. 

Here's link to the patch submitted on Dec 6, 2016.

http://www.spinics.net/lists/target-devel/msg13657.html

The existing code access TCM/LIO structures (i.e.. se_cmd and its members)
across both tcm_qla2xxx as well as in qla2xxx modules. Based on several
customer request as well as internal review, we reorganized the code to move
TCM/LIO specific code to tcm_qla2xxx module. This improved code readability,
manage code better, as well as support multiple target stacks. Earlier submission
provided a wrong impression of adding dead code. We understand your concerns and
so we are resubmitting the patches as multiple patchset as requested. As part
of this effort we have cleaned up some unused code. I've put down more details
related to each patch to help the review.

Patch #1 moves the command search out of qla2xxx driver and moves it to
tcm_qla2xxx, which should be the one who has knowlege of this.

Patch #2 moves task management code close to tcm_qla2xxx.

Patch #3 moves command allocation and free to a callback which can reside 
in tcm_qla2xxx layer.

Patch #4 uses the check for sess pointer being NULL before getting kref. This
consolidation is helpful to prevent system crash. 

Patch #5 moves the check for command residual count from qla2xx to tcm_qla2xxx. 
Also, we converted check into a void function to simplify usage of code instead
of copying same block of code in multiple place.

Patch #6 checks for scsi_status field which in small 

Patch #7 tries to clean up usage of LBA/CDB and moves it to tcm_qla2xxx.

Patch #8 tries to cleanup T10-DIF and moves the error checking logic to tcm_qla2xxx. 

Patch #9 is where we are cleaning up old un-used code related to SRR. This patch also
attempts to cleanly isolate se_cmd access to tcm_qla2xxx layer. 

Overall, as part of this cleanup/re-organization effort we cleanedup more than 490+ 
unused lines of code. Hope this provides better picture.

Please consider them for target-pending. I will be sending rest of the patches
in smaller series for better review.

Thanks,
Himanshu

Quinn Tran (9):
  qla2xxx: Move cmd search out of qla during ABTS
  qla2xxx: Cleanup TMF code translation from qla_target.
  qla2xxx: Move percpu_ida_{alloc|free} to tcm_qla2xxx.
  qla2xxx: Cleanup for sess_kref handling
  qla2xxx: Move Command residual check from qla2xxx to tcm_qla2xxx
  qla2xxx: Remove direct access of scsi_status field in se_cmd
  qla2xxx: Remove direct access to t_task_cdb/t_task_lba field
  qla2xxx: Add T10-DIF opcode/type in qla_tgt_cmd
  qla2xxx: Remove se_cmd struct out of qla_tgt_cmd/qla_tgt_mgmt_cmd

 drivers/scsi/qla2xxx/qla_def.h     |    1 +
 drivers/scsi/qla2xxx/qla_target.c  | 1039 +++++-------------------------------
 drivers/scsi/qla2xxx/qla_target.h  |   36 +-
 drivers/scsi/qla2xxx/tcm_qla2xxx.c |  299 +++++++++--
 drivers/scsi/qla2xxx/tcm_qla2xxx.h |   10 +
 5 files changed, 402 insertions(+), 983 deletions(-)

-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2016-12-20 14:16 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-18  9:02 [PATCH 0/9] qla2xxx: Cleanup for target code Himanshu Madhani
2016-12-18  9:02 ` [PATCH 1/9] qla2xxx: Move cmd search out of qla during ABTS Himanshu Madhani
2016-12-19 15:33   ` Bart Van Assche
2016-12-19 15:59     ` hch
2016-12-19 16:29       ` Bart Van Assche
2016-12-20 14:16         ` hch
2016-12-18  9:02 ` [PATCH 2/9] qla2xxx: Cleanup TMF code translation from qla_target Himanshu Madhani
2016-12-18  9:54   ` Christoph Hellwig
2016-12-18  9:02 ` [PATCH 3/9] qla2xxx: Move percpu_ida_{alloc|free} to tcm_qla2xxx Himanshu Madhani
2016-12-18  9:49   ` Christoph Hellwig
2016-12-18  9:02 ` [PATCH 4/9] qla2xxx: Cleanup for sess_kref handling Himanshu Madhani
2016-12-18  9:49   ` Christoph Hellwig
2016-12-18  9:02 ` [PATCH 5/9] qla2xxx: Move Command residual check from qla2xxx to tcm_qla2xxx Himanshu Madhani
2016-12-18  9:51   ` Christoph Hellwig
2016-12-18  9:02 ` [PATCH 6/9] qla2xxx: Remove direct access of scsi_status field in se_cmd Himanshu Madhani
2016-12-18  9:55   ` Christoph Hellwig
2016-12-18  9:02 ` [PATCH 7/9] qla2xxx: Remove direct access to t_task_cdb/t_task_lba field Himanshu Madhani
2016-12-18  9:51   ` Christoph Hellwig
2016-12-18  9:02 ` [PATCH 8/9] qla2xxx: Add T10-DIF opcode/type in qla_tgt_cmd Himanshu Madhani
2016-12-18  9:52   ` Christoph Hellwig
2016-12-18  9:02 ` [PATCH 9/9] qla2xxx: Remove se_cmd struct out of qla_tgt_cmd/qla_tgt_mgmt_cmd Himanshu Madhani
2016-12-18  9:53   ` Christoph Hellwig
2016-12-18  9:48 ` [PATCH 0/9] qla2xxx: Cleanup for target code Christoph Hellwig

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.