mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-22 17:36:20 +03:00
gpu: nvgpu: coverity-clean nvs sprintf
Cast the return code of sprintf away when creating a scheduling domain device name. While at it, use snprintf just in case. CID 497476 CID 497479 Bug 3512545 Change-Id: I4e26c29b889de4b709d582ec3fdde28c50fca5b9 Signed-off-by: Konsta Hölttä <kholtta@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2681274 Reviewed-by: svcacv <svcacv@nvidia.com> Reviewed-by: Alex Waterman <alexw@nvidia.com> GVS: Gerrit_Virtual_Submit
This commit is contained in:
committed by
mobile promotions
parent
b80b2bdab8
commit
4b4ee3802a
@@ -243,7 +243,7 @@ static int create_domain_dev(struct gk20a *g,
|
||||
return err;
|
||||
}
|
||||
|
||||
sprintf(name, "nvsched-%s", nvs_domain->name);
|
||||
(void) snprintf(name, sizeof(name), "nvsched-%s", nvs_domain->name);
|
||||
|
||||
ioctl->g = g;
|
||||
ioctl->domain = domain;
|
||||
|
||||
Reference in New Issue
Block a user