Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1303269rbb; Mon, 26 Feb 2024 05:29:41 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXPVqKinX11mQSfZXSSD3GFUVX6I5o4nAPvw/p8G9WeuDV0rpBxVoMvzb+Akf6Z8OQ1HUKkLvF9kcZydeDqL9gG2+h5f11MNhnCeGj0+A== X-Google-Smtp-Source: AGHT+IEZTWSFrNaoxDMpvcPQSlWUtb+WgImGeTKZgoIprCt20iO+SCLFQ6B3XIaYZSeJhg1GTVat X-Received: by 2002:a05:6358:2495:b0:17b:88c2:5c13 with SMTP id m21-20020a056358249500b0017b88c25c13mr8548497rwc.7.1708954180805; Mon, 26 Feb 2024 05:29:40 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708954180; cv=pass; d=google.com; s=arc-20160816; b=iWoDnDLkrreZYBV7pJ40E4wtDGp+D9iODtqjTIX2wG4gqvd7W+j1P5mYA5XAonII6S MbvEGVnZomy/Gt208fnyTz1MzZBTYpiX4Ye7xbKBJJY//WEu1Oa8O2JJwHmkohYklAxW otbAn4NEFxk/aACFwiBxwkvDFb65hddUab1kf3V4f4l9BjP7Cf2nMl0JfTY2xz0f30WS KW/Wi/gYWjb42wRNSlj+sM36aVDK5OOfP+n6Xed7NBpjWuVNkLwc+RT4r7/9VUT3hLwY zHTzOXH6S9uvBqTEsH73hqPn7ZCQHVYTS3Q1G3gfjqaveyFkPhVYkvUzwIJqVVIQr6qs cwgQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:organization:from:references :cc:to:content-language:subject:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=bVsIzVEJVoKWnX7cN734QjaonbKCtAUdb7PLFZc6DUk=; fh=G9wTKW++urrgC7pKHsWwJvHVom17izb9TLih9CnGFZ0=; b=QN+gsjgFphuhStzdbSyENvCkHCr1RAEvvh4MfKl2IRo1Hd7bwqod7YaFOZC3IDbjy/ hIUHjaVJf+z/kCmUEyCGeaq8uo9wM1zuq4bEt2f3cjqXxrfj5t3b8LVFCuDyDN7CC3JI WBCSSJmLPmYjqiKv0ZcJawDRaQ36LLJeNicRDpyEBohB1pbAQLK6UcCWItrieOXBwyLy M7i92jRNyljDrPONA1yQQrYJHwv/AvnRUjFeWUX1oNfMHP9uZ8Kz0rhq70OKdHKsbqgV xjYGALgVcr3FzasBnDnyrIW7drhEJqjgp/Vdbpk63kNndon0h1EsL7QwZv7ZBrYXsyzD Zz2A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=WcPKrZPJ; arc=pass (i=1 spf=pass spfdomain=microchip.com dkim=pass dkdomain=microchip.com dmarc=pass fromdomain=microchip.com); spf=pass (google.com: domain of linux-kernel+bounces-81421-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81421-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=REJECT dis=NONE) header.from=microchip.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id e14-20020a65648e000000b005dc816e3080si3704102pgv.12.2024.02.26.05.29.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 05:29:40 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-81421-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=WcPKrZPJ; arc=pass (i=1 spf=pass spfdomain=microchip.com dkim=pass dkdomain=microchip.com dmarc=pass fromdomain=microchip.com); spf=pass (google.com: domain of linux-kernel+bounces-81421-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81421-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=REJECT dis=NONE) header.from=microchip.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id EBCC3B2D158 for ; Mon, 26 Feb 2024 12:57:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C2BA780C00; Mon, 26 Feb 2024 12:56:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=microchip.com header.i=@microchip.com header.b="WcPKrZPJ" Received: from esa.microchip.iphmx.com (esa.microchip.iphmx.com [68.232.154.123]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2FBE08005E for ; Mon, 26 Feb 2024 12:56:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=68.232.154.123 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708952202; cv=none; b=c3718WmK1FXd4FFBeKVQ4l81M3UBuPxTKotw4HDGOKZGwp4FhZ3JpznacX7KMwFd76+zp/6T94bfw4TYE2Qn5vEniaG7JTqjK+9GCAiv96JmyYr21XIAo9j4HOb55wA21ZQVqEuxObWYGaNyW+VTate7AK1U+40T0CCPc2Nu8Gc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708952202; c=relaxed/simple; bh=ZWGyD5hzgW44HzlR18tI17IUrY8Vy5u5/537CqTcSss=; h=Message-ID:Date:MIME-Version:Subject:To:CC:References:From: In-Reply-To:Content-Type; b=NjoQ5cXgBw8H1REkpdO/eFfarcrSKCYhZBw2DM3ncL/Hg+P+A0zGBQBMgG3dPwCH1ZFZYmzkVj0YFZ3UJm/8ekO6VRmvKCW3RXIrfIA0yTE8huv/tlSmwATKLTiOnhoLc3bdD8n7iX85+CeOpaiGw2c1fCh28ItkdCgXutOEkws= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=microchip.com; spf=pass smtp.mailfrom=microchip.com; dkim=pass (2048-bit key) header.d=microchip.com header.i=@microchip.com header.b=WcPKrZPJ; arc=none smtp.client-ip=68.232.154.123 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=microchip.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=microchip.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1708952200; x=1740488200; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=ZWGyD5hzgW44HzlR18tI17IUrY8Vy5u5/537CqTcSss=; b=WcPKrZPJWZxeLbkklxZwlt5S4hhddqHn2hVsrFkGFcIWIFp38jX9uEJc KbzwWGCcIPUHm/m5ZOrC22aI20x3ddJHs5K+fF+bGObgxS5Se35wNdLhi 9YHv1bUfBL6ZekU3GtvV9AZImsdwZ2X81RcxSokXdXxjkUgsO1ZPJJJmx wMWSJrACTLgyuCpMGKhne7ilOSasJKG8NNMBysgMkKHBKlwaMNN0/zoGU cB3iwCsbrqZXAxawjp898PwdUZKrLfVQfv9f/bbQ4shXOJ7nZpfp29WkU +Cw4FvwMKSyWBPZJGTMMjc/7oOuqWfyj9JWMtadEDerFBIk6S1AtCxvWX Q==; X-CSE-ConnectionGUID: kHv4xSMiQjOsauQ9YHuS0g== X-CSE-MsgGUID: Lh8qfODeRFOytOATbH+2rg== X-IronPort-AV: E=Sophos;i="6.06,185,1705388400"; d="scan'208";a="184095717" X-Amp-Result: SKIPPED(no attachment in message) Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 26 Feb 2024 05:56:39 -0700 Received: from chn-vm-ex03.mchp-main.com (10.10.85.151) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Mon, 26 Feb 2024 05:55:58 -0700 Received: from [10.159.245.205] (10.10.85.11) by chn-vm-ex03.mchp-main.com (10.10.85.151) with Microsoft SMTP Server id 15.1.2507.35 via Frontend Transport; Mon, 26 Feb 2024 05:55:57 -0700 Message-ID: Date: Mon, 26 Feb 2024 13:54:58 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] mtd: nand: raw: atmel: Fix comment in timings preparation Content-Language: en-US, fr-FR To: Alexander Dahl , CC: Boris Brezillon , Tudor Ambarus , Miquel Raynal , Vignesh Raghavendra , , References: <20240226122537.75097-1-ada@thorsis.com> From: Nicolas Ferre Organization: microchip In-Reply-To: <20240226122537.75097-1-ada@thorsis.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit On 26/02/2024 at 13:25, Alexander Dahl wrote: > Looks like a copy'n'paste mistake introduced when initially adding the > dynamic timings feature with commit f9ce2eddf176 ("mtd: nand: atmel: Add > ->setup_data_interface() hooks"). The context around this and > especially the code itself suggests 'read' is meant instead of write. > > Signed-off-by: Alexander Dahl Looks indeed valid: Reviewed-by: Nicolas Ferre Thanks Alexander. Best regards, Nicolas > --- > drivers/mtd/nand/raw/atmel/nand-controller.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/mtd/nand/raw/atmel/nand-controller.c b/drivers/mtd/nand/raw/atmel/nand-controller.c > index 4cb478bbee4a..dc75d50d52e8 100644 > --- a/drivers/mtd/nand/raw/atmel/nand-controller.c > +++ b/drivers/mtd/nand/raw/atmel/nand-controller.c > @@ -1370,23 +1370,23 @@ static int atmel_smc_nand_prepare_smcconf(struct atmel_nand *nand, > * > * NRD_PULSE = tRP > */ > ncycles = DIV_ROUND_UP(conf->timings.sdr.tRP_min, mckperiodps); > totalcycles += ncycles; > ret = atmel_smc_cs_conf_set_pulse(smcconf, ATMEL_SMC_NRD_SHIFT, > ncycles); > if (ret) > return ret; > > /* > - * The write cycle timing is directly matching tWC, but is also > + * The read cycle timing is directly matching tRC, but is also > * dependent on the setup and hold timings we calculated earlier, > * which gives: > * > * NRD_CYCLE = max(tRC, NRD_PULSE + NRD_HOLD) > * > * NRD_SETUP is always 0. > */ > ncycles = DIV_ROUND_UP(conf->timings.sdr.tRC_min, mckperiodps); > ncycles = max(totalcycles, ncycles); > ret = atmel_smc_cs_conf_set_cycle(smcconf, ATMEL_SMC_NRD_SHIFT, > ncycles); > > base-commit: d206a76d7d2726f3b096037f2079ce0bd3ba329b > -- > 2.39.2 >