[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <9ae839f1-442c-4184-80a8-6f2b51a7b8de@amd.com>
Date: Thu, 2 Nov 2023 13:39:35 +0100
From: Christian König <christian.koenig@....com>
To: Lucas Stach <l.stach@...gutronix.de>,
Daniel Vetter <daniel@...ll.ch>,
Dave Airlie <airlied@...il.com>
Cc: asahi@...ts.linux.dev, Asahi Lina <lina@...hilina.net>,
Luben Tuikov <ltuikov89@...il.com>,
linux-kernel@...r.kernel.org, dri-devel@...ts.freedesktop.org,
alyssa@...enzweig.io, Sumit Semwal <sumit.semwal@...aro.org>,
Faith Ekstrand <faith.ekstrand@...labora.com>,
linux-media@...r.kernel.org
Subject: Re: [PATCH 2/3] drm/scheduler: Fix UAF in
drm_sched_fence_get_timeline_name
Am 02.11.23 um 12:19 schrieb Lucas Stach:
> Am Donnerstag, dem 02.11.2023 um 11:48 +0100 schrieb Christian König:
> [...]
>> I was considering to change the dma_fence semantics so that
>> dma_fence_signal() could only be called from the interrupt contexts of
>> devices and then put a big fat WARN_ON(!in_interrupt()) in there.
>>
>> It's a sledgehammer, but as far as I can see the only thing which might
>> help. Opinions?
> That's not going to fly. As soon as you are dealing with device drivers
> that use IRQ threads, either voluntarily or even involuntarily on RT
> kernels, the dma_fence_signal will be from process context.
Ah shit, yeah of course. We use IRQ threads in amdgpu for the second
interrupt ring as well.
Ok, nail that coffin. Any other ideas how we could enforce this?
Thanks,
Christian.
>
> Regards,
> Lucas
Powered by blists - more mailing lists