Re: [PATCH 1/2] drm/sched: memset() 'job' in drm_sched_job_init()

2024-10-22 Thread Philipp Stanner
On Mon, 2024-10-21 at 15:05 +0200, Christian König wrote: > Am 21.10.24 um 12:50 schrieb Philipp Stanner: > > drm_sched_job_init() has no control over how users allocate struct > > drm_sched_job. Unfortunately, the function can also not set some > > struct > > members such as job->sched. > > > > T

Re: [PATCH 1/2] drm/sched: memset() 'job' in drm_sched_job_init()

2024-10-21 Thread Christian König
Am 21.10.24 um 12:50 schrieb Philipp Stanner: drm_sched_job_init() has no control over how users allocate struct drm_sched_job. Unfortunately, the function can also not set some struct members such as job->sched. This could theoretically lead to UB by users dereferencing the struct's pointer mem

[PATCH 1/2] drm/sched: memset() 'job' in drm_sched_job_init()

2024-10-21 Thread Philipp Stanner
drm_sched_job_init() has no control over how users allocate struct drm_sched_job. Unfortunately, the function can also not set some struct members such as job->sched. This could theoretically lead to UB by users dereferencing the struct's pointer members too early. It is easier to debug such issu

Re: [PATCH 1/2] drm/sched: memset() 'job' in drm_sched_job_init()

2024-08-20 Thread Philipp Stanner
*PING* On Tue, 2024-08-06 at 16:38 +0200, Philipp Stanner wrote: > drm_sched_job_init() has no control over how users allocate struct > drm_sched_job. Unfortunately, the function can also not set some > struct > members such as job->sched. > > This could theoretically lead to UB by users derefer

[PATCH 1/2] drm/sched: memset() 'job' in drm_sched_job_init()

2024-08-06 Thread Philipp Stanner
drm_sched_job_init() has no control over how users allocate struct drm_sched_job. Unfortunately, the function can also not set some struct members such as job->sched. This could theoretically lead to UB by users dereferencing the struct's pointer members too early. It is easier to debug such issu