scsi: mpt3sas: Force reply buffer allocations to be within same 4 GB region
authorSuganath Prabu S <suganath-prabu.subramani@broadcom.com>
Fri, 5 Mar 2021 10:29:01 +0000 (15:59 +0530)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 19 Mar 2021 02:18:08 +0000 (22:18 -0400)
commit58501fd9375f76369c602a0b751a95d3376878e2
tree2f41542190ec5d569ba1bbcafc8c6c967e933fc7
parent970ac2bb70e79a90eeb75496a523b8f1705d7a8c
scsi: mpt3sas: Force reply buffer allocations to be within same 4 GB region

According to the MPI specification, reply buffers can not cross a 4 GB
boundary.

While allocating, if any buffer crosses the 4 GB boundary, then:

 - Release the already allocated memory pools; and

 - Reallocate them by changing the DMA coherent mask to 32-bit

Link: https://lore.kernel.org/r/20210305102904.7560-5-suganath-prabu.subramani@broadcom.com
Signed-off-by: Suganath Prabu S <suganath-prabu.subramani@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/mpt3sas/mpt3sas_base.c