From ac5b3d9640790b99798070fbb011c4b0c100d33e Mon Sep 17 00:00:00 2001 From: Tejal Kudav Date: Fri, 26 Jan 2018 08:18:35 +0530 Subject: gpu: nvgpu: Remove init_state initialization code nvlink core library no longer exposes the set_init_state() interface as it wishes to block init_state changes from endpoint drivers. Now, the core driver is responsible for initializing init_state variables using set_init_state() interface. Hence, we remove this redundant code. Change-Id: I81c4922cf48f7918e69795579b39b7fa0c299644 Signed-off-by: Tejal Kudav Reviewed-on: https://git-master.nvidia.com/r/1646437 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Adeel Raza Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/common/linux/nvlink.c | 8 -------- 1 file changed, 8 deletions(-) (limited to 'drivers') diff --git a/drivers/gpu/nvgpu/common/linux/nvlink.c b/drivers/gpu/nvgpu/common/linux/nvlink.c index eea6eda7..6cf74048 100644 --- a/drivers/gpu/nvgpu/common/linux/nvlink.c +++ b/drivers/gpu/nvgpu/common/linux/nvlink.c @@ -468,8 +468,6 @@ u32 nvgpu_nvlink_probe(struct gk20a *g) g->nvlink.topology_connected_links = BIT(phys_link_id); - mutex_init(&ndev->init_state_mutex); - /* Check that we are in dGPU mode */ if (ndev->device_id != NVLINK_ENDPT_GV100) { nvgpu_err(g, "Local nvlink device is not dGPU"); @@ -477,12 +475,6 @@ u32 nvgpu_nvlink_probe(struct gk20a *g) goto free_nvlink; } - err = nvlink_set_init_state(ndev, NVLINK_DEV_OFF); - if (err) { - nvgpu_err(g, "Error initalizing device state to OFF"); - goto free_nvlink; - } - /* Fill in device struct */ ndev->dev_ops.dev_early_init = nvgpu_nvlink_early_init; ndev->dev_ops.dev_interface_init = nvgpu_nvlink_interface_init; -- cgit v1.2.2