Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933457AbdDSHKL (ORCPT ); Wed, 19 Apr 2017 03:10:11 -0400 Received: from mail-lf0-f65.google.com ([209.85.215.65]:33927 "EHLO mail-lf0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933210AbdDSHKH (ORCPT ); Wed, 19 Apr 2017 03:10:07 -0400 Date: Wed, 19 Apr 2017 10:09:56 +0300 From: Pekka Paalanen To: Michel =?UTF-8?B?RMOkbnplcg==?= Cc: Gerd Hoffmann , Daniel Vetter , amd-gfx@lists.freedesktop.org, "dri-devel@lists.freedesktop.org" , open list Subject: Re: [RfC PATCH] drm: fourcc byteorder: brings header file comments in line with reality. Message-ID: <20170419100956.78e4a7ab@eldfell> In-Reply-To: <4230c093-6a8a-76d6-dce8-f9b2300fa70f@daenzer.net> References: <20170410101202.19229-1-kraxel@redhat.com> <20170410161214.305f5daf@eldfell> <1491833847.30990.77.camel@redhat.com> <20170410180941.43922e25@eldfell> <20170411103101.0497fe08@eldfell> <1492510440.27392.27.camel@redhat.com> <4230c093-6a8a-76d6-dce8-f9b2300fa70f@daenzer.net> X-Mailer: Claws Mail 3.13.2 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; boundary="Sig_/eMDPd5Br83l0AbWqfiiudJG"; protocol="application/pgp-signature" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2668 Lines: 67 --Sig_/eMDPd5Br83l0AbWqfiiudJG Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Wed, 19 Apr 2017 10:01:47 +0900 Michel D=C3=A4nzer wrote: > On 18/04/17 07:14 PM, Gerd Hoffmann wrote: > > Hi, > > =20 > >>> Quite true that this proves nothing. However one should note that > >>> fbcon -> fbdev works, =20 > >> > >> BTW, this supports Gerd's patch, since the KMS fbdev emulation code us= es > >> e.g. DRM_FORMAT_XRGB8888 for depth/bpp 24/32, and the fbdev API uses > >> native endian packed colour values. =20 > >=20 > > Same is true for DRM_IOCTL_MODE_ADDFB, with depth/bpp 24/32 you'll get > > DRM_FORMAT_XRGB8888 (only DRM_IOCTL_MODE_ADDFB2 allows userspace specify > > fourcc formats directly). =20 >=20 > Right, and since all major Xorg drivers use DRM_IOCTL_MODE_ADDFB, > they're effectively using DRM_FORMAT_XRGB8888 as native endianness as wel= l. I sincerely hope this doesn't actually force us into a place where we have XRGB8888 (and ARGB8888?) as native-endian, but the other format codes - since being used explicitly - must be kept as little-endian because they were used like that honouring the documentation we have atm. It's starting to resemble the wl_shm format codes problem we have on Wayland for BE. Has this now turned into a question of what the kernel drivers do with the DRM pixel format codes? Hmm, I suppose that has been the question all along... userspace uses whatever formats that look right, new kernel drivers come along and fix themselves to work with whatever userspace uses? And the people who get it wrong are the ones who only ever test on LE and trust the docs... Thanks, pq --Sig_/eMDPd5Br83l0AbWqfiiudJG Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEJQjwWQChkWOYOIONI1/ltBGqqqcFAlj3DUQACgkQI1/ltBGq qqdd1hAAqFwLsQ3oxyLk6Xa5Rxt9ruZpZb8Jk9DGA/VhEveweTlY8tGF6d60spP/ R8LYdMqZhZVcub4WZ1oHpUPiIQYCYPyKk5OogTnyAs8W60qhTMM0Emu6ejHz5uXD I0msLQ6h6cmeZOBTAIvkx2UNMoz/A6m+ORvvBJKuxUF65b1hEVfu3ae11m8JO+r6 Irj+HhnMNgrcDNhjR+E2dnc9d+hyeDDLycXLJe03W3KAI134Tq9B1RiDyILGGcET 0jbSMWR2dhdnbt//VNsn/NeWDI07uYQ7gkpUTQIohxFU2jvn0wbolhVlt+WpNxpG MA5jwAxutHH1tHDg1GFzGU16hXpy4K63Ln9mlR3VQ3PcZl1HTwNqNBmQdQZ/zUUS 5IKcy06XmG8qJ3437RhOCU07Fjf94fVMeayFM4K7LYPJQB/YJTZlHMgNudlsFZPw Ir3dPYSXLdhhnkhowXQDO2yI+JIjiJdumhi3GzDegdv6YFMqvpeD0ZMFgcTheIPA 2LB/WqIphWEebsqx+g200+fcEQzncmznhT0h46BKdB0/tBtnSW/baVLDBb1dEtkU 01R2vjV//GV+qoyU7WrMrrZl2zWm5hm2UVxcRo7gKc791hKXUhL11F4KSR6mxd4J cz/rLRzgWE5JSzALOSevLuPXLJOb9L1KW75c+p58Aug6FwgSVtA= =m/d/ -----END PGP SIGNATURE----- --Sig_/eMDPd5Br83l0AbWqfiiudJG--