From: Tomi Valkeinen Subject: Re: [PATCH 0/2] omap/drm: dmm/tiler support for GEM buffers Date: Thu, 08 Dec 2011 10:45:48 +0200 Message-ID: <1323333948.1867.32.camel@deskari> References: <1323134362-3146-1-git-send-email-rob.clark@linaro.org> <1323250279.1915.17.camel@deskari> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0299873249==" Return-path: Received: from na3sys009aog124.obsmtp.com (na3sys009aog124.obsmtp.com [74.125.149.151]) by gabe.freedesktop.org (Postfix) with ESMTP id D47219E7DD for ; Thu, 8 Dec 2011 00:45:54 -0800 (PST) Received: by lagm6 with SMTP id m6so1031384lag.39 for ; Thu, 08 Dec 2011 00:45:52 -0800 (PST) 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: Rob Clark Cc: Greg KH , dri-devel@lists.freedesktop.org, patches@linaro.org List-Id: dri-devel@lists.freedesktop.org --===============0299873249== Content-Type: multipart/signed; micalg="pgp-sha1"; protocol="application/pgp-signature"; boundary="=-3RS2GxEeDp86S0hDXncu" --=-3RS2GxEeDp86S0hDXncu Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, 2011-12-07 at 07:29 -0600, Rob Clark wrote: > On Wed, Dec 7, 2011 at 3:31 AM, Tomi Valkeinen wr= ote: > > Hi, > > > > On Mon, 2011-12-05 at 19:19 -0600, Rob Clark wrote: > >> From: Rob Clark > >> > >> Support for DMM and tiled buffers. The DMM/TILER block in omap4+ SoC > >> provides support for remapping physically discontiguous buffers for > >> various DMA initiators (DSS, IVAHD, etc) which do not otherwise suppor= t > >> non-physically contiguous buffers, as well as providing support for > >> tiled buffers. > >> > >> See the descriptions in the following two patches for more details. > > > > Why is the tiler/dmm driver integrated into the drm driver? >=20 > Basically because of a big list of reasons to keep it integrated, and > no good reason that I could think of to make it a standalone driver. Well, I think it's good architecture to keep independent things separate. Also we have other display frameworks in the kernel than DRM. > 1) Because the function/usage is most like a GTT in other systems.. > the usage is really graphics/multimedia related so GEM is a natural > way to expose it to userspace. Other places we want to use tiler > buffers, like camera, are neatly handled by using dmabuf to export the > GEM buffer to a different device. >=20 > 2) We went down the separate driver path in the past, and it really > exposes a lot of problems. See the hacks that were done in the past > to get wakeup/resume sequencing correct when tiler was a separate > driver. (hint: the table of page addresses needs to be reprogrammed > before any access to buffer mapped in DMM is done.. this can be > accomplished quite simply by restoring the LUT before enabling any > video pipes when it is in a single driver... although that is still in > the TODO) >=20 > 3) Doing some of the more advanced stuff, like page flipping using > DMM's synchronized refill to update page addresses synchronized with > scannout will, I think, end up being some kinda weird API.. I don't > think I'd want to make that a public API exported by one driver > consumed by another, but not such a problem if it is just something > used internally by one driver. >=20 > 4) The LUT isn't really big enough to be managed statically like we > did in the past.. it needs to be managed dynamically, mapping and > evicting buffers. This is something that is typical with other gfx > drivers in their management of their GTT.. >=20 > 5) I wouldn't really want to duplicate the userspace mmap'ing games > for 2d buffers in a lot of different drivers. I can't really argue your points as I'm not familiar with the problems with the tiler. So I'm not questioning the decision to integrate the tiler code into drm, just expressing my toughts =3D). If the tiler driver had only kernel internal API, and no userspace APIs, I don't see why it'd be much more difficult to have as a separate driver than integrated into DRM. Well, except if the tiler code itself uses features offered by DRM extensively, and having the tiler code as an independent driver would mean replicating all those features. I guess it's not quite a fair comparison, but I'm comparing tiler to the vrfb driver (well, lib is perhaps a better word for it), which doesn't depend on any framework and can be used by any kernel component. Tomi --=-3RS2GxEeDp86S0hDXncu Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iQIcBAABAgAGBQJO4Hk8AAoJEPo9qoy8lh71nEMP/2ZqZUbGk8SIehQBaGxIa1gB x/Fb7fNeLFrY3QVBqTzdH8sDX+X7kAH2ZTygH5aIHgBjGI0mUFaUySeklshNnj+Q RPY+Bm7MhLDeEvEhDhk0pzi9smuROwz8e2OuwpomlEt4ZBoIeX1wBKM1z4rNaPuo uWIxaLCgO3qwSWVISp5BET1dAZe+MhicW/9LU31dsezBDbh//IQkec5WRG91UUDV 7oFCrRE6cSag1UYYLHcmfDw8BKgX1UjxjdHQQy419aevguIancHAv5Ymq4w87i1e DWZSHCWXAiQDVZGsQXjrHvNWS8c15F3ydf76lwrJX90pOUqiRam+MzioOq3b1eDv H26YCV2BcASuFGfNCWOD0Nv2p5VazvwixZbz+Qrlyr+2eLBzayQX7EWg0nQ6qAVd l12isN6jW3LAUDVOvVfPRuzK8HGvzkelF8C5m0Mdv1PZBPZgk2H4WITYY22bWyFB vE0HJv3Az+YTVSpJ+KY6ceCg2YLJqQHa7R4QsICbGx4WpqeYG8l7hxswity5Tn+v V4BrsJKIHsgosm6Vx92x0QahxZayL28w0RfEVcTdhHlbjuywDoamDaYXXs6rKD/H dLeMnMyAJok5f8gLwYDyxnZzAGMf55SIjs2a/d02r1kWg1HmVvLjke+szAYez+2H gxkQgu5m9acez8e4RxGw =2o9F -----END PGP SIGNATURE----- --=-3RS2GxEeDp86S0hDXncu-- --===============0299873249== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/dri-devel --===============0299873249==--