linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] scsi: mpt3sas: Don't print sense pool info twice
@ 2023-03-21  6:14 Jerry Snitselaar
  2023-03-24 19:32 ` [PATCH v2] " Jerry Snitselaar
  0 siblings, 1 reply; 3+ messages in thread
From: Jerry Snitselaar @ 2023-03-21  6:14 UTC (permalink / raw)
  To: linux-kernel, linux-scsi
  Cc: Sathya Prakash, Sreekanth Reddy, Suganath Prabu Subramani,
	MPT-FusionLinux.pdl, Martin K. Petersen

_base_allocate_sense_dma_pool() already prints out the sense pool
information, so don't print it a second time after calling it in
_base_allocate_memory_pools(). In addition the version in
_base_allocate_memory_pools() was using the wrong size value, sz,
which was last assigned when doing some nvme calculations instead of
sense_sz to determine the pool size in kilobytes.

Cc: Sathya Prakash <sathya.prakash@broadcom.com>
Cc: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
Cc: Suganath Prabu Subramani <suganath-prabu.subramani@broadcom.com>
Cc: MPT-FusionLinux.pdl@broadcom.com
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
Signed-off-by: Jerry Snitselaar <jsnitsel@redhat.com>
---
 drivers/scsi/mpt3sas/mpt3sas_base.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c
index 2ee9ea57554d..14ae0a9c5d3d 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_base.c
+++ b/drivers/scsi/mpt3sas/mpt3sas_base.c
@@ -6616,11 +6616,6 @@ _base_allocate_memory_pools(struct MPT3SAS_ADAPTER *ioc)
 	else if (rc == -EAGAIN)
 		goto try_32bit_dma;
 	total_sz += sense_sz;
-	ioc_info(ioc,
-	    "sense pool(0x%p)- dma(0x%llx): depth(%d),"
-	    "element_size(%d), pool_size(%d kB)\n",
-	    ioc->sense, (unsigned long long)ioc->sense_dma, ioc->scsiio_depth,
-	    SCSI_SENSE_BUFFERSIZE, sz / 1024);
 	/* reply pool, 4 byte align */
 	sz = ioc->reply_free_queue_depth * ioc->reply_sz;
 	rc = _base_allocate_reply_pool(ioc, sz);
-- 
2.38.1


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

* [PATCH v2] scsi: mpt3sas: Don't print sense pool info twice
  2023-03-21  6:14 [PATCH] scsi: mpt3sas: Don't print sense pool info twice Jerry Snitselaar
@ 2023-03-24 19:32 ` Jerry Snitselaar
  2023-03-25  1:16   ` Martin K. Petersen
  0 siblings, 1 reply; 3+ messages in thread
From: Jerry Snitselaar @ 2023-03-24 19:32 UTC (permalink / raw)
  To: linux-kernel, linux-scsi
  Cc: Sathya Prakash, Sreekanth Reddy, Suganath Prabu Subramani,
	MPT-FusionLinux.pdl, Martin K. Petersen, James E.J. Bottomley

_base_allocate_sense_dma_pool() already prints out the sense pool
information, so don't print it a second time after calling it in
_base_allocate_memory_pools(). In addition the version in
_base_allocate_memory_pools() was using the wrong size value, sz,
which was last assigned when doing some nvme calculations instead of
sense_sz to determine the pool size in kilobytes.

Cc: Sathya Prakash <sathya.prakash@broadcom.com>
Cc: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
Cc: Suganath Prabu Subramani <suganath-prabu.subramani@broadcom.com>
Cc: MPT-FusionLinux.pdl@broadcom.com
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
Cc: "James E.J. Bottomley" <jejb@linux.ibm.com>
Fixes: 970ac2bb70e7 ("scsi: mpt3sas: Force sense buffer allocations to be within same 4 GB region")
Signed-off-by: Jerry Snitselaar <jsnitsel@redhat.com>
---
changes from v1: Add missing Fixes tag, and missed Cc to James

 drivers/scsi/mpt3sas/mpt3sas_base.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c
index 2ee9ea57554d..14ae0a9c5d3d 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_base.c
+++ b/drivers/scsi/mpt3sas/mpt3sas_base.c
@@ -6616,11 +6616,6 @@ _base_allocate_memory_pools(struct MPT3SAS_ADAPTER *ioc)
 	else if (rc == -EAGAIN)
 		goto try_32bit_dma;
 	total_sz += sense_sz;
-	ioc_info(ioc,
-	    "sense pool(0x%p)- dma(0x%llx): depth(%d),"
-	    "element_size(%d), pool_size(%d kB)\n",
-	    ioc->sense, (unsigned long long)ioc->sense_dma, ioc->scsiio_depth,
-	    SCSI_SENSE_BUFFERSIZE, sz / 1024);
 	/* reply pool, 4 byte align */
 	sz = ioc->reply_free_queue_depth * ioc->reply_sz;
 	rc = _base_allocate_reply_pool(ioc, sz);
-- 
2.38.1


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

* Re: [PATCH v2] scsi: mpt3sas: Don't print sense pool info twice
  2023-03-24 19:32 ` [PATCH v2] " Jerry Snitselaar
@ 2023-03-25  1:16   ` Martin K. Petersen
  0 siblings, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2023-03-25  1:16 UTC (permalink / raw)
  To: linux-kernel, linux-scsi, Jerry Snitselaar
  Cc: Martin K . Petersen, Sathya Prakash, Sreekanth Reddy,
	Suganath Prabu Subramani, MPT-FusionLinux.pdl,
	James E.J. Bottomley

On Fri, 24 Mar 2023 12:32:04 -0700, Jerry Snitselaar wrote:

> _base_allocate_sense_dma_pool() already prints out the sense pool
> information, so don't print it a second time after calling it in
> _base_allocate_memory_pools(). In addition the version in
> _base_allocate_memory_pools() was using the wrong size value, sz,
> which was last assigned when doing some nvme calculations instead of
> sense_sz to determine the pool size in kilobytes.
> 
> [...]

Applied to 6.3/scsi-fixes, thanks!

[1/1] scsi: mpt3sas: Don't print sense pool info twice
      https://git.kernel.org/mkp/scsi/c/d684a7a26f7d

-- 
Martin K. Petersen	Oracle Linux Engineering

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

end of thread, other threads:[~2023-03-25  1:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-21  6:14 [PATCH] scsi: mpt3sas: Don't print sense pool info twice Jerry Snitselaar
2023-03-24 19:32 ` [PATCH v2] " Jerry Snitselaar
2023-03-25  1:16   ` Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).