In the PP_OD_EDIT_VDDC_CURVE case the "input_index" variable is capped at
2 but not checked for negative values so it results in an out of bounds
read. This value comes from the user via sysfs.
Fixes: d5bf26539494 ("drm/amd/powerplay: added vega20 overdrive support V3"
; > support to drm_gem_vunmap function because the mapping argument was always
> > NULL together with the object. Make drm_gem_vunmap() functions to handle
> > the NULL pointers better.
> >
> > Reported-by: Dan Carpenter
> > Link: https://lore.kernel.org/dri-d
ffer->handle)
244 drm_mode_destroy_dumb(dev, buffer->handle,
buffer->client->file);
245
246 kfree(buffer);
247 }
regards,
dan carpenter
t6505->bridge.dev);
2719 memset(it6505->dpcd, 0, sizeof(it6505->dpcd));
2720 DRM_DEV_DEBUG_DRIVER(dev, "power off it6505 success!");
2721 }
2722
2723 unlock:
2724 mutex_unlock(&it6505->extcon_lock);
2725 }
regards,
dan carpenter
1008 dmabuf->ops->unpin(attach);
1009 }
1010 list_del(&attach->node);
1011
1012 dma_resv_unlock(dmabuf->resv);
1013
1014 if (dmabuf->ops->detach)
1015 dmabuf->ops->detach(dmabuf, attach);
1016
1017 kfree(attach);
1018 }
regards,
dan carpenter
irtio: implement context init: add
virtio_gpu_fence_event")
Signed-off-by: Dan Carpenter
---
v2: Style change. Use BIT_ULL().
drivers/gpu/drm/virtio/virtgpu_ioctl.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/virtio/virtgpu_ioctl.c
b/drivers/gpu/drm
On Thu, Sep 15, 2022 at 05:45:46PM -0700, Chia-I Wu wrote:
> On Thu, Sep 15, 2022 at 4:14 AM Dan Carpenter
> wrote:
> >
> > The ->ring_idx_mask variable is a u64 so static checkers, Smatch in
> > this case, complain if the BIT() is not also a u64.
> >
> >
irtio: implement context init: add
virtio_gpu_fence_event")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/virtio/virtgpu_ioctl.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/virtio/virtgpu_ioctl.c
b/drivers/gpu/drm/virtio/virtgpu_ioctl.c
index 3b17
There is no need for the "video_size_step" variable.
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/sprd/sprd_dsi.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/sprd/sprd_dsi.c b/drivers/gpu/drm/sprd/sprd_dsi.c
index 12b67a5d5923..c8
This code uses struct_size() but it stores the result in an int so the
integer overflow checks are not effective. Record the types as size_t
to prevent the size from being truncated.
Fixes: bf3c50837506 ("drm/i915/query: Use struct_size() helper")
Signed-off-by: Dan Carpenter
---
I d
-ci/archive/20220830/202208301957.ulaot2oy-...@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-5) 11.3.0
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot
Reported-by: Dan Carpenter
New smatch warnings:
drivers/gpu/drm/i915/gt/uc/intel_guc_slpc.c:497
an explicit error return code to make this unambiguous.
> >
> > Reported-by: Dan Carpenter
> > Signed-off-by: Linus Walleij
>
> Would someone show mercy on this patch and review it so I
> can apply it?
>
> Dan maybe? If it solves the problem you reported.
at the beginning of the commit message,
> - add a correct Fixes tag.
This doesn't fix a bug so the fixes tag is inappropriate.
regards,
dan carpenter
On Thu, Aug 11, 2022 at 04:36:33PM +0530, Arunpravin Paneer Selvam wrote:
> Hi Dan,
>
> drm-misc-fixes doesn't have the updated ttm_bo.c file, we have the updated
> ttm_bo.c version in
> drm-misc-next branch. Please find below for the line number 907.
>
> On 8/11/2
rnel.org but there is no Fixes
tag.
916 ret = ttm_tt_create(bo, true);
917 if (ret)
regards,
dan carpenter
If list_for_each_entry() exits without hitting a break then "pstate"
is not a valid pstate pointer. Introduce a "found" variable instead.
Fixes: 7c8565220697 ("drm/nouveau/clk: implement power state and engine clock
control in core")
Signed-off-by: Dan Carpenter
the code.
>
> >
> > Fixes: 856082f021a2 ("fbdev: defio: fix the pagelist corruption")
>
> Don't agree with such description.
I don't see how you can disagree? Before your patch the
fb_deferred_io_init() did not use info->fix.smem_len and now it does.
regards,
dan carpenter
e pagelist corruption")
Signed-off-by:
Make sure you CC the original author (Chuansheng Liu) so they can review
the bug fix.
Google used to give good guides for how to send a v2 patch but now the
first page is just useless. :/
regards,
dan carpenter
> Signed-off-by: Peter Suti
:
drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c:1177 vmw_translate_mob_ptr() warn:
passing zero to 'PTR_ERR'
drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c:1314 vmw_cmd_dx_bind_query() error:
uninitialized symbol 'vmw_bo'.
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/vmwgfx/vmw
OR: from is NULL but dereferenced.
drivers/android/binder.c:2920:29-33: ERROR: target_thread is NULL but
dereferenced.
drivers/android/binder.c:353:25-35: ERROR: node -> proc is NULL but
dereferenced.
drivers/android/binder.c:4888:16-20: ERROR: t is NULL but dereferenced.
regards,
dan carpenter
bits to support bus format
negotiation")
Signed-off-by: Dan Carpenter
---
v2: initialize the variable instead, this keeps the original error codes.
drivers/gpu/drm/drm_bridge.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/drm_bridge.c b/drivers/
On Tue, Jun 28, 2022 at 09:26:09AM +0200, Boris Brezillon wrote:
> On Tue, 28 Jun 2022 09:59:51 +0300
> Dan Carpenter wrote:
>
> > This works, but technically it uses "num_in_bus_fmts" before it has been
> > initialized so it leads to static checker warnings and p
quot;drm/bridge: Add the necessary bits to support bus format
negotiation")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/drm_bridge.c | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/gpu/drm/drm_bridge.c b/drivers/gpu/drm/drm_bridge.c
index e275b4
On Fri, Jun 24, 2022 at 04:53:25PM +0200, Paul Kocialkowski wrote:
> Hello Dan,
>
> On Tue 14 Jun 22, 15:07, Dan Carpenter wrote:
> > Hello Paul Kocialkowski,
> >
> > The patch efeeaefe9be5: "drm: Add support for the LogiCVC display
> > controller"
The vc4_check_tex_size() function is supposed to return false on error
but this error path accidentally returns -ENODEV (which means true).
Fixes: 30f8c74ca9b7 ("drm/vc4: Warn if some v3d code is run on BCM2711")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/vc4/vc4_validate.c | 2
Return -ENOMEM instead of success if dma_fence_unwrap_merge() fails.
Fixes: ec8d985ff26f ("drm: use dma_fence_unwrap_merge() in drm_syncobj")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/drm_syncobj.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drive
Return -EINVAL if logicvc_layer_formats_lookup() fails. Don't return
success.
Fixes: efeeaefe9be5 ("drm: Add support for the LogiCVC display controller")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/logicvc/logicvc_layer.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/
The "regmap" is supposed to be initialized to NULL but it's used
without being initialized.
Fixes: efeeaefe9be5 ("drm: Add support for the LogiCVC display controller")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/logicvc/logicvc_drm.c | 2 +-
1 file changed, 1
ot;- voffset = 0x%x chunks of 0x%x bytes\n",
voffset,
339 layer_stride);
340 drm_dbg_kms(drm_dev, "- hoffset = 0x%x chunks of 0x%x bytes\n",
hoffset,
341 layer_bytespp);
342
343 if (setup) {
344 setup->buffer_sel = buffer_sel;
345 setup->voffset = voffset;
346 setup->hoffset = hoffset;
347 }
348
349 return 0;
350 }
regards,
dan carpenter
On Thu, May 26, 2022 at 03:28:25PM +0100, Matthew Wilcox wrote:
> On Thu, May 26, 2022 at 11:48:32AM +0300, Dan Carpenter wrote:
> > On Thu, May 26, 2022 at 02:16:34AM +0100, Matthew Wilcox wrote:
> > > Bizarre this started showing up now. The recent patch was:
> > >
() and folio_order() are 0-255. I guess because of
the "unsigned char compound_order;" in the struct page.
regards,
dan carpenter
>
> so the RHS here should have unsigned long type. Being able to generate
> the cpp output would be helpful. That requires the .config.
The heuristic is that "inode->i_blocks" is a u64 but this .config must
be for a 32bit CPU.
I'm just going to turn off all these warnings until I can figure out a
better heuristic.
regards,
dan carpenter
/202205210319.ovui0mkr-...@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-1) 11.3.0
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot
Reported-by: Dan Carpenter
New smatch warnings:
drivers/dma-buf/udmabuf.c:383 udmabuf_dev_init() warn: '&udmabuf_m
se positive. On closing the file @line no:567, it
> > ends up calling dma_buf_file_release() which does remove dmabuf from its
> > list.
>
> Yeah, correct as far as I can see. The checker just can't see that the fput
> will cleanup the list.
Yep. Thanks!
I hope that that Smatch will be better at parsing the fput() by the end
of the year but right now it doesn't work at all.
regards,
dan carpenter
ULL;
567 fput(file);
568 err_dmabuf:
569 kfree(dmabuf);
dmabuf is freed, but it's still on the list so it leads to a use after
free.
570 err_module:
571 module_put(exp_info->owner);
572 return ERR_PTR(ret);
573 }
regards,
dan carpenter
On Mon, May 09, 2022 at 07:48:23AM -0700, Rob Clark wrote:
> On Sun, May 8, 2022 at 11:28 PM Dan Carpenter
> wrote:
> > 407 } else {
> > 408 /*
> > 409 * We couldn't attribute this fault to any
> &
/202205112132.fqtvzlwa-...@intel.com/config)
compiler: hppa-linux-gcc (GCC) 11.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot
Reported-by: Dan Carpenter
smatch warnings:
drivers/gpu/drm/virtio/virtgpu_plane.c:158 virtio_gpu_resource_flush() error
This error path needs an unlock before returning.
Fixes: 604be85547ce ("drm/rockchip: Add VOP2 driver")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/rockchip/rockchip_drm_vop2.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_vop2.c
b/d
260
261 if (!conn_state || !conn_state->connector) {
262 DPU_ERROR("invalid connector state\n");
263 return -EINVAL;
264 } else if (conn_state->connector->status !=
265 connector_status_connected) {
regards,
dan carpenter
l the rings with the latest and greatest fence..
this
425 * needs to happen after msm_rd_dump_submit() to ensure that the
426 * bo's referenced by the offending submit are still around.
427 */
regards,
dan carpenter
.eyvqwrst-...@intel.com/config)
compiler: gcc-11 (Debian 11.2.0-20) 11.2.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot
Reported-by: Dan Carpenter
smatch warnings:
drivers/gpu/drm/mgag200/mgag200_mode.c:819 mgag200_vga_connector_init() error
The msm_gem_prime_get_sg_table() needs to return error pointers on
error. This is called from drm_gem_map_dma_buf() and returning a
NULL will lead to a crash in that function.
Fixes: ac45146733b0 ("drm/msm: fix msm_gem_prime_get_sg_table()")
Signed-off-by: Dan Carpenter
---
drivers/g
The "dsi->bus_clk" pointer cannot be an error pointer at this point.
The check is confusing and unnecessary. Delete it.
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/
-...@intel.com/config)
compiler: gcc-11 (Debian 11.2.0-20) 11.2.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot
Reported-by: Dan Carpenter
New smatch warnings:
drivers/video/fbdev/core/fbmem.c:1389 fb_mmap() warn: inconsistent returns
'
If the kzalloc() fails then this code will crash. Return -ENOMEM instead.
Fixes: e50d9ba0d2cd ("drm/amdgpu: Add debugfs TA load/unload/invoke support")
Signed-off-by: Dan Carpenter
---
This would look nicer as:
shared_buf = memdup_user(&buf[copy_pos], shared_buf_le
d2cd ("drm/amdgpu: Add debugfs TA load/unload/invoke support")
Signed-off-by: Dan Carpenter
---
There are a bunch of exit paths where copy_from_user() fails and this
function returns -EINVAL which is wrong as well. If the copy fails it
should be -EFAULT. If the data is bad, then -EINVA
260
261 WARN_ON(ret);
262 }
regards,
dan carpenter
e/20220413/202204130935.urqkcdrg-...@intel.com/config)
compiler: arc-elf-gcc (GCC) 11.2.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot
Reported-by: Dan Carpenter
smatch warnings:
drivers/soc/mediatek/mtk-mmsys.c:315 mtk_mmsys_probe() warn: passi
uninitialized
variable in the caller.
drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c:1314 vmw_cmd_dx_bind_query()
error: uninitialized symbol 'vmw_bo'.
So clean this code up and silence then static checker warnings by
removing the bogus NULL check.
Signed-off-by: Dan Carpenter
---
drivers/gpu/
On Tue, Apr 12, 2022 at 10:01:20AM +0900, Inki Dae wrote:
> Hi Dan Carpenter.
>
> Same patch[1] was posted so I will pick it up.
>
> [1] https://www.spinics.net/lists/arm-kernel/msg967488.html
>
It's not the same. That one returns -EINVAL and mine returns
-EPRO
/202204111055.eteht46w-...@intel.com/config)
compiler: gcc-11 (Debian 11.2.0-19) 11.2.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot
Reported-by: Dan Carpenter
smatch warnings:
drivers/gpu/drm/mxsfb/mxsfb_kms.c:444 mxsfb_crtc_set_crc_source() warn:
variable
The of_drm_find_bridge() does not return error pointers, it returns
NULL on error.
Fixes: dd8b6803bc49 ("exynos: drm: dsi: Attach in_bridge in MIC driver")
Signed-off-by: Dan Carpenter
---
-EPROBE_DEFER is the correct return, right?
drivers/gpu/drm/exynos/exynos_drm_mic.c | 4 ++
drm_kms_helper_poll_init(dev);
127
128 goto finish;
129
130 out_bridge:
131 if (panel)
132 drm_panel_bridge_remove(bridge);
133 drm_mode_config_cleanup(dev);
134 finish:
135 return ret;
136 }
regards,
dan carpenter
dup(task->comm, GFP_KERNEL);
> >
> > What?
> >
> > If the first allocation failed, then this one is going to fail as well.
> > Just return -ENOMEM. Or maybe this is meant to be checking for an empty
> > string?
>
> fwiw, if ctx->comm is NULL, the kstrdup() will return NULL, so this
> isn't intended to deal with OoM, but the case that comm and/or cmdline
> is not overridden.
Ah, I should have thought about that. Thanks!
regards,
dan carpenter
NOMEM. Or maybe this is meant to be checking for an empty
string?
> +
> + if (!*cmd)
> + *cmd = kstrdup_quotable_cmdline(task, GFP_KERNEL);
Same.
>
> put_task_struct(task);
> }
regards,
dan carpenter
This post-op should be a pre-op so that we do not pass -1 as the bit
number to test_bit(). The current code will loop downwards from 63 to
-1. After changing to a pre-op, it loops from 63 to 0.
Fixes: 71c37505e7ea ("drm/amdgpu/gfx: move more common KIQ code to
amdgpu_gfx.c")
Signed-o
ning a legal document to say that you have not
stolen anyone else's copyrighted works (SCO lawsuit). So it should be
whatever name you use to sign legal documents.
regards,
dan carpenter
ly other places which
rely on the old behavior.
In an ideal world, with the new API the compiler would warn about
uninitialized variables, but unfortunately that warning is disabled by
default so we still have to rely on kbuild/Clang/Smatch to find the
bugs.
But hopefully the new API encourages people to write clearer code so it
prevents bugs in the long run.
regards,
dan carpenter
These casts need to happen before the shift. The only time it would
matter would be if "rev.core" is >= 128. In that case the sign bit
would be extended and we do not want that.
Fixes: afab9d91d872 ("drm/msm/adreno: Expose speedbin to userspace")
Signed-off-by: Dan Carp
Set the error code to -ENOMEM if drm_random_order() fails.
Fixes: e6ff5ef81170 ("drm/selftests: add drm buddy smoke testcase")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/selftests/test-drm_buddy.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drive
.c
index ddf5737c63d9..c9dffa5c40a2 100644
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -3771,6 +3771,9 @@ EXPORT_SYMBOL(kmem_cache_free_bulk);
*
* Don't free memory not originally allocated by kmalloc()
* or you will run into trouble.
+ *
+ * CHECKER information
+ * frees: $0
*/
void kfree(const void *objp)
{
regards,
dan carpenter
^^^
425
426 for (port = 0; port < r8a66597->max_root_hub; port++) {
427 if (r8a66597->root_hub[port].dev == dev) {
^^^
428 r8a66597->root_hub[port].dev = NULL;
429 break;
430 }
431 }
Printing the freed pointer in debug code is another thing people do.
regards,
dan carpenter
c dma driver")
Signed-off-by: Dan Carpenter
---
sound/soc/qcom/lpass-platform.c | 16 ++--
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/sound/soc/qcom/lpass-platform.c b/sound/soc/qcom/lpass-platform.c
index bf180a594c19..620312529c2f 100644
--- a/sound/soc/
On Mon, Feb 28, 2022 at 10:20:28AM -0800, Joe Perches wrote:
> On Mon, 2022-02-28 at 14:24 +0300, Dan Carpenter wrote:
>
> > a multi-line indent gets curly braces for readability even though
> > it's not required by C. And then both sides would get curly braces.
>
&
een what is a related part of a
patch is a bit vague and some maintainers will ask you to add or subtract
from a patch depending on their individual tastes. I don't really have
an exact answer, but I felt like this patch needs to be subtracted from.
Especially if there is a whole chunk of the patch which can be removed,
then to me, that obviously should be in a different patch.
regards,
dan carpenter
dev_name(&_phy->dev));
> BUG();
> }
> } else {
> - sas_port_create_link(port, phy);
> - list_add_tail(&phy->port_siblings, &port->phy_list);
> + s
nse, but it's out of date now. Just delete it.
> - if (group && &group->list == &rcd->tid_group_list.list)
> + if (!group)
> goto bail_eagain;
> group = list_prepare_entry(group, &rcd->tid_group_list.list,
> list);
regards,
dan carpenter
--
> drivers/media/pci/saa7134/saa7134-alsa.c | 4 ++--
> drivers/perf/xgene_pmu.c | 13 +++--
> 3 files changed, 11 insertions(+), 10 deletions(-)
These are all bug fixes.
1) Send them as 3 separate patches.
2) Add Fixes tags.
regards,
dan carpenter
break;
> + }
> }
> - if (&req->req != _req) {
> + if (!req) {
> ep->stopped = stopped;
> spin_unlock_irqrestore(&ep->dev->lock, flags);
> return -EINVAL;
> @@ -954,7 +957,6 @@ net2272_dequeue(struct usb_ep *_ep, struct usb_request
> *_req)
> dev_dbg(ep->dev->dev, "unlink (%s) pio\n", _ep->name);
> net2272_done(ep, req, -ECONNRESET);
> }
> - req = NULL;
Another unrelated change. These are all good changes but send them as
separate patches.
> ep->stopped = stopped;
>
> spin_unlock_irqrestore(&ep->dev->lock, flags);
regards,
dan carpenter
ata_size);
803if (ret) {
804ret = -EFAULT;
805 goto exit;
806}
regards,
dan carpenter
sonal style is to have the likely part first.
> This makes reading the code easier.
I've thought about this quite a bit... I guess my rule is to avoid
negatives as much as possible so I prefer the original code. My rules
right now are:
1) Always do error handling. Don't do success handling.
2) Return as quickly as possible and pull the code in an indent.
3) Avoid negatives. Never had negatives in the variable names.
regards,
dan carpenter
If copy_to_user() fails, it returns the number of bytes remaining to
be copied but we want to return a negative error code (-EFAULT) to the
user.
Fixes: 9d5dabfeff3c ("drm/amdkfd: CRIU Save Shared Virtual Memory ranges")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/amd/amdkfd/kfd
The kfd_process_device_data_by_id() does not return error pointers,
it returns NULL.
Fixes: bef153b70c6e ("drm/amdkfd: CRIU implement gpu_id remapping")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
di
On Thu, Feb 03, 2022 at 12:29:11PM +0100, Krzysztof Kozlowski wrote:
> On Thu, 3 Feb 2022 at 12:08, Dan Carpenter wrote:
> > >
> > > This does not look like compliant with GPL-2.0. You cannot call a
> > > license GPL-2.0 and restrict it with some other provisions.
shall be included in all copies or substantial portions
> > + * of the Software.
>
> This does not look like compliant with GPL-2.0. You cannot call a
> license GPL-2.0 and restrict it with some other provisions.
That's the MIT license. It's not the GPL-2.0 license but it is
compliant.
regards,
dan carpenter
On Wed, Jan 26, 2022 at 11:31:02PM +0100, Daniel Vetter wrote:
> dOn Wed, Jan 26, 2022 at 3:46 PM Dan Carpenter
> wrote:
> >
> > The other advantage of staging is the I don't think syzbot enables it.
> > I guess it's easier to persuade Dmitry to ignore STA
the kernel.
regards,
dan carpenter
re
> supported by tiny DRM and see about interfaces).
Could we get an exact list?
regards,
dan carpenter
g()
error: potential divide by zero bug '/ rec->dst_width'.
Prevent this by ensuring that the dst height and width are non-zero.
Fixes: 02e792fbaadb ("drm/i915: implement drmmode overlay support v4")
Signed-off-by: Dan Carpenter
---
>From static analysis. Not
1234 kfree(edid);
1235 return ret;
1236 }
1237 drm_connector_update_edid_property(&ast_connector->base, NULL);
1238 return 0;
1239 }
regards,
dan carpenter
On Fri, Dec 17, 2021 at 09:16:19AM +, Steven Price wrote:
> On 17/12/2021 09:10, Dan Carpenter wrote:
> > On Fri, Dec 17, 2021 at 08:55:50AM +, Steven Price wrote:
> >> However this one is harder to fix without setting an arbitrary cap on
> >> the number of B
64 and SIZE_MAX is ULONG_MAX so the (sz > SIZE_MAX) condition
does work to prevent an integer overflow on 32bit systems. But it's not
beautiful.
regards,
dan carpenter
hat is going to be a requirement at
some point.
regards,
dan carpenter
ideally if this could be fixed in a central way, but if not
then hopefully I've added the relevant lists to the CC.
regards,
dan carpenter
The "dp_bridge" pointer is allocated with devm_kzalloc() so it will be
freed automatically. Kfreeing it here will only lead to a double free.
Fixes: 8a3b4c17f863 ("drm/msm/dp: employ bridge mechanism for display enable
and disable")
Signed-off-by: Dan Carpenter
---
dr
return;
160}
161
162drm_atomic_helper_shutdown(drm);
163}
regards,
dan carpenter
; 574 ttm_bo_put(&vmw_bo->base);
^
Smatch thinks it can fail.
575
576 return ret;
577 }
regards,
dan carpenter
The "edid" struct member is only used during probe() and it's freed
right away. There is no point in storing a freed pointer for the
whole life of the driver.
Signed-off-by: Dan Carpenter
---
v2: use __maybe_unused annotation to silence an unused variable warning
depending
pdated all the drivers. But somehow the vc4 chunk from your
patch was dropped. It was *NOT* dropped by Stephen Rothwell. It got
dropped earlier. I am including the `git format-patch -1 ` output
from the commit.
regards,
dan carpenter
>From 4ff22f487f8c26b99cbe1678344595734c001a39 Mon Sep 17
On Mon, Dec 06, 2021 at 12:16:24PM +0100, Thomas Zimmermann wrote:
> Hi
>
> Am 06.12.21 um 11:42 schrieb Dan Carpenter:
> > On Tue, Nov 30, 2021 at 10:52:55AM +0100, Thomas Zimmermann wrote:
> > > GEM helper libraries use struct drm_driver.gem_create_object to let
&g
-...@intel.com/config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot
Reported-by: Dan Carpenter
smatch warnings:
drivers/gpu/drm/ast/ast_mode.c:1231 ast_get_modes() error: uninitialized symbol
'edid'
e and build but it will break
at runtime.
For now, it's only vc4_create_object() which is broken.
regards,
dan carpenter
If "sinfo->config" is not found, then return -ENODEV. Don't
return success.
Fixes: b985172b328a ("video: atmel_lcdfb: add device tree suport")
Signed-off-by: Dan Carpenter
---
drivers/video/fbdev/atmel_lcdfb.c | 11 ++-
1 file changed, 6 insertions(+),
The "edid" struct member is only used during probe() and it's freed
right away. There is no point in storing a freed pointer for the
whole life of the driver.
Signed-off-by: Dan Carpenter
---
drivers/video/fbdev/savage/savagefb.h | 1 -
drivers/video/fbdev/savage/savage
GBIF_SCACHE_CNTL0, (0x1f << 10) |
--> 1480 (1 << 8), (gpu_scid << 10) | (1 << 8));
^^
Uninitialized if llcc_slice_activate() failed.
1481 }
regards,
dan carpenter
This code accidentally returns IS_ERR(), which is 1, instead of
propagating the negative error code. The caller doesn't check for
errors so it doesn't affect run time at all.
Fixes: 566fef1226c1 ("drm/bridge: anx7625: add HDMI audio function")
Signed-off-by: Dan Carpenter
The "offset" is a u32 that comes from the user. The bug is that the
"offset + bytes" operation can have an integer overflow problem which
leads to an out of bounds access.
Fixes: 4d60c5fd3f87 ("drm/i915/gvt: vGPU PCI configuration space
virtualization"
This function returns a bool type so returning -EBUSY is equivalent to
returning true. It should return false instead.
Fixes: 7ae034590cea ("drm/i915/ttm: add tt shmem backend")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/i915/gem/i915_gem_ttm.c | 2 +-
1 file changed, 1 inser
ret)
352 dev_dbg(dev, "Current limit cannot be set on %s: %d\n",
353 boe->vregs[1].supply, ret);
354
355 vreg = boe->vregs[BF060Y8M_VREG_VCI].consumer;
356 ret = regulator_set_current_limit(vreg, 2, 4);
The drm_gem_shmem_get_sg_table() function never returns NULL. It returns
error pointers on error.
Fixes: c66df701e783 ("drm/virtio: switch from ttm to gem shmem helpers")
Signed-off-by: Dan Carpenter
---
v2: I originally sent this patch on 19 Jun 2020 but it was somehow
not appl
301 - 400 of 1506 matches
Mail list logo