From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0.aculab.com (mx0.aculab.com [213.249.233.131]) by ozlabs.org (Postfix) with SMTP id B85DCB6F9F for ; Mon, 25 Jun 2012 19:21:44 +1000 (EST) Received: from mx0.aculab.com ([127.0.0.1]) by localhost (mx0.aculab.com [127.0.0.1]) (amavisd-new, port 10024) with SMTP id 20954-06 for ; Mon, 25 Jun 2012 10:21:42 +0100 (BST) MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Subject: RE: [PATCH] bluetooth: opcode field of sent commands is little endian. Date: Mon, 25 Jun 2012 10:20:25 +0100 Message-ID: In-Reply-To: <1340609570.5461.50.camel@thor.local> From: "David Laight" To: =?iso-8859-1?Q?Michel_D=E4nzer?= , "Marcel Holtmann" Cc: linux-bluetooth@vger.kernel.org, Johan Hedberg , linuxppc-dev@ozlabs.org List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , =20 > > > Fine with me, though FWIW that not only doesn't use > > > __constant_cpu_to_le16() but actually swaps the non-constant = value. > >=20 > > Don't see what point you are trying to make here. Swapping the value > > from the actual command structure is always fine with me. >=20 > The point is that the result of swapping a constant value is just > another constant value, whereas the fix in mainline swaps a value from > memory. Not a big deal. Surely, but surely, the definition of cpu_to_le16() uses gcc 'magic' to determine that the argument is a constant and then automatically selects the 'constant' form. David