summaryrefslogtreecommitdiff
path: root/drivers/platform/x86/intel/vsec.c
diff options
context:
space:
mode:
authorDavid E. Box <david.e.box@linux.intel.com>2025-01-06 20:46:52 +0300
committerIlpo Järvinen <ilpo.jarvinen@linux.intel.com>2025-01-07 18:30:11 +0300
commit1d7461d0c8330689117286169106af6531a747ed (patch)
tree629f51a791252f3506de94fb2ff34b3d717c134f /drivers/platform/x86/intel/vsec.c
parentcc1ff7bc1bb378e7c46992c977b605e97d908801 (diff)
downloadlinux-1d7461d0c8330689117286169106af6531a747ed.tar.xz
platform/x86: intel/pmc: Fix ioremap() of bad address
In pmc_core_ssram_get_pmc(), the physical addresses for hidden SSRAM devices are retrieved from the MMIO region of the primary SSRAM device. If additional devices are not present, the address returned is zero. Currently, the code does not check for this condition, resulting in ioremap() incorrectly attempting to map address 0. Add a check for a zero address and return 0 if no additional devices are found, as it is not an error for the device to be absent. Fixes: a01486dc4bb1 ("platform/x86/intel/pmc: Cleanup SSRAM discovery") Signed-off-by: David E. Box <david.e.box@linux.intel.com> Link: https://lore.kernel.org/r/20250106174653.1497128-1-david.e.box@linux.intel.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Diffstat (limited to 'drivers/platform/x86/intel/vsec.c')
0 files changed, 0 insertions, 0 deletions