Re: [PATCH v4 11/14] drm/panthor: Add the driver frontend block

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 23 Jan 2024 17:29:12 +0100
Heiko Stübner <heiko@xxxxxxxxx> wrote:

> Am Montag, 22. Januar 2024, 17:30:42 CET schrieb Boris Brezillon:
> > This is the last piece missing to expose the driver to the outside
> > world.
> > 
> > This is basically a wrapper between the ioctls and the other logical
> > blocks.
> > 
> > v4:
> > - Add an ioctl to let the UMD query the VM state
> > - Fix kernel doc
> > - Let panthor_device_init() call panthor_device_init()
> > - Fix cleanup ordering in the panthor_init() error path
> > - Add Steve's and Liviu's R-b
> > 
> > v3:
> > - Add acks for the MIT/GPL2 relicensing
> > - Fix 32-bit support
> > - Account for panthor_vm and panthor_sched changes
> > - Simplify the resv preparation/update logic
> > - Use a linked list rather than xarray for list of signals.
> > - Simplify panthor_get_uobj_array by returning the newly allocated
> >   array.
> > - Drop the "DOC" for job submission helpers and move the relevant
> >   comments to panthor_ioctl_group_submit().
> > - Add helpers sync_op_is_signal()/sync_op_is_wait().
> > - Simplify return type of panthor_submit_ctx_add_sync_signal() and
> >   panthor_submit_ctx_get_sync_signal().
> > - Drop WARN_ON from panthor_submit_ctx_add_job().
> > - Fix typos in comments.
> > 
> > Co-developed-by: Steven Price <steven.price@xxxxxxx>
> > Signed-off-by: Steven Price <steven.price@xxxxxxx>
> > Signed-off-by: Boris Brezillon <boris.brezillon@xxxxxxxxxxxxx>
> > Acked-by: Steven Price <steven.price@xxxxxxx> # MIT+GPL2 relicensing,Arm
> > Acked-by: Grant Likely <grant.likely@xxxxxxxxxx> # MIT+GPL2 relicensing,Linaro
> > Acked-by: Boris Brezillon <boris.brezillon@xxxxxxxxxxxxx> # MIT+GPL2 relicensing,Collabora
> > Reviewed-by: Steven Price <steven.price@xxxxxxx>
> > Reviewed-by: Liviu Dudau <liviu.dudau@xxxxxxx>
> > ---
> >  drivers/gpu/drm/panthor/panthor_drv.c | 1470 +++++++++++++++++++++++++
> >  1 file changed, 1470 insertions(+)
> >  create mode 100644 drivers/gpu/drm/panthor/panthor_drv.c
> > 
> > diff --git a/drivers/gpu/drm/panthor/panthor_drv.c b/drivers/gpu/drm/panthor/panthor_drv.c
> > new file mode 100644
> > index 000000000000..207aacaccd39
> > --- /dev/null
> > +++ b/drivers/gpu/drm/panthor/panthor_drv.c
> > @@ -0,0 +1,1470 @@
> > +// SPDX-License-Identifier: GPL-2.0 or MIT
> > +/* Copyright 2018 Marty E. Plummer <hanetzer@xxxxxxxxxxxxx> */
> > +/* Copyright 2019 Linaro, Ltd., Rob Herring <robh@xxxxxxxxxx> */
> > +/* Copyright 2019 Collabora ltd. */
> > +
> > +#include <linux/list.h>
> > +#include <linux/module.h>
> > +#include <linux/of_platform.h>
> > +#include <linux/pagemap.h>
> > +#include <linux/pm_runtime.h>  
> 
> @@ -7,6 +7,7 @@
>  #include <linux/module.h>
>  #include <linux/of_platform.h>
>  #include <linux/pagemap.h>
> +#include <linux/platform_device.h>
>  #include <linux/pm_runtime.h>
>  
>  #include <drm/drm_drv.h>
> 
> with v6.8-rc1 this needs a linux/platform_device.h include to keep
> finding struct platform_device and friends

Will add this include in v5.

> 
> [...]
> 
> 
> > +static int panthor_submit_ctx_init(struct panthor_submit_ctx *ctx,
> > +				   struct drm_file *file, u32 job_count)
> > +{
> > +	ctx->jobs = kvmalloc_array(job_count, sizeof(*ctx->jobs),
> > +				   GFP_KERNEL | __GFP_ZERO);
> > +	if (!ctx->jobs)
> > +		return -ENOMEM;
> > +
> > +	ctx->file = file;
> > +	ctx->job_count = job_count;
> > +	INIT_LIST_HEAD(&ctx->signals);
> > +	drm_exec_init(&ctx->exec, DRM_EXEC_INTERRUPTIBLE_WAIT | DRM_EXEC_IGNORE_DUPLICATES);  
> 
> ../drivers/gpu/drm/panthor/panthor_drv.c: In function ‘panthor_submit_ctx_init’:
> ../drivers/gpu/drm/panthor/panthor_drv.c:722:9: error: too few arguments to function ‘drm_exec_init’
>   722 |         drm_exec_init(&ctx->exec, DRM_EXEC_INTERRUPTIBLE_WAIT | DRM_EXEC_IGNORE_DUPLICATES);
>       |         ^~~~~~~~~~~~~
> 
> In v6.8-rc1 (or drm-misc-next I guess) the calling convention of
> drm_exec_init changed to include a number of initial objects, see
> commit 05d249352f1a ("drm/exec: Pass in initial # of objects")
> 

Looks like this patch went through drm-misc-fixes, and v4.8-rc1 has not
been back merged to drm-misc-next yet.




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux