Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932864AbdC3IQo (ORCPT ); Thu, 30 Mar 2017 04:16:44 -0400 Received: from mail-wr0-f194.google.com ([209.85.128.194]:36785 "EHLO mail-wr0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755073AbdC3IPo (ORCPT ); Thu, 30 Mar 2017 04:15:44 -0400 Date: Thu, 30 Mar 2017 10:15:39 +0200 From: Daniel Vetter To: Javi Merino Cc: airlied@linux.ie, C.Emde@osadl.org, linux-kernel@lists.codethink.co.uk, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH RESEND] drm: use .hword to represent 16-bit numbers Message-ID: <20170330081539.u7vaw7qdb5mremi6@phenom.ffwll.local> Mail-Followup-To: Javi Merino , airlied@linux.ie, C.Emde@osadl.org, linux-kernel@lists.codethink.co.uk, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org References: <1490795123-16851-1-git-send-email-javi.merino@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1490795123-16851-1-git-send-email-javi.merino@kernel.org> X-Operating-System: Linux phenom 4.9.0-2-amd64 User-Agent: NeoMutt/20170306 (1.8.0) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1865 Lines: 57 On Wed, Mar 29, 2017 at 02:45:23PM +0100, Javi Merino wrote: > The size of .word is the size of a word in the given platform, which > for intel systems is 16-bits but other architectures use different > sizes. However, .hword emits 16-bit numbers regardless of the > platform (and despite the name). The quantities specified in EDID are > platform independent, so they should work in spite of the default > target of the cc you are using, so use .hword where EDID specifies > 16-bit numbers. > > Cc: Carsten Emde > Cc: David Airlie > Signed-off-by: Javi Merino Applied to drm-misc, thanks. -Daniel > --- > Documentation/EDID/edid.S | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/Documentation/EDID/edid.S b/Documentation/EDID/edid.S > index 7ac0327..ef082dc 100644 > --- a/Documentation/EDID/edid.S > +++ b/Documentation/EDID/edid.S > @@ -59,9 +59,9 @@ > /* Fixed header pattern */ > header: .byte 0x00,0xff,0xff,0xff,0xff,0xff,0xff,0x00 > > -mfg_id: .word swap16(mfgname2id(MFG_LNX1, MFG_LNX2, MFG_LNX3)) > +mfg_id: .hword swap16(mfgname2id(MFG_LNX1, MFG_LNX2, MFG_LNX3)) > > -prod_code: .word 0 > +prod_code: .hword 0 > > /* Serial number. 32 bits, little endian. */ > serial_number: .long SERIAL > @@ -177,7 +177,7 @@ std_vres: .byte (XY_RATIO<<6)+VFREQ-60 > > descriptor1: > /* Pixel clock in 10 kHz units. (0.-655.35 MHz, little-endian) */ > -clock: .word CLOCK/10 > +clock: .hword CLOCK/10 > > /* Horizontal active pixels 8 lsbits (0-4095) */ > x_act_lsb: .byte XPIX&0xff > -- > 2.1.4 > > _______________________________________________ > dri-devel mailing list > dri-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/dri-devel -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch