Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp232822img; Mon, 18 Mar 2019 01:46:34 -0700 (PDT) X-Google-Smtp-Source: APXvYqwL9wNfXeeyGev6U6NN7gSzVJ96NVJCtf8dngjuC/uEvMUAdJ/YTeefYBLdrFI09B7FP/l+ X-Received: by 2002:a63:7341:: with SMTP id d1mr16943896pgn.405.1552898794074; Mon, 18 Mar 2019 01:46:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552898794; cv=none; d=google.com; s=arc-20160816; b=w1/tN2U4HcJFmIII4okDu1qJBUjlt6l192qZu1ix2gUOV5/poUmwjOUQiQoFgvkRFf RDm0jzFErHU/ulAXpvYsq40ZvDPFuRxwnz93baeSBumWRSujZYDCG4xWvjPsgSUE7ypu yxXmiFAPrU3shvDbizOk54hl4sEzmcjnTuL8R+V3UKoiQX9XLJ6T71PvNTbl6zh8mEpE hmo8abPs41KxDBXbk7ACRvNjSrd+kKaSybzKcKJPzcxbC2tvNkKOvp5ljCCSSfyH2CU1 Zw4kOfWuzlr7tra0hfUwoupBlQO3/xkNsQ4Pld6Ba1i2336oME18B1U4OTzgr2VaDeHx kvUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=eY6UeMqNHFzUHcskmkSJLzlujj++kRPbwSLNPy3IP8s=; b=g0W356x2MaUIuL045u/G+R2WsZGepbNXjxrlgWaWZNCSC9dIGwtdcGl2Anyv+MLyOJ PRp9iP7zCcD98nFGRd6VMsHMU+GYWPGhRQuGuJ0z8rHf3W/Xor29yG6n+iWwC9jtCp9w Yy+iZ5r21WXiqIs3gelaeSCxWhWya/68mav8+RsIvXuxtWyt+DuE24D2ZuXsFp4dLnPf mp1q6ZezWbHaMjvdv52cnk0jAod3ODus7a+ghdhDonDu7v92BgxJr8HsYRYI45dpaf9B 4Z/bppHPK+lz07KY6WBjvl4uSi21Z2E9f6f6x6JWnycAfTrrTy2N0mr0JjNZHib/cCJU TUSg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=yKD15rZd; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a17si142406pgg.345.2019.03.18.01.46.19; Mon, 18 Mar 2019 01:46:34 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=yKD15rZd; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726932AbfCRIpg (ORCPT + 99 others); Mon, 18 Mar 2019 04:45:36 -0400 Received: from mail.kernel.org ([198.145.29.99]:43240 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726594AbfCRIpf (ORCPT ); Mon, 18 Mar 2019 04:45:35 -0400 Received: from mail-wr1-f48.google.com (mail-wr1-f48.google.com [209.85.221.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4F53021734; Mon, 18 Mar 2019 08:45:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1552898734; bh=eY6UeMqNHFzUHcskmkSJLzlujj++kRPbwSLNPy3IP8s=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=yKD15rZdzX7TK2tDg+pBq7G6TjcN7qxM9fTlYqbVqQYcO9eMS+ba/zlgiUERrP8GE O2wRWrylTo6a4zLTCHJABnVRbcNpuwFn5aO/UkNmbVN2I6+rGPuSeq0Xu+yHbSQoBy ZZ4VKxQNHwd1AssJlIxdIc/NpnBF8f2p6JlGdVH0= Received: by mail-wr1-f48.google.com with SMTP id d17so15992164wre.10; Mon, 18 Mar 2019 01:45:34 -0700 (PDT) X-Gm-Message-State: APjAAAWoQ7NP1agdBtkYXnU+vkkh667scNBftRMVH4/0XnraiXdnIsx4 8zfMAjAL4UN7mf9A2gwVtVx1mZMkfv+mbkvFQ1k= X-Received: by 2002:adf:c002:: with SMTP id z2mr7157499wre.177.1552898732921; Mon, 18 Mar 2019 01:45:32 -0700 (PDT) MIME-Version: 1.0 References: <20190318073354.12151-1-wens@kernel.org> <20190318073354.12151-5-wens@kernel.org> <20190318084212.lv2lorskizl65uzg@flea> In-Reply-To: <20190318084212.lv2lorskizl65uzg@flea> From: Chen-Yu Tsai Date: Mon, 18 Mar 2019 16:45:19 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 4/6] nvmem: sunxi_sid: Read out data in native format To: Maxime Ripard Cc: Chen-Yu Tsai , Srinivas Kandagatla , linux-sunxi , linux-arm-kernel , devicetree , linux-kernel Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 18, 2019 at 4:42 PM Maxime Ripard wrote: > > Hi, > > On Mon, Mar 18, 2019 at 03:33:52PM +0800, Chen-Yu Tsai wrote: > > From: Chen-Yu Tsai > > > > Originally the SID e-fuses were thought to be in big-endian format. > > Later sources show that they are in fact native or little-endian. > > The most compelling evidence is the thermal sensor calibration data, > > which is a set of one to three 16-bit values. In native-endian they > > are in 16-bit cells with increasing offsets, whereas with big-endian > > they are in the wrong order, and a gap with no data will show if there > > are one or three cells. > > > > Switch to a native endian representation for the nvmem device. For the > > H3, the register read-out method was already returning data in native > > endian. This only affects the other SoCs. > > > > Signed-off-by: Chen-Yu Tsai > > I thought only the newer SoCs were impacted by this issue? It is noticable on the newer SoCs. The old ones only have the 128-bit SID, which could be read either way, as AFAIK it's just a serial number. If you think we should leave the old ones alone I can factor that in. ChenYu