Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp561250ybh; Wed, 22 Jul 2020 07:36:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw9LtQ25X6Cb9E19sD0KddDOG2Akexc3tF0CUyDxHqUpM9zeuFZYn1xmzcv7PG3hk2WInCg X-Received: by 2002:a17:907:41dc:: with SMTP id og20mr31605412ejb.183.1595428615227; Wed, 22 Jul 2020 07:36:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595428615; cv=none; d=google.com; s=arc-20160816; b=HcI2ZNb4kIFMgzpB+UHnPxh94k6JR8Yc9U+empiO5Qmjv1jz8LwO8j97vcrxX3AnJ5 PBXS27f7SCdHfcVTeM49sUabdWgjXtyxPbfKHFO8OrzxDa6uXYlT6pLujI7CLtuzi1Gz 9ve2RlZOaoiSBWHnd41f55v830FnILay7e5ebXRd2weyt7npkkQUGimuPTO1xC93D5aA uwH2UJp+UanN6KAzOL9CVPrbjf7tKW8K+kryAqVLBoKNHvbWSZFG2RprsffJaPV5rwFq ET4xbQuy5YhAM/sR9BPF7CdXtqPzkNHaJN0NPID1fszjZXfU06/rZivPmHiK43yevRN0 fOQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:organization:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:ironport-sdr:ironport-sdr; bh=Gry6+8bANAEXVkNrsIpu+02gWOQSbqGQXdwu2ndRW7A=; b=WHEp6yDb9qoawbqz73tPLKLhLPDSH+R7ZTZyJAZIjkxK21kmWOUg+iJtDve9/Gc9QJ OYLH7JqOUCpe2ml6ld8MLhc7UT/Ew6qTp2hTWGyheNq0+vp70nlBFf5CS9GsQHh4LHWU do+1W3uioHPXdFyvWp10IBNv9AccGNQjDjC/NHvprBCJ1UoXhLSFFjQEx6bK35N9ylB6 EPNey5Rnng0JMe7+rnC1lUU6rEYJLQ12gmV69ouT6CiVUoV2xF1j441NLbBC9xpXaVxq uBJLJ1X5svMapShwjqq9U85QdZAI1eHVP1o1ze3v2mQPVmC6j1zILWF4/BFQ9KlNYKaD F5Aw== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e10si85457ejt.626.2020.07.22.07.36.32; Wed, 22 Jul 2020 07:36:55 -0700 (PDT) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732576AbgGVOgJ (ORCPT + 99 others); Wed, 22 Jul 2020 10:36:09 -0400 Received: from mga17.intel.com ([192.55.52.151]:18459 "EHLO mga17.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728837AbgGVOgI (ORCPT ); Wed, 22 Jul 2020 10:36:08 -0400 IronPort-SDR: aQEyGysVT7Jwc6T3JMd3XNGteO8WCibRd37uw7PrwWJgSM32RwY6vv8pNvqSNK2lr4CxhaSCxx cj/QHmMjkoTQ== X-IronPort-AV: E=McAfee;i="6000,8403,9689"; a="130415735" X-IronPort-AV: E=Sophos;i="5.75,383,1589266800"; d="scan'208";a="130415735" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Jul 2020 07:36:08 -0700 IronPort-SDR: 0fDA+wFM2VhH/FNuai2oBdG5m5IqSLN3WBVI03QvuIPscpFFKfhz8xwTE0a1wZJbBU1K9LeRhM TUEYRGTotjNA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.75,383,1589266800"; d="scan'208";a="392692686" Received: from lahna.fi.intel.com (HELO lahna) ([10.237.72.163]) by fmsmga001.fm.intel.com with SMTP; 22 Jul 2020 07:36:05 -0700 Received: by lahna (sSMTP sendmail emulation); Wed, 22 Jul 2020 17:36:04 +0300 Date: Wed, 22 Jul 2020 17:36:04 +0300 From: Mika Westerberg To: Tudor.Ambarus@microchip.com Cc: alexander.sverdlin@nokia.com, vigneshr@ti.com, linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, ibr@ilbers.de Subject: Re: [PATCH] mtd: spi-nor: intel-spi: Simulate WRDI command Message-ID: <20200722143604.GQ5180@lahna.fi.intel.com> References: <282e1305-fd08-e446-1a22-eb4dff78cfb4@nokia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On Wed, Jul 22, 2020 at 02:28:30PM +0000, Tudor.Ambarus@microchip.com wrote: > + Mika > > Hi, Mika, > > Would you please review the patch from below? Sure, there is minor comment below. > > Thanks! > > On 7/22/20 5:01 PM, Alexander Sverdlin wrote: > > EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe > > > > From: Alexander Sverdlin > > > > After spi_nor_write_disable() return code checks were introduced in the > > spi-nor front end intel-spi backend stopped to work because WRDI was never > > supported and always failed. > > > > Just pretend it was sucessful and ignore the command itself. HW sequencer > > shall do the right thing automatically, while with SW sequencer we cannot > > do it anyway, because the only tool we had was preopcode and it makes no > > sense for WRDI. > > > > Cc: stable@vger.kernel.org > > Fixes: bce679e5ae3a ("mtd: spi-nor: Check for errors after each Register Operation") > > Signed-off-by: Alexander Sverdlin > > --- > > drivers/mtd/spi-nor/controllers/intel-spi.c | 8 ++++++++ > > 1 file changed, 8 insertions(+) > > > > diff --git a/drivers/mtd/spi-nor/controllers/intel-spi.c b/drivers/mtd/spi-nor/controllers/intel-spi.c > > index 61d2a0a..134b356 100644 > > --- a/drivers/mtd/spi-nor/controllers/intel-spi.c > > +++ b/drivers/mtd/spi-nor/controllers/intel-spi.c > > @@ -612,6 +612,14 @@ static int intel_spi_write_reg(struct spi_nor *nor, u8 opcode, const u8 *buf, > > return 0; > > } > > > > + /* > > + * We hope that HW sequencer will do the right thing automatically and > > + * with the SW seuencer we cannot use preopcode any way, so just ignore ^^^^^^^^ Typo, should be sequencer. Otherwise looks good to me.