From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gerd Hoffmann Subject: Re: [PATCH] drm/virtio: Use vmalloc for command buffer allocations. Date: Mon, 2 Sep 2019 07:19:21 +0200 Message-ID: <20190902051921.nczclnaqcmxlh7bz__7868.611141906$1567401575$gmane$org@sirius.home.kraxel.org> References: <20190829212417.257397-1-davidriley@chromium.org> <20190830060857.tzrzgoi2hrmchdi5@sirius.home.kraxel.org> <20190830111605.twzssycagmjhfa45@sirius.home.kraxel.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: virtualization-bounces@lists.linux-foundation.org Errors-To: virtualization-bounces@lists.linux-foundation.org To: Chia-I Wu Cc: David Airlie , open list , ML dri-devel , Gurchetan Singh , =?utf-8?B?U3TDqXBoYW5l?= Marchesin , "open list:VIRTIO CORE, NET AND BLOCK DRIVERS" List-Id: virtualization@lists.linuxfoundation.org > > Completely different approach: use get_user_pages() and don't copy the > > execbuffer at all. > It would be really nice if execbuffer does not copy. > > The user space owns the buffer and may overwrite the contents > immediately after the ioctl. Oh, right. The exec ioctl doesn't block. So this doesn't work (breaks userspace abi). Scratch the idea then. > We also need a flag to indicate that the > ownership of the buffer is transferred to the kernel. Yes, with an additional flag for the changed behavior it could work. cheers, Gerd