similar to: [PATCH] drm/nouveau/nvif/mmu: Use struct_size() helper

Displaying 20 results from an estimated 1000 matches similar to: "[PATCH] drm/nouveau/nvif/mmu: Use struct_size() helper"

2019 May 24
1
[PATCH] drm/nouveau/mmu: use struct_size() helper
Make use of the struct_size() helper instead of an open-coded version in order to avoid any potential type mistakes, in particular in the context in which this code is being used. So, replace the following form: sizeof(*kind) + sizeof(*kind->data) * mmu->kind_nr; with: struct_size(kind, data, mmu->kind_nr) This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A.
2019 Dec 17
1
[PATCH] drm/nouveau: Add correct turing page kinds
Turing introduced a new simplified page kind scheme, reducing the number of possible page kinds from 256 to 16. It also is the first NVIDIA GPU in which the highest possible page kind value is not reserved as an "invalid" page kind. To address this, the invalid page kind is made an explicit property of the MMU HAL, and a new table of page kinds is added to the tu102 MMU HAL. One
2019 Jun 19
3
[PATCH] scsi: virtio_scsi: Use struct_size() helper
One of the more common cases of allocation size calculations is finding the size of a structure that has a zero-sized array at the end, along with memory for some number of elements for that array. For example: struct virtio_scsi { ... struct virtio_scsi_vq req_vqs[]; }; Make use of the struct_size() helper instead of an open-coded version in order to avoid any potential type mistakes.
2019 Jun 19
3
[PATCH] scsi: virtio_scsi: Use struct_size() helper
One of the more common cases of allocation size calculations is finding the size of a structure that has a zero-sized array at the end, along with memory for some number of elements for that array. For example: struct virtio_scsi { ... struct virtio_scsi_vq req_vqs[]; }; Make use of the struct_size() helper instead of an open-coded version in order to avoid any potential type mistakes.
2020 Aug 17
0
[PATCH][next] drm/virtio: Use struct_size() helper in kmalloc()
On Wed, Jun 17, 2020 at 04:57:07PM -0500, Gustavo A. R. Silva wrote: > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > > Signed-off-by: Gustavo A. R. Silva <gustavoars at kernel.org> Queued up for
2018 Jun 15
2
[PATCH] drm/nouveau/nvif: remove const attribute from nvif_mclass
Similar to commit 0bf8bf50eddc ("module: Remove const attribute from alias for MODULE_DEVICE_TABLE") Fixes many -Wduplicate-decl-specifier warnings due to the combination of const typeof() of already const variables. Signed-off-by: Nick Desaulniers <ndesaulniers at google.com> --- drivers/gpu/drm/nouveau/include/nvif/object.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
2015 Nov 26
0
[libdrm 09/13] nouveau: import and install a selection of nvif headers from the kernel
From: Ben Skeggs <bskeggs at redhat.com> Signed-off-by: Ben Skeggs <bskeggs at redhat.com> --- include/drm/nouveau_drm.h | 1 + nouveau/Makefile.am | 11 +++- nouveau/libdrm_nouveau.pc.in | 2 +- nouveau/nvif/cl0080.h | 45 ++++++++++++++ nouveau/nvif/cl9097.h | 44 ++++++++++++++ nouveau/nvif/class.h | 141
2018 Jun 15
0
[PATCH] drm/nouveau/nvif: remove const attribute from nvif_mclass
On Fri, Jun 15, 2018 at 3:56 PM Nick Desaulniers <ndesaulniers at google.com> wrote: > > Similar to commit 0bf8bf50eddc ("module: Remove > const attribute from alias for MODULE_DEVICE_TABLE") > > Fixes many -Wduplicate-decl-specifier warnings due to the combination of > const typeof() of already const variables. > > Signed-off-by: Nick Desaulniers
2018 Jun 15
1
[PATCH v2] drm/nouveau/nvif: remove const attribute from nvif_mclass
Similar to commit 0bf8bf50eddc ("module: Remove const attribute from alias for MODULE_DEVICE_TABLE") Fixes many -Wduplicate-decl-specifier warnings due to the combination of const typeof() of already const variables. Signed-off-by: Nick Desaulniers <ndesaulniers at google.com> --- Changes since v1: added additional space after statements.
2019 May 26
0
[PATCH] drm/nouveau: fix nvif/device.h is included more than once
remove duplicate inclusion of nvif/device.h Issue identified by includecheck Signed-off-by: Hariprasad Kelam <hariprasad.kelam at gmail.com> --- drivers/gpu/drm/nouveau/nouveau_drv.h | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_drv.h b/drivers/gpu/drm/nouveau/nouveau_drv.h index 35ff0ca..cfebb14 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drv.h +++
2023 Apr 07
3
[PATCH 2/2] drm/nouveau/kms: Add INHERIT ioctl to nvkm/nvif for reading IOR state
Now that we're supporting things like Ada and the GSP, there's situations where we really need to actually know the display state that we're starting with when loading the driver in order to prevent breaking GSP expectations. The first step in doing this is making it so that we can read the current state of IORs from nvkm in DRM, so that we can fill in said into into the atomic state.
2020 Nov 10
0
[PATCH] drm/nouveau: Fix out-of-bounds access when deferencing MMU type
>-----Original Message----- >From: Thomas Zimmermann <tzimmermann at suse.de> >Sent: Tuesday, November 10, 2020 8:37 AM >To: bskeggs at redhat.com; airlied at linux.ie; daniel at ffwll.ch; Ruhl, Michael J ><michael.j.ruhl at intel.com>; christian.koenig at amd.com >Cc: nouveau at lists.freedesktop.org; dri-devel at lists.freedesktop.org; Thomas >Zimmermann
2015 Jun 08
2
[PATCH RFC 05/20] pm: reorganize the nvif interface
On 8 June 2015 at 06:40, Samuel Pitoiset <samuel.pitoiset at gmail.com> wrote: > This commit introduces the NVIF_IOCTL_NEW_V0_PERFMON class which will be > used in order to query domains, signals and sources. This separates the > querying and the counting interface. Hey Samuel, I've merged patches 1-4 already, I've got some comments on this one, but after they're solved
2015 Dec 28
1
Breakage with nvif?
Hi Ben, Karol and Tom are seeing this on init with a nvif-enabled kernel + libdrm. What are we doing wrong? I think that route == NVIF_IOCTL_V0_ROUTE_NVIF (== 0), while owner is apparently 1, whatever that is. [362619.242238] nouveau: glxgears[6096]:00000000:00000000: ioctl: size 32 [362619.242240] nouveau: glxgears[6096]:00000000:00000000: ioctl: vers 0 type 00 object 0000000000000000 owner 00
2020 Aug 27
0
5.8.4: WARNING at drivers/gpu/drm/nouveau/nvif/vmm.c:68
Hi, I just found this new WARNING in dmesg. Maybe you want to know. I haven't seen this before in 5.7. BR Ortwin [Thu Aug 27 15:40:48 2020] ------------[ cut here ]------------ [Thu Aug 27 15:40:48 2020] WARNING: CPU: 6 PID: 23542 at drivers/gpu/drm/nouveau/nvif/vmm.c:68 nvif_vmm_put+0x65/0x70 [Thu Aug 27 15:40:48 2020] CPU: 6 PID: 23542 Comm: kworker/6:2 Tainted: G T
2020 Nov 20
0
nouveau: WARNING: CPU: 0 PID: 20957 at drivers/gpu/drm/nouveau/nvif/vmm.c:71
[15561.391527] ------------[ cut here ]------------ [15561.391560] WARNING: CPU: 0 PID: 20957 at drivers/gpu/drm/nouveau/nvif/vmm.c:71 nvif_vmm_put+0x4a/0x50 [nouveau] [15561.391562] Modules linked in: nls_utf8(E) isofs(E) fuse(E) msr(E) xt_comment(E) br_netfilter(E) xt_physdev(E) nfnetlink_cthelper(E) nfnetlink(E) ebtable_filter(E) ebtables(E) af_packet(E) bridge(E) stp(E) llc(E) iscsi_ibft(E)
2020 Nov 11
0
[PATCH] drm/nouveau: Fix out-of-bounds access when deferencing MMU type
>-----Original Message----- >From: Thomas Zimmermann <tzimmermann at suse.de> >Sent: Wednesday, November 11, 2020 7:08 AM >To: Ruhl, Michael J <michael.j.ruhl at intel.com>; bskeggs at redhat.com; >airlied at linux.ie; daniel at ffwll.ch; christian.koenig at amd.com >Cc: nouveau at lists.freedesktop.org; dri-devel at lists.freedesktop.org; >Maarten Lankhorst
2020 Mar 03
2
[PATCH v2] nouveau/hmm: map pages after migration
When memory is migrated to the GPU, it is likely to be accessed by GPU code soon afterwards. Instead of waiting for a GPU fault, map the migrated memory into the GPU page tables with the same access permissions as the source CPU page table entries. This preserves copy on write semantics. Signed-off-by: Ralph Campbell <rcampbell at nvidia.com> Cc: Christoph Hellwig <hch at lst.de> Cc:
2020 Nov 10
3
[PATCH] drm/nouveau: Fix out-of-bounds access when deferencing MMU type
The value of struct drm_device.ttm.type_vram can become -1 for unknown types of memory (see nouveau_ttm_init()). This leads to an out-of-bounds error when accessing struct nvif_mmu.type[]: [ 18.304116] ================================================================== [ 18.311649] BUG: KASAN: slab-out-of-bounds in nouveau_ttm_io_mem_reserve+0x17a/0x7e0 [nouveau] [ 18.320415] Read of
2020 Nov 12
0
[PATCH] drm/nouveau: Fix out-of-bounds access when deferencing MMU type
>-----Original Message----- >From: Ben Skeggs <skeggsb at gmail.com> >Sent: Wednesday, November 11, 2020 9:39 PM >To: Ruhl, Michael J <michael.j.ruhl at intel.com> >Cc: Thomas Zimmermann <tzimmermann at suse.de>; bskeggs at redhat.com; >airlied at linux.ie; daniel at ffwll.ch; christian.koenig at amd.com; amd- >gfx at lists.freedesktop.org; nouveau at