From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752887AbcFCNRk (ORCPT ); Fri, 3 Jun 2016 09:17:40 -0400 Received: from mail-wm0-f66.google.com ([74.125.82.66]:34824 "EHLO mail-wm0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752349AbcFCNRj (ORCPT ); Fri, 3 Jun 2016 09:17:39 -0400 Subject: Re: [PATCH] nvme: lightnvme: make MLC num_pairs little endian To: Johannes Thumshirn , Jens Axboe References: <1464957858-59392-1-git-send-email-jthumshirn@suse.de> Cc: Keith Busch , linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org From: =?UTF-8?Q?Matias_Bj=c3=b8rling?= Organization: Paletta Message-ID: <5751836F.7060407@bjorling.me> Date: Fri, 3 Jun 2016 15:17:35 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <1464957858-59392-1-git-send-email-jthumshirn@suse.de> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 06/03/2016 02:44 PM, Johannes Thumshirn wrote: > According to the OpenChannel SSD interface specification the NAND flash > MLC page pairing information's number of page page pairings field is the > first two bytes in the MLC Page Pairing data structure. The hardware's > data structure itself is little endian so annotate it as such, like the > rest of lighnvm's data structures. > > Signed-off-by: Johannes Thumshirn > --- > drivers/nvme/host/lightnvm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/nvme/host/lightnvm.c b/drivers/nvme/host/lightnvm.c > index 9461dd6..ea36cbb 100644 > --- a/drivers/nvme/host/lightnvm.c > +++ b/drivers/nvme/host/lightnvm.c > @@ -156,7 +156,7 @@ struct nvme_nvm_completion { > > #define NVME_NVM_LP_MLC_PAIRS 886 > struct nvme_nvm_lp_mlc { > - __u16 num_pairs; > + __le16 num_pairs; > __u8 pairs[NVME_NVM_LP_MLC_PAIRS]; > }; > > Thanks Johannes. Applied for 4.8.