From patchwork Tue Feb 7 22:58:52 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Tauner X-Patchwork-Id: 725512 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from mail.coreboot.org (mail.coreboot.org [80.81.252.135]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3vJCGR46GXz9s7p for ; Wed, 8 Feb 2017 18:17:51 +1100 (AEDT) Received: from [127.0.0.1] (helo=ra.coresystems.de) by mail.coreboot.org with esmtp (Exim 4.86_2) (envelope-from ) id 1cbMUS-0008F8-Lk; Wed, 08 Feb 2017 08:16:32 +0100 Received: from mail2.student.tuwien.ac.at ([193.170.73.222]) by mail.coreboot.org with esmtps (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.86_2) (envelope-from ) id 1cbEj1-0004Pp-Ib for flashrom@flashrom.org; Tue, 07 Feb 2017 23:59:10 +0100 Received: from localhost.localdomain (80-109-83-31.cable.dynamic.surfer.at [80.109.83.31]) (authenticated bits=0) by mail2.student.tuwien.ac.at (8.13.8/8.13.8) with ESMTP id v17Mwuor011924 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Tue, 7 Feb 2017 23:58:56 +0100 From: Stefan Tauner To: flashrom@flashrom.org Date: Tue, 7 Feb 2017 23:58:52 +0100 Message-Id: <20170207225852.10687-1-stefan.tauner@alumni.tuwien.ac.at> X-Mailer: git-send-email 2.9.0.rc2.8.ga28705d X-Spam-Score: -2.4 (--) X-Mailman-Approved-At: Wed, 08 Feb 2017 08:16:31 +0100 Subject: [flashrom] [PATCH] Add support for ESMT F25L004A X-BeenThere: flashrom@flashrom.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: flashrom discussion and development mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Stefan Tauner MIME-Version: 1.0 Errors-To: flashrom-bounces@flashrom.org Sender: "flashrom" X-Duff: Orig. Duff, Duff Lite, Duff Dry, Duff Dark, Raspberry Duff, Lady Duff, Red Duff, Tartar Control Duff Also, enable AAI for ESMT F25L008A. Signed-off-by: Stefan Tauner --- flashchips.c | 45 ++++++++++++++++++++++++++++++++++++++++----- flashchips.h | 1 + 2 files changed, 41 insertions(+), 5 deletions(-) diff --git a/flashchips.c b/flashchips.c index 40b6b8e..33280e6 100644 --- a/flashchips.c +++ b/flashchips.c @@ -3315,6 +3315,41 @@ const struct flashchip flashchips[] = { { .vendor = "ESMT", + .name = "F25L004A", + .bustype = BUS_SPI, + .manufacture_id = ESMT_ID, + .model_id = ESMT_F25L004A, + .total_size = 512, + .page_size = 256, + .feature_bits = FEATURE_WRSR_EITHER, + .tested = TEST_UNTESTED, + .probe = probe_spi_rdid, + .probe_timing = TIMING_ZERO, + .block_erasers = + { + { + .eraseblocks = { {4 * 1024, 128} }, + .block_erase = spi_block_erase_20, + }, { + .eraseblocks = { {64 * 1024, 8} }, + .block_erase = spi_block_erase_d8, + }, { + .eraseblocks = { {512 * 1024, 1} }, + .block_erase = spi_block_erase_60, + }, { + .eraseblocks = { {512 * 1024, 1} }, + .block_erase = spi_block_erase_c7, + } + }, + .printlock = spi_prettyprint_status_register_plain, /* TODO: improve BP2 + AAI */ + .unlock = spi_disable_blockprotect_bp2_srwd, + .write = spi_aai_write, /* AAI supported (0xAD) */ + .read = spi_chip_read, /* Fast read (0x0B) supported */ + .voltage = {2700, 3600}, + }, + + { + .vendor = "ESMT", .name = "F25L008A", .bustype = BUS_SPI, .manufacture_id = ESMT_ID, @@ -3322,7 +3357,7 @@ const struct flashchip flashchips[] = { .total_size = 1024, .page_size = 256, .feature_bits = FEATURE_WRSR_EITHER, - .tested = TEST_OK_PREW, + .tested = { .probe = OK, .read = OK, .erase = OK, .write = NT }, .probe = probe_spi_rdid, .probe_timing = TIMING_ZERO, .block_erasers = @@ -3341,10 +3376,10 @@ const struct flashchip flashchips[] = { .block_erase = spi_block_erase_c7, } }, - .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */ - .unlock = spi_disable_blockprotect, - .write = spi_chip_write_1, - .read = spi_chip_read, + .printlock = spi_prettyprint_status_register_plain, /* TODO: improve BP2 + AAI */ + .unlock = spi_disable_blockprotect_bp2_srwd, + .write = spi_aai_write, /* AAI supported (0xAD) */ + .read = spi_chip_read, /* Fast read (0x0B) supported */ .voltage = {2700, 3600}, }, diff --git a/flashchips.h b/flashchips.h index 9ffb30f..2553544 100644 --- a/flashchips.h +++ b/flashchips.h @@ -216,6 +216,7 @@ #define CATALYST_CAT28F512 0xB8 #define ESMT_ID 0x8C /* Elite Semiconductor Memory Technology (ESMT) / EFST Elite Flash Storage */ +#define ESMT_F25L004A 0x2013 #define ESMT_F25L008A 0x2014 #define ESMT_F25L32PA 0x2016 #define ESMT_F25D08QA 0x2534