Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp234603pxb; Wed, 24 Feb 2021 00:08:59 -0800 (PST) X-Google-Smtp-Source: ABdhPJxEnc0LA7DjHQlbpCdcO/mrwyj6PzF3P/gdYFgYOFH9HZ3mnO6ZM7m9w+y9oK09hh8CV7M8 X-Received: by 2002:aa7:c314:: with SMTP id l20mr20199915edq.148.1614154139473; Wed, 24 Feb 2021 00:08:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614154139; cv=none; d=google.com; s=arc-20160816; b=EaDBZxepUHk+h+BIMcT+n4oXR1CaU2OL9X1ePyIhIvr5ynPqr7nWJ22wm+bR47dj1g Q5IkcHBZ0hsdLjZ9W3d8hS3mpsk3rHF8uCfBhHT0xKXDiNCi4p9wLciuDvA63PuR3Wuu 0nVSxJ5dUdBToUjx0cRvFpSmxALCZSHHKQ5XX98Zlh5wPKRUbKRDiX1bm4T/yHtrKzls tDBQJAAWnHO+hmFw3ufQm0Vidl/3Vj6xQnJ5fXywEpft+E9FQsxk/82M+lmZzNM7xwHt Vf/83T+H95LAy2yLGeI960ZSrm77pgUjK5RoNYDUahawIHz0RW1gHLLYdzYD/5o7Uo5e 3InA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=vO54PfciWbeDk9BtlbU+odsYqjXcxncGsSNqkIWyq04=; b=q5qLbYmlNAELnGYyge/hpgqea7xS08YdCYVpkQHXYwTdxZOC29m8hRAidc+eSapp1u wz3vFXrBZe2cFqvD1oFlKmlRmQME1MJI1w2y5uc8DAAGVOxgvsa8w1WEEfCalb1fo2nm 9dTDD1+4zMIKz/H5Av58JnHRezc6JdkkDwmxUglwu5ozJAopc8UwK9CfqtcTa/mgtTog E6gH0dszfhsTWxwaamaIiZTipOJTLFupsk4XanFtfAuHtLiz5/DvXVKBCVLKkTMTOebL CGTckBqMDADF2BITIJqRtSPpNdDAa2LzApIn66nUGfoX450w/nOxwG0AP6cQ99JTfY9a ndmw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y9si719760edt.598.2021.02.24.00.08.35; Wed, 24 Feb 2021 00:08:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234267AbhBXGt6 convert rfc822-to-8bit (ORCPT + 99 others); Wed, 24 Feb 2021 01:49:58 -0500 Received: from relay10.mail.gandi.net ([217.70.178.230]:53899 "EHLO relay10.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234260AbhBXGtl (ORCPT ); Wed, 24 Feb 2021 01:49:41 -0500 Received: from xps13 (lfbn-tou-1-972-113.w86-210.abo.wanadoo.fr [86.210.203.113]) (Authenticated sender: miquel.raynal@bootlin.com) by relay10.mail.gandi.net (Postfix) with ESMTPSA id 3E15A240005; Wed, 24 Feb 2021 06:48:51 +0000 (UTC) Date: Wed, 24 Feb 2021 07:48:50 +0100 From: Miquel Raynal To: mdalam@codeaurora.org Cc: mani@kernel.org, boris.brezillon@collabora.com, linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, sricharan@codeaurora.org, mdalam=codeaurora.org@codeaurora.org Subject: Re: [PATCH] mtd: rawnand: qcom: update last code word register Message-ID: <20210224074850.0c74154d@xps13> In-Reply-To: <38da9d1d4a96f1b42ba0b194da265e6b@codeaurora.org> References: <1614024267-12529-1-git-send-email-mdalam@codeaurora.org> <20210223173449.1a55df1e@xps13> <38da9d1d4a96f1b42ba0b194da265e6b@codeaurora.org> Organization: Bootlin X-Mailer: Claws Mail 3.17.4 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, mdalam@codeaurora.org wrote on Wed, 24 Feb 2021 10:09:48 +0530: > On 2021-02-24 01:13, mdalam@codeaurora.org wrote: > > On 2021-02-23 22:04, Miquel Raynal wrote: > >> Hello, > >> >> Md Sadre Alam wrote on Tue, 23 Feb 2021 > >> 01:34:27 +0530: > >> >>> From QPIC version 2.0 onwards new register got added to read last > >> >> a new > >> >>> codeword. This change will add the READ_LOCATION_LAST_CW_n register. > >> >> Add support for this READ_LOCATION_LAST_CW_n register. > >> >>> >>> For first three code word READ_LOCATION_n register will be > >>> use.For last code word READ_LOCATION_LAST_CW_n register will be > >>> use. > >> >> " > >> In the case of QPIC v2, codewords 0, 1 and 2 will be accessed through > >> READ_LOCATION_n, while codeword 3 will be accessed through > >> READ_LOCATION_LAST_CW_n. > >> " > >> >> When I read my own sentence, I feel that there is something wrong. > >> If there are only 4 codewords, I guess a QPIC v2 is able to use > >> READ_LOCATION_3 or READ_LOCATION_LAST_CW_0 interchangeably. Isn't it? > >> >> I guess the point of having these "last_cw_n" registers is to support > >> up to 8 codewords, am I wrong? If this the case, the current patch > >> completely fails doing that I don't get the point of such change. > > > > This register is only use to read last code word. > > > > I have address all the comments from all the previous sub sequent > > patches and pushed > > all patches in only one series. > > > > Please check. > > The registers READ_LOCATION & READ_LOCATION_LAST are not associated with number of code words. > These two registers are used to access the location inside a code word. Ok. Can you please explain what is a location then? Or point me to a datasheet that explains it. Bottom line question: why having READ_LOCATION_0, _1,... an READ_LOCATION_LAST_0, _1, etc? > So whether we are having 4 code words > or 8 code words it doesn't matter. If we wanted access the location within normal code word we have to > use READ_LOCATION register and if we wanted to access location in last code word then we have to use > READ_LOCATION_LAST. > > > >> >>> Signed-off-by: Md Sadre Alam Thanks, Miquèl