mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-22 17:36:20 +03:00
gpu: nvgpu: move xve unit sources to hal
This patch moves xve unit sources from common to hal alongwith required arch and makefile updates. JIRA NVGPU-3657 Change-Id: Ie10bcf6f2677ee06c60027efb6d9b8c1d01aab3d Signed-off-by: Sagar Kamble <skamble@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2149495 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Alex Waterman <alexw@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
d5a573db9a
commit
d33db35282
@@ -657,3 +657,11 @@ bios:
|
|||||||
gpu: dgpu
|
gpu: dgpu
|
||||||
sources: [ hal/bios/bios_tu104.c,
|
sources: [ hal/bios/bios_tu104.c,
|
||||||
hal/bios/bios_tu104.h ]
|
hal/bios/bios_tu104.h ]
|
||||||
|
|
||||||
|
xve:
|
||||||
|
safe: yes
|
||||||
|
owner: Alex W
|
||||||
|
gpu: dgpu
|
||||||
|
sources: [ include/nvgpu/xve.h,
|
||||||
|
hal/xve/xve_gp106.c,
|
||||||
|
hal/xve/xve_gp106.h ]
|
||||||
|
|||||||
@@ -8,14 +8,6 @@ init:
|
|||||||
owner: Terje B
|
owner: Terje B
|
||||||
sources: [ include/nvgpu/hal_init.h ]
|
sources: [ include/nvgpu/hal_init.h ]
|
||||||
|
|
||||||
xve:
|
|
||||||
safe: yes
|
|
||||||
owner: Alex W
|
|
||||||
gpu: dgpu
|
|
||||||
sources: [ include/nvgpu/xve.h,
|
|
||||||
common/xve/xve_gp106.c,
|
|
||||||
common/xve/xve_gp106.h ]
|
|
||||||
|
|
||||||
nvlink:
|
nvlink:
|
||||||
safe: yes
|
safe: yes
|
||||||
owner: Tejal K
|
owner: Tejal K
|
||||||
|
|||||||
@@ -67,7 +67,6 @@ nvgpu-y += \
|
|||||||
common/utils/worker.o \
|
common/utils/worker.o \
|
||||||
common/ptimer/ptimer.o \
|
common/ptimer/ptimer.o \
|
||||||
common/perf/perfbuf.o \
|
common/perf/perfbuf.o \
|
||||||
common/xve/xve_gp106.o \
|
|
||||||
common/therm/therm.o \
|
common/therm/therm.o \
|
||||||
common/mc/mc.o \
|
common/mc/mc.o \
|
||||||
common/sync/channel_sync.o \
|
common/sync/channel_sync.o \
|
||||||
@@ -320,7 +319,8 @@ nvgpu-y += \
|
|||||||
hal/bios/bios_tu104.o \
|
hal/bios/bios_tu104.o \
|
||||||
hal/top/top_gm20b.o \
|
hal/top/top_gm20b.o \
|
||||||
hal/top/top_gp106.o \
|
hal/top/top_gp106.o \
|
||||||
hal/top/top_gv100.o
|
hal/top/top_gv100.o \
|
||||||
|
hal/xve/xve_gp106.o
|
||||||
|
|
||||||
|
|
||||||
# Linux specific parts of nvgpu.
|
# Linux specific parts of nvgpu.
|
||||||
|
|||||||
@@ -98,7 +98,6 @@ srcs += common/utils/enabled.c \
|
|||||||
common/mm/nvgpu_sgt.c \
|
common/mm/nvgpu_sgt.c \
|
||||||
common/mm/mm.c \
|
common/mm/mm.c \
|
||||||
common/mm/dma.c \
|
common/mm/dma.c \
|
||||||
common/xve/xve_gp106.c \
|
|
||||||
common/therm/therm.c \
|
common/therm/therm.c \
|
||||||
common/ltc/ltc.c \
|
common/ltc/ltc.c \
|
||||||
common/fbp/fbp.c \
|
common/fbp/fbp.c \
|
||||||
@@ -213,7 +212,8 @@ srcs += common/utils/enabled.c \
|
|||||||
hal/pmu/pmu_gp106.c \
|
hal/pmu/pmu_gp106.c \
|
||||||
hal/pmu/pmu_gv11b.c \
|
hal/pmu/pmu_gv11b.c \
|
||||||
hal/top/top_gm20b.c \
|
hal/top/top_gm20b.c \
|
||||||
hal/top/top_gp106.c
|
hal/top/top_gp106.c \
|
||||||
|
hal/xve/xve_gp106.c
|
||||||
|
|
||||||
# Source files below are functionaly safe (FuSa) and must always be included.
|
# Source files below are functionaly safe (FuSa) and must always be included.
|
||||||
srcs += hal/mm/mm_gv11b_fusa.c \
|
srcs += hal/mm/mm_gv11b_fusa.c \
|
||||||
|
|||||||
@@ -159,9 +159,8 @@
|
|||||||
#include "hal/top/top_gv11b.h"
|
#include "hal/top/top_gv11b.h"
|
||||||
#include "hal/bios/bios_tu104.h"
|
#include "hal/bios/bios_tu104.h"
|
||||||
#include "hal/pramin/pramin_init.h"
|
#include "hal/pramin/pramin_init.h"
|
||||||
|
#include "hal/xve/xve_gp106.h"
|
||||||
|
|
||||||
|
|
||||||
#include "common/xve/xve_gp106.h"
|
|
||||||
#include "common/nvlink/init/device_reginit_gv100.h"
|
#include "common/nvlink/init/device_reginit_gv100.h"
|
||||||
#include "common/nvlink/intr_and_err_handling_gv100.h"
|
#include "common/nvlink/intr_and_err_handling_gv100.h"
|
||||||
#include "hal/nvlink/minion_gv100.h"
|
#include "hal/nvlink/minion_gv100.h"
|
||||||
|
|||||||
@@ -98,7 +98,7 @@ int xve_get_speed_gp106(struct gk20a *g, u32 *xve_link_speed)
|
|||||||
link_speed = xve_link_control_status_link_speed_v(status);
|
link_speed = xve_link_control_status_link_speed_v(status);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Can't use a switch statement becuase switch statements dont work with
|
* Can't use a switch statement because switch statements dont work with
|
||||||
* function calls.
|
* function calls.
|
||||||
*/
|
*/
|
||||||
if (link_speed == xve_link_control_status_link_speed_link_speed_2p5_v()) {
|
if (link_speed == xve_link_control_status_link_speed_link_speed_2p5_v()) {
|
||||||
@@ -204,7 +204,7 @@ static int do_xve_set_speed_gp106(struct gk20a *g, u32 next_link_speed)
|
|||||||
u32 current_link_speed, new_link_speed;
|
u32 current_link_speed, new_link_speed;
|
||||||
u32 dl_mgr, saved_dl_mgr;
|
u32 dl_mgr, saved_dl_mgr;
|
||||||
u32 pl_link_config;
|
u32 pl_link_config;
|
||||||
u32 link_control_status, link_speed_setting, link_width;
|
u32 link_control_status, link_speed_setting = 0U, link_width;
|
||||||
struct nvgpu_timeout timeout;
|
struct nvgpu_timeout timeout;
|
||||||
int attempts = 10, err_status = 0;
|
int attempts = 10, err_status = 0;
|
||||||
|
|
||||||
@@ -283,7 +283,7 @@ static int do_xve_set_speed_gp106(struct gk20a *g, u32 next_link_speed)
|
|||||||
xp_pl_link_config_max_link_rate_8000_mtps_v());
|
xp_pl_link_config_max_link_rate_8000_mtps_v());
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
BUG(); /* Should never be hit. */
|
WARN_ON(true); /* Should never be hit. */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -310,7 +310,7 @@ static int do_xve_set_speed_gp106(struct gk20a *g, u32 next_link_speed)
|
|||||||
pl_link_config |= xp_pl_link_config_target_tx_width_f(
|
pl_link_config |= xp_pl_link_config_target_tx_width_f(
|
||||||
xp_pl_link_config_target_tx_width_x16_v());
|
xp_pl_link_config_target_tx_width_x16_v());
|
||||||
} else {
|
} else {
|
||||||
BUG();
|
WARN_ON(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
xv_sc_dbg(g, LINK_SETTINGS, " pl_link_config = 0x%08x", pl_link_config);
|
xv_sc_dbg(g, LINK_SETTINGS, " pl_link_config = 0x%08x", pl_link_config);
|
||||||
@@ -385,7 +385,7 @@ static int do_xve_set_speed_gp106(struct gk20a *g, u32 next_link_speed)
|
|||||||
* The rest of the driver is probably about to
|
* The rest of the driver is probably about to
|
||||||
* explode...
|
* explode...
|
||||||
*/
|
*/
|
||||||
BUG();
|
WARN_ON(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
link_control_status =
|
link_control_status =
|
||||||
Reference in New Issue
Block a user