public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
To: linux-scsi@vger.kernel.org
Cc: martin.petersen@oracle.com,
	Sreekanth Reddy <sreekanth.reddy@broadcom.com>
Subject: [PATCH 1/1] mpt3sas: Remove usage of dma_get_required_mask api
Date: Fri, 28 Oct 2022 14:46:55 +0530	[thread overview]
Message-ID: <20221028091655.17741-2-sreekanth.reddy@broadcom.com> (raw)
In-Reply-To: <20221028091655.17741-1-sreekanth.reddy@broadcom.com>

[-- Attachment #1: Type: text/plain, Size: 977 bytes --]

Remove the usage of dma_get_required_mask() API.
Directly set the DMA mask to 63/64 if the system
is a 64bit machine.

Signed-off-by: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
---
 drivers/scsi/mpt3sas/mpt3sas_base.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c
index 4e981ccaac41..69061545d9d2 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_base.c
+++ b/drivers/scsi/mpt3sas/mpt3sas_base.c
@@ -2992,8 +2992,7 @@ _base_config_dma_addressing(struct MPT3SAS_ADAPTER *ioc, struct pci_dev *pdev)
 	struct sysinfo s;
 	u64 coherent_dma_mask, dma_mask;
 
-	if (ioc->is_mcpu_endpoint || sizeof(dma_addr_t) == 4 ||
-	    dma_get_required_mask(&pdev->dev) <= DMA_BIT_MASK(32)) {
+	if (ioc->is_mcpu_endpoint || sizeof(dma_addr_t) == 4) {
 		ioc->dma_mask = 32;
 		coherent_dma_mask = dma_mask = DMA_BIT_MASK(32);
 	/* Set 63 bit DMA mask for all SAS3 and SAS35 controllers */
-- 
2.27.0


[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4218 bytes --]

  reply	other threads:[~2022-10-28  9:02 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-28  9:16 [PATCH 0/1] mpt3sas: Remove usage of dma_get_required_mask api Sreekanth Reddy
2022-10-28  9:16 ` Sreekanth Reddy [this message]
2022-10-30 11:52   ` [PATCH 1/1] " Christoph Hellwig
2022-10-30 11:57     ` Christoph Hellwig
2023-01-02 11:17     ` Martin Wilck
2023-01-02 13:06       ` Martin K. Petersen
2023-01-24  9:37         ` Salvatore Bonaccorso
2023-02-22 16:44           ` Salvatore Bonaccorso
2023-02-27 14:07             ` Thorsten Leemhuis
2023-03-03  9:39               ` Linux regression tracking (Thorsten Leemhuis)
2023-03-04  9:16                 ` Salvatore Bonaccorso
2023-03-07  1:39               ` Martin K. Petersen
2023-03-07 15:04                 ` Martin Wilck

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=20221028091655.17741-2-sreekanth.reddy@broadcom.com \
    --to=sreekanth.reddy@broadcom.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.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