vivekku
bd5ab81ccc
gpu: nvgpu: nvs: queue direction update
...
Changes:
- update nvgpu_nvs_ctrl_queue to have queue direction as it is required
by gsp scheduler to erase queue individually
- queue direction is updated during ioctl call to create queue and is
used only by gsp scheduler. So no other moduler should be affected by
it.
- need to pass the size of struct which is u32 so downgrading it from
u64 to u32 is intentional, misra C violation 10.3 can be ignored here
Bug 4027512
Change-Id: I6ef6e4b06124e25da3d004a2d8822516c3ac2105
Signed-off-by: vivekku <vivekku@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2881804
Reviewed-by: svcacv <svcacv@nvidia.com >
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
2023-05-08 23:37:56 -07:00
vivekku
ce4293ab20
gpu: nvgpu: gsp: disabling multiple gsp firmware read
...
Changes:
- disabled gsp firmware release during railgating
- firmware read happen only during power on
Bug 3935433
Change-Id: I9156c015ab7f90ab640c33ca99dc7f3e289b7659
Signed-off-by: vivekku <vivekku@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2870170
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2023-03-17 03:56:36 -07:00
vivekku
9773e7ca68
gpu: nvgpu: gsp: erase queue command for safety scheduler
...
Changes:
- implemented erase queue command for safety scheduler to depopulate
control fifo parameters in safety scheduler FW.
NVGPU-9590
Bug 3935433
Change-Id: I2cd6cd967ac4dba61992dd285e45b18f34dda2ca
Signed-off-by: vivekku <vivekku@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2858533
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2023-03-17 03:55:31 -07:00
vivekku
35960f8f40
gpu: nvgpu: gsp: call runlist update and send ctrl fifo info
...
Changes:
- function calls to add and delete domains
- updating runlist
- integrating control fifo changes with ioctls to send queue info to GSP
FW
Bug 3884011
Change-Id: I5ad29eb9501cc2df66843c074ee6a00aae91af23
Signed-off-by: vivekku <vivekku@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2826482
Reviewed-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
2023-03-17 03:55:08 -07:00
rmylavarapu
0c1fc6bcde
gpu: nvgpu: gsp sched: enable scheduler for embedded-linux
...
NV_BUILD_CONFIGURATION_VARIANT_IS_EMBEDDED is not enabled for embedded
linux and a precise check for embedded-linux should be made for enabling
gsp scheduler on linux platforms.
NVGPU-9297
Change-Id: I2a8fc30670a9a751ecdc051e4f8ca5db8c798595
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2836359
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
2023-01-25 20:09:58 -08:00
rmylavarapu
7bbf10b04a
gpu: nvgpu: gsp: bootstrap gsp scheduler firmware
...
This change will call nvgpu_gsp_sched_bootstrap_hs which will bootstrap
the gsp with gsp scheduler firmware.
NVGPU-9297
Change-Id: If5de945dc7994666fd87ecf99e15ca2014c13573
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2826165
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-12-18 11:43:14 -08:00
vivekku
a92bca9772
gpu: nvgpu: gsp: created cmd for GSP to bind ctx reg
...
Changes
- create command for GSP firmware to bind ctx register.
NVGPU-8730
Change-Id: If92bbbc0169b6466e55f3dff05828b2b649ad3de
Signed-off-by: vivekku <vivekku@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2815472
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-12-13 06:22:02 -08:00
rmylavarapu
01eb416745
gpu: nvgpu: gsp sched: enable gsp sw init for safety build
...
Changes
1. Remove dGPU flag dependency on calling gsp sw init on tot.
2. Created Enable flag for gsp scheduler to enable them on ga10b
platforms.
3. Engine config flag is only enabled for dGPU enabled platforms, as gsp
is using engine functions it need to be enabled for all gsp sched
enabled builds.
4. Changes in gsp_sequence_init/de_init where on qnx we are seeing
issues.
NVGPU-9297
Change-Id: Ia4bce85ae8fd2794da1553e9ea418c76845a10ac
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2822537
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-12-12 06:06:09 -08:00
rmylavarapu
398a30a546
gpu: nvgpu: gsp sched: get the binary file names as per debug fuse
...
Changes
1. Created gsp hal function to read the hardware config register
to tell whether the board is debug fused.
2. Created function to get the binary file names as per debug fuse.
NVGPU-9295
Bug 3897331
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Change-Id: Ia8462aa6f3d8d0d538c06f35245c965e106b3d37
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2822443
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
2022-12-11 19:09:29 -08:00
rmylavarapu
54c2b7a546
gpu: nvgpu: gsp sched: send device info to the gsp fw
...
Change
- It is hard coded to send number of devices info to the gsp depending
on the chip. This CL will auto check the number of devices and send
to the gsp fw according to the chip.
NVGPU-8531
Change-Id: I8890c194121d9164962c2a4ca341244e69bf7f38
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2790015
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
2022-12-01 11:00:50 -08:00
rmylavarapu
e432d2a41c
gpu: nvgpu: gsp: fix update runlist info cmd
...
Current runlist update command uses domain info present in runlist
structure which would be changing depending upon the active domain, this
would cause issue while sending runlist info to the gsp fw. This Cl will
fix the issue by passing the domain parameters to the update runlist
function for sending it to the gsp fw.
NVGPU-8531
Change-Id: Id57b446b55c6e50833376767d672d873a1a9207e
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2803045
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
2022-11-17 02:05:43 -08:00
rmylavarapu
30e7a5e5ed
gpu: nvgpu: gsp sched: create and enable gsp virtual memory access
...
Changes
- Initialize virtual memory for gsp. This space is used for creating
queues for ctrl fifo. Also can be used to ro map sync-pt to this
instance where gsp firmware can poll the sync-pt with sync-pt id.
- Enabled gsp context interface and written the instance block pointer
to nxtctx register for the gsp firmware to access created virtual memory.
- Added required gsp registers for this feature.
NVGPU-8730
Bug 3770916
Change-Id: If538f615eca3f9b7840ffe2787826528b4808886
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2764649
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-10-06 17:16:21 -07:00
vivekku
5bb56723be
gpu: nvgpu: gsp: Create functions to pass nvs data to gsp firmware
...
Changes:
- created functions to populate gsp interface data from nvs and runlist
structures.
- Handled both user domains and shadow domains.
- Provided support for four engines from two.
NVGPU-8531
Signed-off-by: vivekku <vivekku@nvidia.com >
Change-Id: I1d9ec9ded8a9b47a5b2a00c44dacbab22e3b04b1
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2743596
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
2022-10-05 06:18:18 -07:00
vivekku
12b539aa69
gpu: nvgpu: gsp: create nvgpu gsp control fifo interface
...
Changes:
- control fifo file and its build support is done
- Interface to containing control fifo info to be passed to gsp created
- command and function to send fifo info to GSP
NVGPU-8686
NVGPU-8688
NVGPU-8692
Change-Id: I96c59b621ca299f0f4b71e16bd15cad03e719192
Signed-off-by: vivekku <vivekku@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2756560
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com >
Reviewed-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com >
2022-09-29 19:37:51 -07:00
Richard Zhao
1f9fbc85fe
gpu: nvgpu: add nvgpu_hvrtos build
...
- nvgpu_hvrtos disabled bellow configs:
- CONFIG_NVGPU_IVM_BUILD
- CONFIG_NVGPU_TRACE
- CONFIG_NVGPU_SYSFS
- CONFIG_NVGPU_DGPU
- CONFIG_NVGPU_IGPU_VIRT
- CONFIG_NVGPU_NVLINK
- CONFIG_NVGPU_CLK_ARB
- CONFIG_NVGPU_MIG
- nvgpu_hvrtos re-uses posix bitmap.c
- add nvgpu_hvrtos specific headers
- add static check of vgpu ivc frame
- fix build errors caused by new CFLAGS
Jira GVSCI-9976
Signed-off-by: Richard Zhao <rizhao@nvidia.com >
Change-Id: I5f65fda9444d0cbfe6008ac4ab8262b44d1a4f56
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2653745
Reviewed-by: svcacv <svcacv@nvidia.com >
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: Austin Tajiri <atajiri@nvidia.com >
Reviewed-by: Alex Waterman <alexw@nvidia.com >
Reviewed-by: Aparna Das <aparnad@nvidia.com >
GVS: Gerrit_Virtual_Submit
2022-07-28 23:59:10 -07:00
rmylavarapu
bd5ade293d
gpu: nvgpu: gsp: msg: remove event handle support
...
Changes:
- Currently we are not using any event handling between NVGPU and GSP.
So removing the event handler function and directly calling response
handler.
- This change will fix the respective coverity issue.
CID 10138010
Change-Id: I12ddb0012ad9f54bf99f707ab2123598065561d8
Signed-off-by: rmylavarapu <rmylavarapu@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2732628
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-07-15 07:12:52 -07:00
Ramesh Mylavarapu
951ad46819
gpu: nvgpu: gsp: sched: domain management apis
...
Changes:
- Added Domain management APIs with interfaces to communicate with
GSP scheduler.
- Domain creation shall be done inside NVGPU and respective Domain
and runlist info are sent to GSP for scheduling.
Design: https://confluence.nvidia.com/display/TGS/GSP+Scheduler+Interface+Specifications
NVGPU-7371
Signed-off-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Change-Id: Icba7f1ed3b9b2f409aac346084dd9a123c9d3779
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2682686
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-07-05 14:27:00 -07:00
vivekku
1116d90d32
gpu: nvgpu: gsp: enable gsp scheduler debug prints
...
Changes:
- created gsp debug info mask enabled with GSP flag.
- defined a macro to display gsp debug info instead of using
nvgpu_log_fn.
- replaced nvgpu_log_fn with gsp_dbg_info inside gsp_scheduler.
NVGPU-8529
Change-Id: I98f0e470d7f056958a64579fa64c76de5691aefb
Signed-off-by: vivekku <vivekku@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2727812
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-06-17 02:00:58 -07:00
Jinesh Parakh
b8b90f85ee
gpu: nvgpu: Fix CERT-C Violations
...
Fix the following CERT-C Violations:
gsp_runlist.c : CERT EXP34-C
channel_sync_syncpt.c : CERT ERR33-C
grmgr_ga100.c : CERT ERR33-C
grmgr_ga10b.c : CERT ERR33-C
debug.c : CERT ERR33-C
debug_fecs_trace.c : CERT EXP34-C
ioctl.c : CERT ERR33-C
CID 495110
CID 141061
CID 222881
CID 222890
CID 450994
CID 366644
CID 466529
Bug 3512546
Signed-off-by: Jinesh Parakh <jparakh@nvidia.com >
Change-Id: I318a27a6fcb8ea8f6d5d6c1f65d940c48d6f8dfc
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2723008
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: Sagar Kamble <skamble@nvidia.com >
Reviewed-by: Sachin Nikam <snikam@nvidia.com >
GVS: Gerrit_Virtual_Submit
2022-06-03 12:05:26 -07:00
Richard Zhao
1ce899ce46
gpu: nvgpu: fix compile error of new compile flags
...
Preparing to push hvrtos gpu server changes which requires bellow CFLAGS:
-Werror -Wall -Wextra \
-Wmissing-braces -Wpointer-arith -Wundef \
-Wconversion -Wsign-conversion \
-Wformat-security \
-Wmissing-declarations -Wredundant-decls -Wimplicit-fallthrough
Jira GVSCI-11640
Signed-off-by: Richard Zhao <rizhao@nvidia.com >
Change-Id: I25167f17f231ed741f19af87ca0aa72991563a0f
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2653746
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svcacv <svcacv@nvidia.com >
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com >
Reviewed-by: Alex Waterman <alexw@nvidia.com >
GVS: Gerrit_Virtual_Submit
2022-05-07 15:11:49 -07:00
Sagar Kamble
0725a98ea9
gpu: nvgpu: remove array comparison to NULL
...
The queues element in struct nvgpu_gsp_sched is an array. Remove
its comparison against NULL.
CID 10132247
Bug 3460991
Change-Id: I2380cdb9287cc34b54b13fd9c1bab67a4a21a698
Signed-off-by: Sagar Kamble <skamble@nvidia.com >
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2693940
Reviewed-by: svcacv <svcacv@nvidia.com >
Reviewed-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Reviewed-by: Sachin Nikam <snikam@nvidia.com >
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com >
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com >
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com >
GVS: Gerrit_Virtual_Submit
2022-04-14 17:02:58 -07:00
Ramesh Mylavarapu
2a98d20263
nvgpu: ga10b: gsp: implement runlist submit apis
...
- implemented device info cmd to send device info to the gsp for
runlist submission. Currently GSP scheduler support only GR
engine '0' instance.
- implemented runlist submit cmd. GSP firmware will submit the
corresponding runlist by writing into submit registers. This
command is direct replacement of hw_submit ga10b hal for GR engine.
NVGPU-6790
Signed-off-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Change-Id: I5dc573a6ad698fe20b49a3466a8e50b94cae74df
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2608923
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-02-09 00:38:56 -08:00
rmylavarapu
6c1a77dfa9
gpu: nvgpu: gsp: add cmdq/msgq init check
...
- Instead of waiting for mailbox update waiting for cmdq/msgq
initialization request would be the better way to check the
communication between NVGPU and GSP before sending any cmd.
NVGPU-7342
Signed-off-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Change-Id: I6d20764516cee14ad84da7cc9a06c9370675786f
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2650148
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-02-09 00:38:45 -08:00
Ramesh Mylavarapu
e5fd0453cf
gpu: nvgpu: gsp: add priv lockdown release check
...
- NVGPU need to check for priv lockdown release before configuring
any priv registers. In current GSP bootstrap sequence has irq
configuration after GSP engine reset which is causing priv errors.
So irq configuration should be done after GSP firmware releases
priv lockdown.
- Removed clearing irq mask and dest registers before configuring
them as GSP firmware would have done partial irq configuration
before releasing the priv.
NVGPU-7342
Signed-off-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Change-Id: I4b6e83452c051654253e02bfb72330b3d6aec3fd
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2649826
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-02-09 00:38:32 -08:00
Ramesh Mylavarapu
9302b2efee
gpu: nvgpu: gsp units separation
...
Separated gsp unit into three unit:
- GSP unit which holds the core functionality of GSP RISCV core,
bootstrap, interrupt, etc.
- GSP Scheduler to hold the cmd/msg management, IPC, etc.
- GSP Test to hold stress test ucode specific support.
NVGPU-7492
Signed-off-by: Ramesh Mylavarapu <rmylavarapu@nvidia.com >
Change-Id: I12340dc776d610502f28c8574843afc7481c0871
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2660619
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com >
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com >
2022-02-09 00:38:21 -08:00