Re: [PATCH 16/22] gpu: host1x: Forbid unrelated SETCLASS opcode in the firewall

2017-06-13 Thread Dmitry Osipenko
On 13.06.2017 17:06, Thierry Reding wrote: > On Tue, May 23, 2017 at 02:39:33AM +0200, Erik Faye-Lund wrote: >> On Tue, May 23, 2017 at 2:14 AM, Dmitry Osipenko wrote: >>> Several channels could be made to write the same unit concurrently via the >>> SETCLASS opcode, trusting userspace is a bad id

Re: [PATCH 16/22] gpu: host1x: Forbid unrelated SETCLASS opcode in the firewall

2017-06-13 Thread Thierry Reding
On Tue, May 23, 2017 at 02:39:33AM +0200, Erik Faye-Lund wrote: > On Tue, May 23, 2017 at 2:14 AM, Dmitry Osipenko wrote: > > Several channels could be made to write the same unit concurrently via the > > SETCLASS opcode, trusting userspace is a bad idea. It should be possible to > > drop the per-

Re: [PATCH 16/22] gpu: host1x: Forbid unrelated SETCLASS opcode in the firewall

2017-06-01 Thread Mikko Perttunen
With the simplification below and the is_addr_reg change mentioned, Reviewed-by: Mikko Perttunen On 05/23/2017 03:14 AM, Dmitry Osipenko wrote: Several channels could be made to write the same unit concurrently via the SETCLASS opcode, trusting userspace is a bad idea. It should be possible to

Re: [PATCH 16/22] gpu: host1x: Forbid unrelated SETCLASS opcode in the firewall

2017-06-01 Thread Dmitry Osipenko
On 01.06.2017 20:46, Mikko Perttunen wrote: > With the simplification below and the is_addr_reg change mentioned, > > Reviewed-by: Mikko Perttunen > > On 05/23/2017 03:14 AM, Dmitry Osipenko wrote: >> Several channels could be made to write the same unit concurrently via the >> SETCLASS opcode,

Re: [PATCH 16/22] gpu: host1x: Forbid unrelated SETCLASS opcode in the firewall

2017-05-23 Thread Dmitry Osipenko
On 23.05.2017 03:39, Erik Faye-Lund wrote: > On Tue, May 23, 2017 at 2:14 AM, Dmitry Osipenko wrote: >> Several channels could be made to write the same unit concurrently via the >> SETCLASS opcode, trusting userspace is a bad idea. It should be possible to >> drop the per-client channel reservati

[PATCH 16/22] gpu: host1x: Forbid unrelated SETCLASS opcode in the firewall

2017-05-22 Thread Dmitry Osipenko
Several channels could be made to write the same unit concurrently via the SETCLASS opcode, trusting userspace is a bad idea. It should be possible to drop the per-client channel reservation and add a per-unit locking by inserting MLOCK's to the command stream to re-allow the SETCLASS opcode, but i

Re: [PATCH 16/22] gpu: host1x: Forbid unrelated SETCLASS opcode in the firewall

2017-05-22 Thread Erik Faye-Lund
On Tue, May 23, 2017 at 2:14 AM, Dmitry Osipenko wrote: > Several channels could be made to write the same unit concurrently via the > SETCLASS opcode, trusting userspace is a bad idea. It should be possible to > drop the per-client channel reservation and add a per-unit locking by > inserting MLO