Unverified Commit 0e5a9244 authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!11340 soc: hisilicon: Support memory repair driver

Merge Pull Request from: @ci-robot 
 
PR sync from: Junhao He <hejunhao3@huawei.com>
https://mailweb.openeuler.org/hyperkitty/list/kernel@openeuler.org/message/TDSLRHNNFTINAZTKJIRFXZLFZGMSDVA3/ 
Support memory repair driver on Kunpeng SoC.

Junhao He (1):
  config: enable CONFIG_HISI_MEM_RAS by default

Xiaofei Tan (2):
  soc: hisilicon: Support memory repair driver on Kunpeng SoC
  docs: ABI: add ABI document for driver hisi_mem_ras


-- 
2.33.0
 
https://gitee.com/openeuler/kernel/issues/IAO2AR 
 
Link:https://gitee.com/openeuler/kernel/pulls/11340

 

Reviewed-by: default avatarXiaoFei Tan <tanxiaofei@huawei.com>
Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
parents 4999c52f c037a965
Loading
Loading
Loading
Loading
+41 −0
Original line number Diff line number Diff line
What:		/sys/devices/platform/HISI0521:00/memory_type
What:		/sys/devices/platform/HISI0521:00/memory_type_supported
What:		/sys/devices/platform/HISI0521:00/acls_query
What:		/sys/devices/platform/HISI0521:00/acls_repair
What:		/sys/devices/platform/HISI0521:00/sppr_query
What:		/sys/devices/platform/HISI0521:00/sppr_repair
Date:		July 2024
KernelVersion:	6.11
Contact:	Xiaofei Tan <tanxiaofei@huawei.com>
Description:
		The /sys/devices/platform/HISI0521:00/ directory contains
		some attributes about memory repair capability query and execute.

		There are following attributes in this directory:

		================= ==== =========================================
		memory_type:	       (RO) memory type the device managed.
		memory_type_supported: (RO) all memory type device the driver supports.
		acls_query:	       (WO) write with physical address to check if the
					    address support ACLS repair.
					    fails with -EINVAL if input parsing fails.
					    fails with -EIO if PCC message excution failed.
					    fails with -ENXIO if the address doesn't belong this device.
					    fails with -ENOSPC if no ACLS resource left for this address.
		acls_repair:	       (WO) write with physical address to do ACLS repair.
					    fails with -EINVAL if input parsing fails.
					    fails with -EIO if PCC message excution failed.
					    fails with -ENXIO if the address doesn't belong this device.
					    fails with -ENOSPC if no ACLS resource left for this address.
		sppr_query:	       (WO) write with physical address to check if the
					    address support sPPR repair.
					    fails with -EINVAL if input parsing fails.
					    fails with -EIO if PCC message excution failed.
					    fails with -ENXIO if the address doesn't belong this device.
					    fails with -ENOSPC if no ACLS resource left for this address.
		sppr_repair:	       (WO) write with physical address to do sPPR repair.
					    fails with -EINVAL if input parsing fails.
					    fails with -EIO if PCC message excution failed.
					    fails with -ENXIO if the address doesn't belong this device.
					    fails with -ENOSPC if no ACLS resource left for this address.
		================= ==== =========================================
+7 −0
Original line number Diff line number Diff line
@@ -7952,6 +7952,13 @@ F: Documentation/ABI/testing/sysfs-devices-platform-kunpeng_hccs
F:	drivers/soc/hisilicon/kunpeng_hccs.c
F:	drivers/soc/hisilicon/kunpeng_hccs.h
HISILICON KUNPENG SOC MEMORY RAS DRIVER
M:	Xiaofei Tan <tanxiaofei@huawei.com>
S:	Maintained
F:	Documentation/ABI/testing/sysfs-devices-platform-hisi_mem_ras
F:	drivers/soc/hisilicon/hisi_mem_ras.c
F:	drivers/soc/hisilicon/hisi_mem_ras.h
HISILICON LPC BUS DRIVER
M:	john.garry@huawei.com
S:	Maintained
+1 −0
Original line number Diff line number Diff line
@@ -6119,6 +6119,7 @@ CONFIG_HISI_HBMCACHE=m
CONFIG_HISI_HBMDEV_ACLS=y
CONFIG_HISI_L3T=m
CONFIG_HISI_L0=m
CONFIG_HISI_MEM_RAS=m
# end of Hisilicon SoC drivers
# end of SOC (System On Chip) specific Drivers

+14 −0
Original line number Diff line number Diff line
@@ -58,4 +58,18 @@ config HISI_L0
	  for user to alloc and lock memory

	  If not sure say no.

config HISI_MEM_RAS
	tristate "Add RAS support for Hisilicon memory device"
	depends on ACPI
	depends on PCC
	depends on ARM64 || COMPILE_TEST
	help
	  Add RAS driver for Hisilicon memory device to repair hardware error of
	  memory devices in OS side. The driver interacts with firmware through PCC
	  and provides sysfs files as user-mode interfaces.It could support both
	  HBM and DDR memory.

	  If not sure say no.

endmenu
+1 −0
Original line number Diff line number Diff line
@@ -7,3 +7,4 @@ obj-$(CONFIG_ARM64_PBHA) += pbha.o
hisi_l3t-objs			:= hisi_lockdown.o l3t.o
obj-$(CONFIG_HISI_L3T)		+= hisi_l3t.o
obj-$(CONFIG_HISI_L0)		+= hisi_l0.o
obj-$(CONFIG_HISI_MEM_RAS)	+= hisi_mem_ras.o
Loading