From patchwork Sat Jul 20 23:07:33 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrea Adami X-Patchwork-Id: 260483 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from casper.infradead.org (unknown [IPv6:2001:770:15f::2]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 61B3B2C00A3 for ; Sun, 21 Jul 2013 09:08:41 +1000 (EST) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V0gFw-0005JG-Iv; Sat, 20 Jul 2013 23:08:05 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1V0gFu-0002kX-SQ; Sat, 20 Jul 2013 23:08:02 +0000 Received: from mail-ea0-x232.google.com ([2a00:1450:4013:c01::232]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V0gFr-0002jn-Fi for linux-mtd@lists.infradead.org; Sat, 20 Jul 2013 23:08:00 +0000 Received: by mail-ea0-f178.google.com with SMTP id l15so3032766eak.37 for ; Sat, 20 Jul 2013 16:07:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer; bh=o0nMPyDob+wiAyENKUkr/Zhj6NUX3n+01+W/hrZUKlc=; b=CpV8ZhY+99hBX1Qy+J2d3LfD9uOpNpiW5Y6O6oukLAKBpxBuVqi4P/CqtSPSxcsGTD 0c29GtGrhJhW3E658rPXNP5r5cdNRmymMgzNdlpIUhlOapzmFZyafMTNGmQF5VdYyAAf oZqH0Dy2hnCf48KIwcezJTbN/Dz7zX+qUQ7I0C9VUOAgRdQDxJBWf6FJhM9mhgCESvGp f3MkXLcFfXoiuUEY/DGUnuEEkw5Cj6UnoM6rUAqgHcw6fcU9ZajFN+9bUOfIexQx5WLQ +SjMO3CewmixoHga4SDFr2KTEeseJ/PWkOYdBtHxz1pNd0R5njTk/gwn2u+u0EQxjOg8 iibA== X-Received: by 10.14.29.69 with SMTP id h45mr21597836eea.127.1374361656630; Sat, 20 Jul 2013 16:07:36 -0700 (PDT) Received: from mizar.localdomain (host133-7-dynamic.20-79-r.retail.telecomitalia.it. [79.20.7.133]) by mx.google.com with ESMTPSA id n5sm38680804eed.9.2013.07.20.16.07.34 for (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 20 Jul 2013 16:07:35 -0700 (PDT) From: Andrea Adami To: linux-mtd@lists.infradead.org Subject: [PATCH] mtd: jedec_probe: fix LH28F640BF definition Date: Sun, 21 Jul 2013 01:07:33 +0200 Message-Id: <1374361653-3004-1-git-send-email-andrea.adami@gmail.com> X-Mailer: git-send-email 1.8.1.5 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130720_190759_678147_6A157AEF X-CRM114-Status: GOOD ( 11.47 ) X-Spam-Score: -2.0 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (andrea.adami[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature Cc: Russell King , David Woodhouse , linux-kernel@vger.kernel.org X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Zaurus 5500 contains 2 LH28F640BFHE-PTTL90 (64M 4Mx16) and the LH28F640BFHE-PTTL90.pdf datasheet available on the net shows the exact erasesize and the OTP support. At the moment only jedec_probe can discover the chip and the NOR is mounted read only probably because of wrong vpp. Signed-off-by: Andrea Adami --- drivers/mtd/chips/jedec_probe.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/drivers/mtd/chips/jedec_probe.c b/drivers/mtd/chips/jedec_probe.c index c443f52..7c0b27d 100644 --- a/drivers/mtd/chips/jedec_probe.c +++ b/drivers/mtd/chips/jedec_probe.c @@ -120,7 +120,7 @@ #define PM49FL008 0x006A /* Sharp */ -#define LH28F640BF 0x00b0 +#define LH28F640BF 0x00B0 /* ST - www.st.com */ #define M29F800AB 0x0058 @@ -1299,13 +1299,14 @@ static const struct amd_flash_info jedec_table[] = { .mfr_id = CFI_MFR_SHARP, .dev_id = LH28F640BF, .name = "LH28F640BF", - .devtypes = CFI_DEVICETYPE_X8, + .devtypes = CFI_DEVICETYPE_X16, .uaddr = MTD_UADDR_UNNECESSARY, - .dev_size = SIZE_4MiB, - .cmd_set = P_ID_INTEL_STD, - .nr_regions = 1, + .dev_size = SIZE_8MiB, + .cmd_set = P_ID_INTEL_EXT, + .nr_regions = 2, .regions = { - ERASEINFO(0x40000,16), + ERASEINFO(0x10000, 127), + ERASEINFO(0x02000, 8), } }, { .mfr_id = CFI_MFR_SST,