From: Sukwon Ryoo Date: Wed, 13 Mar 2019 06:32:09 +0000 (+0900) Subject: [ERD][NEUS7920-135] [COMMON]chub: No remove sensorinfo in reset X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=72e3d4e557550d1f3df134773cb91db51860dd71;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git [ERD][NEUS7920-135] [COMMON]chub: No remove sensorinfo in reset When something went wrong during os select, sensorinfo area is swiped out because of reset. So HAL can not get sensorlist. This patch makes IPC area set 0 except sensorinfo area. Change-Id: I667deedbd4ba4b0b190aa46c13f0b3008ca193b3 Signed-off-by: Sukwon Ryoo --- diff --git a/drivers/staging/nanohub/chub.c b/drivers/staging/nanohub/chub.c index a0ecdfc56465..d1de6afc23a3 100644 --- a/drivers/staging/nanohub/chub.c +++ b/drivers/staging/nanohub/chub.c @@ -1138,7 +1138,11 @@ int contexthub_reset(struct contexthub_ipc_info *ipc, bool force_load, enum chub /* image download */ dev_info(ipc->dev, "%s: clear ipc:%p, %d\n", __func__, ipc_get_base(IPC_REG_IPC), ipc_get_offset(IPC_REG_IPC)); - memset_io(ipc_get_base(IPC_REG_IPC), 0x0, ipc_get_offset(IPC_REG_IPC)); + memset_io(ipc_get_base(IPC_REG_IPC_A2C), 0, ipc_get_offset(IPC_REG_IPC_A2C)); + memset_io(ipc_get_base(IPC_REG_IPC_C2A), 0, ipc_get_offset(IPC_REG_IPC_C2A)); + memset_io(ipc_get_base(IPC_REG_IPC_EVT_A2C), 0, ipc_get_offset(IPC_REG_IPC_EVT_A2C)); + memset_io(ipc_get_base(IPC_REG_IPC_EVT_C2A), 0, ipc_get_offset(IPC_REG_IPC_EVT_C2A)); + memset_io(ipc_get_base(IPC_REG_LOG), 0, ipc_get_offset(IPC_REG_LOG)); if (ipc->block_reset || force_load) { ret = contexthub_download_image(ipc, IPC_REG_BL); if (!ret) {