[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1493275550.31995.31.camel@redhat.com>
Date: Thu, 27 Apr 2017 08:45:50 +0200
From: Gerd Hoffmann <kraxel@...hat.com>
To: Michel Dänzer <michel@...nzer.net>
Cc: Daniel Vetter <daniel.vetter@...el.com>,
dri-devel@...ts.freedesktop.org,
open list <linux-kernel@...r.kernel.org>,
amd-gfx@...ts.freedesktop.org
Subject: Re: [PATCH 3/6] drm: fourcc byteorder: add bigendian support to
drm_mode_legacy_fb_format
Hi,
> > That is done using the RADEON_TILING_SWAP_{16,32}BIT flag mentioned in
> > another thread?
>
> Right.
>
>
> > What about dumb bos? You've mentioned the swap flag isn't used for
> > those. Which implies they are in little endian byte order (both gpu and
> > cpu view).
>
> Right, AFAICT from looking at the code.
Ok.
And I also don't see an easy way to make them big endian (cpu view)
using swapping with the existing drm interfaces, given we apply a format
when we put the bo into use as framebuffer, not when creating it. So
userspace can: (1) create dumb bo, (2) map bo, (3) write something bo,
(4) create fb + attach to crtc. And at (3) we don't know the format
yet, so we can't configure swapping accordingly.
So just not using the swapping indeed looks like the only sensible
option. Which in turn implies there is no BGRA8888 support for dumb
bos. Hmm, I can see the problem. Userspace expectation appears to be
that ADDFB configures a native endian framebuffer, which the driver
simply can't do on bigendian.
So, what can/should the driver do here? Throw errors for ADDFB and
force userspace to use ADDFB2? From a design point of view the best
option, but in the other hand I suspect that could break the xorg radeon
driver ...
cheers,
Gerd
Powered by blists - more mailing lists