Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp1214258pxb; Tue, 29 Mar 2022 20:47:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwH890sxtifLEAJGcKd7YcP1emvbOJ08SgKLwX2LADWII3VNTXrf6qF6gA51sgrz0U3ddUw X-Received: by 2002:a17:907:7d93:b0:6da:8f57:68fa with SMTP id oz19-20020a1709077d9300b006da8f5768famr38742498ejc.42.1648612067155; Tue, 29 Mar 2022 20:47:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648612067; cv=none; d=google.com; s=arc-20160816; b=NDUnzc15D4Zi1gRfReOAV6NPjC1p80Tpc/yl5oN4aQWtSOrn1qvchjj0pJ07AEEL9U jU22eg0J/Q14A7/wffAPyESWoHXVO5+SIzzvzirEqgtcMADxN5YGpKidSXDx6UdXJZM2 eFLWKEb4HnvBgPPkjIPP7Wplm+ZGyGtpplnZKyIwCyevGYSLtSM00aSdOAkT0IdL4bG3 PLby9Hre/p0uxTZH0zTmkI5au4WI6eqXpiouG+T4Cs7Nrkd4/u3ySOz/TI8JwL0hGzS2 pg/28MH72AihCtvrw6RuQc0tcV2QH+BnQfX3XcUt1kZP+msZEb8ck3EK1kDzCin0iL+r dlbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=uvRihBFxK79wvLjfRr4n7wixXsUSu5Qklv9axZ7x2TA=; b=zNs25fnExllZhhNZwtQ/NR6CpcIRYdDryd+gBls0fwn4+8jt4QKV/ve+UZRPnIaq4T 0LndUKUotOOmrAB0QAxc3BYGTYxmP6xy6wcezEYgWxGo4dJF565buFbfHMuy8rD156XY F1Z0hm1BlxPMYXrnyge5nZwp90ERHJ29+lWbWYhs4lz9S3dgtWfQyZ7+k1sWPrjx3+sQ yB9sUEia7gmKS+NixK5VxDwG0z6x2QtM5/0230Bu5N3WkdZk3liuA3CJM36rO9dxvPHq zjvRIC0oyST4T5YV6ogWSp0mz+OyMg4xS65IYmoxFoojVhWQtA56GGBa9pCzcuGnC9E0 W/HA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=D4P34mYN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ss6-20020a170907038600b006dfb07cee44si17867724ejb.814.2022.03.29.20.47.21; Tue, 29 Mar 2022 20:47:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=D4P34mYN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239918AbiC2XTR (ORCPT + 99 others); Tue, 29 Mar 2022 19:19:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55084 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229955AbiC2XTQ (ORCPT ); Tue, 29 Mar 2022 19:19:16 -0400 Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [46.235.227.227]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 85D13ADD4A; Tue, 29 Mar 2022 16:17:32 -0700 (PDT) Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: dmitry.osipenko) with ESMTPSA id 31C6A1F44074 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1648595851; bh=vNOmry5ThwZXsotfcrBezmCsAHRH+JMNFUfaSsIR1GY=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=D4P34mYNJY6M7Oz8ATv7zNF8aeyzQ2jScIuorEl7BXVhy3SrlRhjvPvzZczvzXyKa WjScuOK6EJM040rfOLlkgvoeO7A0n4GrlLpbl+l1agHYy0on9x+TpKw0dZVmZYCSgW c5ZdbL4hVqVe6DfgZw9LMT8DhovSzp3goCLGL/tsGNX4tstvvytqBS84uxiZMSq2hx kNK86GV8wFomze2ERyiokH6qPpIC+4p0WT3BfjEmciFMar+6uLSNba2MvG9+Sga0De DE7RccOC5/qo9tk0dibZzuU1oRwS+x7gqXYDGGEeN5JTnlbYhaevaY8M+yKE50vfRy UU9LWMInwT2wA== Message-ID: <74a98688-67ad-6f8d-da1e-8fa0b32cff71@collabora.com> Date: Wed, 30 Mar 2022 02:17:27 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: [PATCH 9/9] drm/msm: Add a way for userspace to allocate GPU iova Content-Language: en-US To: Rob Clark , dri-devel@lists.freedesktop.org Cc: Rob Clark , open list , Emma Anholt , Jonathan Marek , Akhil P Oommen , David Airlie , linux-arm-msm@vger.kernel.org, Abhinav Kumar , Jordan Crouse , Sean Paul , freedreno@lists.freedesktop.org, Dan Carpenter References: <20220329230105.601666-1-robdclark@gmail.com> <20220329230105.601666-10-robdclark@gmail.com> From: Dmitry Osipenko In-Reply-To: <20220329230105.601666-10-robdclark@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 3/30/22 02:00, Rob Clark wrote: > +static int msm_ioctl_gem_info_set_iova(struct drm_device *dev, > + struct drm_file *file, struct drm_gem_object *obj, > + uint64_t iova) > +{ > + struct msm_drm_private *priv = dev->dev_private; > + struct msm_file_private *ctx = file->driver_priv; > + > + if (!priv->gpu) > + return -EINVAL; > + > + /* Only supported if per-process address space is supported: */ > + if (priv->gpu->aspace == ctx->aspace) > + return -EINVAL; nit: -EOPNOTSUPP ?