From: Alan Cox Subject: Re: [PATCH] drm/gem: add functions to get/put pages Date: Tue, 27 Sep 2011 10:35:28 +0100 Message-ID: <20110927103528.4e992148@lxorguk.ukuu.org.uk> References: <1315855286-8182-5-git-send-email-rob.clark@linaro.org> <1316126878-29262-1-git-send-email-rob.clark@linaro.org> <20110926194356.GD2804@phenom.ffwll.local> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from www.etchedpixels.co.uk (earthlight.etchedpixels.co.uk [81.2.110.250]) by gabe.freedesktop.org (Postfix) with ESMTP id B109E9EB78 for ; Tue, 27 Sep 2011 02:36:37 -0700 (PDT) In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: Daniel Vetter Cc: patches@linaro.org, dri-devel@lists.freedesktop.org, Rob Clark List-Id: dri-devel@lists.freedesktop.org > Well I think for this case the solution is simple: Tiling not allowed > if userspace is too dumb to properly round the buffer up so it > fulfills whatever odd requirement the hw has. I think hiding the fact > that certain buffers need more backing storage than a naive userspace > might assume is ripe for ugly problems down the road. That depends a lot upon the interface. One good reason for hiding it for example is that if you have hardware where a limit goes away (or worse yet appears) in some rev of the device or an erratum you don't have to issue a new X server. For some of the other interfaces like the dumb fb api it's even more important the code doesn't know. I don't however think the helper should know about padding because I think a driver can implement its own function which wraps the helper and then adds the padding itself ? Alan