From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-io0-x235.google.com ([2607:f8b0:4001:c06::235]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1a3ZcG-00009u-Bx for linux-mtd@lists.infradead.org; Tue, 01 Dec 2015 01:20:25 +0000 Received: by ioc74 with SMTP id 74so192854370ioc.2 for ; Mon, 30 Nov 2015 17:20:03 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <20151201010552.GS64635@google.com> References: <1448519122-6259-1-git-send-email-mar.kolya@gmail.com> <20151130203518.GL64635@google.com> <20151201000923.GQ64635@google.com> <20151201010552.GS64635@google.com> Date: Mon, 30 Nov 2015 20:20:03 -0500 Message-ID: Subject: Re: [PATCH] mtd: nand: Fix Spansion sparearea size detection From: Nikolay Martynov To: Brian Norris Cc: linux-mtd@lists.infradead.org, David Woodhouse , Boris Brezillon , John Crispin Content-Type: text/plain; charset=UTF-8 List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Brian, thank you for detailed explanation! Please disregard this patch then, since this problem is openwrt specific. Thanks! 2015-11-30 20:05 GMT-05:00 Brian Norris : > On Mon, Nov 30, 2015 at 07:19:22PM -0500, Nikolay Martynov wrote: >> Hi. >> >> I'm using mt7621 board, so this would be mtk_nand with matches from openwrt. > > Sorry, you'll have to address this to the OpenWrt team then. I see the > OpenWrt NAND driver for your board is pretty crappy, but it might be > fixable to support ONFI properly. > > Cc'ing John, who checked in mtk_nand.c into OpenWrt, I think. > > Regards, > Brian > >> 2015-11-30 19:09 GMT-05:00 Brian Norris : >> > Hi Nikolay, >> > >> > On Mon, Nov 30, 2015 at 06:59:32PM -0500, Nikolay Martynov wrote: >> >> I'm sorry, I only have board with S34ML02G2 and I've tested by >> >> change on it - it works fine. But unfortunately I do not have any way >> >> to test S34ML01G2. >> >> It looks like that logic can be simplified if just check id_data[1] >> >> is one of 0xda, 0xdc, 0xca, 0xcc - this should be safer option. >> > >> > Possibly safer, but it's uglier, and I'd like not to have to make this >> > change at all, if ONFI can help it. >> > >> >> I'm sorry, I'm very new to all this. This patch made kernel boot on >> >> a board that I have. The kernel was 'oldish' - 3.18. So I'm not sure >> >> why ONFI is not used here, I will see if I can figure it out. >> > >> > What NAND driver are you using? It's possible that it doesn't support >> > the PARAMETER READ command properly. If so, it'd be better to fix that >> > than to clutter the NAND core. >> > >> > Regards, >> > Brian >> >> >> >> -- >> Martynov Nikolay. >> Email: mar.kolya@gmail.com -- Martynov Nikolay. Email: mar.kolya@gmail.com