Re: [Nouveau] [PATCH] In function nvkm_ioctl_map(), the variable "type" could be uninitialized if "nvkm_object_map()" returns error code, however, it does not check the return value and directly use t

2022-01-01 Thread Yizhuo Zhai
Hi Lyude: I appreciate your feedback and I misplaced the commit message to the title, I have modified it and resend the patch. I made my linux development tree a mess, so I sent a brandly new one and cc you. Thanks again for your help: ) On Tue, Nov 16, 2021 at 1:18 PM Lyude Paul wrote: > >

[Nouveau] [RFC PATH 2/3] drm: set fb_modifiers_not_supported flag in legacy drivers

2022-01-01 Thread Tomohito Esaki
Set fb_modifiers_not_supported flag in legacy drivers whose planes support non-linear layouts but does not support modifiers, and replace allow_fb_modifiers with fb_modifiers_not_supported. Signed-off-by: Tomohito Esaki --- drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 6 +++---

[Nouveau] [PATCH] drm/nouveau/core/object: Fix the uninitialized use of "type"

2022-01-01 Thread Yizhuo Zhai
In function nvkm_ioctl_map(), the variable "type" could be uninitialized if "nvkm_object_map()" returns error code, however, it does not check the return value and directly use the "type" in the if statement, which is potentially unsafe. Cc: sta...@vger.kernel.org Fixes: 01326050391c

[Nouveau] [RFC PATCH 0/3] Add support modifiers for drivers whose planes only support linear layout

2022-01-01 Thread Tomohito Esaki
Some drivers whose planes only support linear layout fb do not support format modifiers. These drivers should support modifiers, however the DRM core should handle this rather than open-coding in every driver. In this patch series, these drivers expose format modifiers based on the following

Re: [Nouveau] [PATCH] drm/nouveau: wait for the exclusive fence after the shared ones v2

2022-01-01 Thread Dan Moulding
Tested-by: Dan Moulding Thanks! -- Dan

[Nouveau] [RFC PATH 1/3] drm: add support modifiers for drivers whose planes only support linear layout

2022-01-01 Thread Tomohito Esaki
The LINEAR modifier is advertised as default if a driver doesn't specify modifiers. However, there are legacy drivers such as radeon that do not support modifiers but infer the actual layout of the underlying buffer. Therefore, a new flag not_support_fb_modifires is introduced for these legacy

[Nouveau] [RFC PATH 3/3] drm: replace allow_fb_modifiers with fb_modifiers_not_supported

2022-01-01 Thread Tomohito Esaki
Since almost drivers support fb modifiers, allow_fb_modifiers is replaced with fb_modifiers_not_supported and removed. Signed-off-by: Tomohito Esaki --- drivers/gpu/drm/drm_framebuffer.c| 6 +++--- drivers/gpu/drm/drm_ioctl.c | 2 +-

[Nouveau] [PATCH 1/1] drm/nouveau/device: Get right pgsize_bitmap of iommu_domain

2022-01-01 Thread Lu Baolu
The suported page sizes of an iommu_domain are saved in the pgsize_bitmap field. Retrieve the value from the right place. Fixes: 58fd9375c2c534 ("drm/nouveau/platform: probe IOMMU if present") Signed-off-by: Lu Baolu --- drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c | 2 +- 1 file changed,