PCI: epf-mhi: Make use of the alignment restriction from EPF core
authorManivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Mon, 17 Jul 2023 06:54:54 +0000 (12:24 +0530)
committerKrzysztof Wilczyński <kwilczynski@kernel.org>
Sat, 26 Aug 2023 16:54:45 +0000 (16:54 +0000)
commitd9d9f26f1666b8e4052b7b40b2f17c456da0fba3
treea7c68797b70d5629389700f6624500d6819a4414
parent8cd2b8ce48e52bfda76a04be9aef8c1b176693d9
PCI: epf-mhi: Make use of the alignment restriction from EPF core

Instead of hardcoding the alignment restriction in the EPF_MHI driver, make
use of the info available from the EPF core that reflects the alignment
restriction of the endpoint controller.

For this purpose, let's introduce the get_align_offset() static function.

[kwilczynski: update get_align_offset() to avoid issues on 32-bit architectures]
Link: https://lore.kernel.org/linux-pci/20230717065459.14138-3-manivannan.sadhasivam@linaro.org
Link: https://lore.kernel.org/linux-pci/20230826150626.23309-1-manivannan.sadhasivam@linaro.org
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Krzysztof Wilczyński <kwilczynski@kernel.org>
drivers/pci/endpoint/functions/pci-epf-mhi.c