From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tomi Valkeinen Subject: Re: [PATCH 4/6] drm/omap: Allow allocation of larger buffers Date: Mon, 14 Apr 2014 12:25:35 +0300 Message-ID: <534BA98F.10004@ti.com> References: <1397201015-2807-1-git-send-email-archit@ti.com> <1397201015-2807-5-git-send-email-archit@ti.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0577111701==" Return-path: Received: from comal.ext.ti.com (comal.ext.ti.com [198.47.26.152]) by gabe.freedesktop.org (Postfix) with ESMTP id E54026E03B for ; Mon, 14 Apr 2014 02:25:38 -0700 (PDT) In-Reply-To: <1397201015-2807-5-git-send-email-archit@ti.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: Archit Taneja , robdclark@gmail.com Cc: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============0577111701== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="XXk2063HPQTHcDKRrXeWUhoje8AL2f3v1" --XXk2063HPQTHcDKRrXeWUhoje8AL2f3v1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 11/04/14 10:23, Archit Taneja wrote: > The drm ioctl DRM_IOCTL_MODE_ADDFB2 doesn't let us allocate buffers whi= ch are > greater than what is specified in the driver through dev->mode_config. >=20 > Create helpers for DISPC which return the max manager width and height = supported > by the device. The maximum width for a framebuffer is set to the combin= ed width > of the all the crtcs, assuming they are arranged horizontally. >=20 > Signed-off-by: Archit Taneja > --- > drivers/gpu/drm/omapdrm/omap_drv.c | 10 ++++++---- > drivers/video/omap2/dss/dispc.c | 12 ++++++++++++ > include/video/omapdss.h | 2 ++ > 3 files changed, 20 insertions(+), 4 deletions(-) >=20 > diff --git a/drivers/gpu/drm/omapdrm/omap_drv.c b/drivers/gpu/drm/omapd= rm/omap_drv.c > index c8270e4..55ec575 100644 > --- a/drivers/gpu/drm/omapdrm/omap_drv.c > +++ b/drivers/gpu/drm/omapdrm/omap_drv.c > @@ -306,11 +306,13 @@ static int omap_modeset_init(struct drm_device *d= ev) > dev->mode_config.min_width =3D 32; > dev->mode_config.min_height =3D 32; > =20 > - /* note: eventually will need some cpu_is_omapXYZ() type stuff here > - * to fill in these limits properly on different OMAP generations.. > + /* > + * Note: the maximum width is set to the combined width of all the > + * crtcs. We could assume the same for the maximum height too, but > + * we generally don't use such a configuration. > */ > - dev->mode_config.max_width =3D 2048; > - dev->mode_config.max_height =3D 2048; > + dev->mode_config.max_width =3D num_crtcs * dispc_mgr_max_width(); > + dev->mode_config.max_height =3D dispc_mgr_max_height(); This looks very strange. If the max size is supposed to be the maximum output size we support, then multiplying with num_crtcs doesn't make sense. If, on the other hand, it tells the possible maximum size of the framebuffer in the memory, of which only small part is shown (where's the max size of that "part" defined, then?), then there should be no limits as the only limit is the size of the memory. Tomi --XXk2063HPQTHcDKRrXeWUhoje8AL2f3v1 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.14 (GNU/Linux) iQIcBAEBAgAGBQJTS6mPAAoJEPo9qoy8lh715x0QAIjXPBw+/xiDolmw6W+7QqVk Gawr3Cz8uz4WoxZxkbVNP7TN3SQI3rBENdKM0FClbA6uQqsspsk83quv71p9HFyn gRW2qfIddBh5pNRaeN5D3XoTh5z/iMfMDeWn+V5yJHC9kizzj+snySyaBsiqicte En404zima75qQPljcTd6cWbLnmN5JXFei9l6jsM+o1hrI+hdvjqbXP+53h3Chy5b in6tdi96nm2TOPhzRQJemtumj0j6i02UA1vAEizKZ3YkYNYDy5a2oeBUQBekx93z yLaRtkdQ2u4AruHz8a+o9AKMVghgtKI5zW4BJxG9MIoY02VMzymfg+qW8pVF05g2 qrP31dbeYXfrUIbHh7taZZDuqOncv+W6QKrFgzuv+vjjjVYxSxfMrlhd6jofYHCd Ju7kJSxc4s84OGbrikAJi/PIlueIxbIKLuUsA5Lj3zZQ//meEB4CnQwaL2IRTjcI lKUDSK6Ls7sBpfW8udYA0Nnz/ShWDj4aoqxmFZGAoc0owUhn2s2wxN0GjcY3/zm2 SXaOv1xIR3aj3ag3s2wKBvusboB8U40MWLfeRoXnT+KQICL9l3zOQx7/6YbP+5ca Igxdey88kYb9sc2AL/filnivpsfW37CplRileZfGzb9Kd39Czj8EMd6fT6mOm2u7 NxzHC+wh/gKjHx6KU5XR =20FW -----END PGP SIGNATURE----- --XXk2063HPQTHcDKRrXeWUhoje8AL2f3v1-- --===============0577111701== 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 --===============0577111701==--