Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp61496pxu; Wed, 2 Dec 2020 15:05:42 -0800 (PST) X-Google-Smtp-Source: ABdhPJzule/SmBBHPXYv3UwiozNblZepozRyqGnL0DAtKWNTCW/j1x87Z2YtFpPFImbf7bXc2XCC X-Received: by 2002:a05:6402:31a5:: with SMTP id dj5mr274525edb.325.1606950342543; Wed, 02 Dec 2020 15:05:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606950342; cv=none; d=google.com; s=arc-20160816; b=GY9D8cpStL646K5fXsvSENkaLHkKCZcgcVGra9hEyuMQAqDk/id52MP1CA9mT+BrQn JdxNJ7QFwBhbc4DZKuC9dEXYhjJlW/YoYp2qff05a+/tpSj5NuvIRy3GptVSMklOccCy tsNBdG2FGq3mAAR/xKFQ/xAcGGxvcHrAQ88poE8NC1sY5IZCHGlxwCiNSQMfi7gSzDVg SKgDSoi4QjUkhyg/SgbuBrgb7DT27KIgeSedrmranFFI++xmtxXbqGM9lFFJ6XOvZkmv AOGgiqkTGF+SUcWO8Qt4w4TdG+QTPjAJwENIzRfE9KzCge6ZFwNIqF244PbHJhf9fh4a heqg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=TnA/qUXIYTXaM01hsHMLcQl3An0XNPm+t1vCVx7R0w8=; b=jIc1/2egZ3faLW5Ufz5ZnHKJAeJIS1DFFkztP6hMfQ7QE2K0+soharJGv3qjJGeshH vgz3wzdwLLLIA+qbZgsmlBpM/1HLWoVL3Sk3ouI6eT9zbkV0CcDuWI1CEDlXStTJlg7P GOEQgEA75VbmdUTwazA+Mv8mHQCA/aTHqXhY16ROIYeLSXE9EHFlGvbm/TI+K1Vo2SEr futKYKWzCkalRtger9WsupMg06B4w/PZMqh9pJqcxZSgNpM18v13GJBzZHzuNxjCouf6 jZp/PdJgfsWHJvklhBrpWua+cXiY3j60Ut4buRefmt26EmLcNI8jVLEMgkLc7SL0ckf6 1Y+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b=kSsyKryQ; 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 dd3si121092edb.558.2020.12.02.15.05.19; Wed, 02 Dec 2020 15:05:42 -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; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b=kSsyKryQ; 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 S2387892AbgLBXBl (ORCPT + 99 others); Wed, 2 Dec 2020 18:01:41 -0500 Received: from ssl.serverraum.org ([176.9.125.105]:38379 "EHLO ssl.serverraum.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727084AbgLBXBk (ORCPT ); Wed, 2 Dec 2020 18:01:40 -0500 Received: from apollo.fritz.box (unknown [IPv6:2a02:810c:c200:2e91:6257:18ff:fec4:ca34]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ssl.serverraum.org (Postfix) with ESMTPSA id E408D23E4A; Thu, 3 Dec 2020 00:00:55 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=walle.cc; s=mail2016061301; t=1606950056; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=TnA/qUXIYTXaM01hsHMLcQl3An0XNPm+t1vCVx7R0w8=; b=kSsyKryQib1ypctEuHcEV3YtWwpvJ4y+79qu6gvXBVIg/BKbTYziL5tcYwFbMaHgA0uNsh RntnQuL54pMs8LMPF0x5ZCZB6AcbUUKumu5r5/BBT6RdUcRSwIrhLnaMSK+ayLdTUq9Xjj mv7DdUqgOzgLf3VJjJJ+LV12y9VCvkI= From: Michael Walle To: linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org Cc: Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Tudor Ambarus , Boris Brezillon , Michael Walle , stable@vger.kernel.org Subject: [PATCH v7 1/7] mtd: spi-nor: sst: fix BPn bits for the SST25VF064C Date: Thu, 3 Dec 2020 00:00:34 +0100 Message-Id: <20201202230040.14009-2-michael@walle.cc> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20201202230040.14009-1-michael@walle.cc> References: <20201202230040.14009-1-michael@walle.cc> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This flash part actually has 4 block protection bits. Reported-by: Tudor Ambarus Cc: stable@vger.kernel.org # v5.7+ Signed-off-by: Michael Walle --- I didn't add the Fixes: tag because we depend on the 4bit BP support which was introduced in 5.7. changes since v6: - new patch drivers/mtd/spi-nor/sst.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/mtd/spi-nor/sst.c b/drivers/mtd/spi-nor/sst.c index e0af6d25d573..0ab07624fb73 100644 --- a/drivers/mtd/spi-nor/sst.c +++ b/drivers/mtd/spi-nor/sst.c @@ -18,7 +18,8 @@ static const struct flash_info sst_parts[] = { SECT_4K | SST_WRITE) }, { "sst25vf032b", INFO(0xbf254a, 0, 64 * 1024, 64, SECT_4K | SST_WRITE) }, - { "sst25vf064c", INFO(0xbf254b, 0, 64 * 1024, 128, SECT_4K) }, + { "sst25vf064c", INFO(0xbf254b, 0, 64 * 1024, 128, + SECT_4K | SPI_NOR_4BIT_BP) }, { "sst25wf512", INFO(0xbf2501, 0, 64 * 1024, 1, SECT_4K | SST_WRITE) }, { "sst25wf010", INFO(0xbf2502, 0, 64 * 1024, 2, -- 2.20.1