From patchwork Tue May 12 23:23:32 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Brownell X-Patchwork-Id: 27145 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [18.85.46.34]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by bilbo.ozlabs.org (Postfix) with ESMTPS id 06F22B7079 for ; Wed, 13 May 2009 09:28:26 +1000 (EST) Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.69 #1 (Red Hat Linux)) id 1M41K7-0004QZ-DP; Tue, 12 May 2009 23:23:47 +0000 Received: from n22a.bullet.mail.mud.yahoo.com ([68.142.207.188]) by bombadil.infradead.org with smtp (Exim 4.69 #1 (Red Hat Linux)) id 1M41Jy-0004Ck-L8 for linux-mtd@lists.infradead.org; Tue, 12 May 2009 23:23:44 +0000 Received: from [68.142.200.226] by n22.bullet.mail.mud.yahoo.com with NNFMP; 12 May 2009 23:23:35 -0000 Received: from [68.142.201.244] by t7.bullet.mud.yahoo.com with NNFMP; 12 May 2009 23:23:34 -0000 Received: from [127.0.0.1] by omp405.mail.mud.yahoo.com with NNFMP; 12 May 2009 23:23:34 -0000 X-Yahoo-Newman-Id: 970286.11872.bm@omp405.mail.mud.yahoo.com Received: (qmail 12034 invoked from network); 12 May 2009 23:23:34 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=pacbell.net; h=Received:X-YMail-OSG:X-Yahoo-Newman-Property:From:To:Subject:Date:User-Agent:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding:Content-Disposition:Message-Id; b=uqe4zbUHh5NCzmsYmsFIFFf8iUZ0mFTKB57KxG2PDvefTudkizGcyn/LwLrTkhkIQ2XclF+5ZIsnpAhOeLetd8IR0EaZmCqXO9RhhrbNcLfwDNKTEc5pavFnhi0WaHNKGzgKnvV9oqdFL/b8SLR/3THy4eCRRNx/og8NwuHTwdg= ; Received: from unknown (HELO albert) (david-b@69.226.239.45 with plain) by smtp108.sbc.mail.sp1.yahoo.com with SMTP; 12 May 2009 23:23:33 -0000 X-YMail-OSG: db8EwRYVM1lRyLum_oDEX34PnfoH6C195QoVhoDrALErsOiTzKaXpceA3PhQkOGWbYXa1pApSnC87G4j92csqEO86WbNPP9JDl7aPpHJHOOdfARb3vUBsxro6cpz_uH__9YOt.jhxIohJ3v21RqIiTPTfEuomPVl0JQzc3R2JC23IJVjRpa30x9Vmw9e1RO39xtSmQXnnF4uZXOv83T4P8Cih7oWl5uAtwBRhD3yXPiwuqy0Ql7NPHWbdyfcYXFQMnsRFVXLUjpamcxdGiNNYyJFOSebl.4_4Wy6m9qIZTU_31YfTNclm_.3AmXaIhHY6dxET7kA97A7Uet7xMmP X-Yahoo-Newman-Property: ymail-3 From: David Brownell To: Linux MTD Subject: [patch 2.6.30-rc5+] davinci_nand: cmdlinepart uses MTD IDs Date: Tue, 12 May 2009 16:23:32 -0700 User-Agent: KMail/1.9.10 MIME-Version: 1.0 Content-Disposition: inline Message-Id: <200905121623.32809.david-b@pacbell.net> X-Spam-Score: 0.0 (/) Cc: Andrew Morton , Snehaprabha Narnakaje X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-mtd-bounces@lists.infradead.org Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: David Brownell Remove some legacy code from the davinci_nand driver, which made cmdlinepart ignore the the MTD ID passed to it. Boards can have multiple NAND chips, and some do (like the DM357 EVM), so this dated hack is undesirable. Correct labels a"re like davinci_nand.0" (for chipselect 0). Signed-off-by: David Brownell --- drivers/mtd/nand/davinci_nand.c | 11 ----------- 1 file changed, 11 deletions(-) --- a/drivers/mtd/nand/davinci_nand.c +++ b/drivers/mtd/nand/davinci_nand.c @@ -718,19 +718,8 @@ syndrome_done: static const char *probes[] __initconst = { "cmdlinepart", NULL }; - const char *master_name; - - /* Set info->mtd.name = 0 temporarily */ - master_name = info->mtd.name; - info->mtd.name = (char *)0; - - /* info->mtd.name == 0, means: don't bother checking - */ mtd_parts_nb = parse_mtd_partitions(&info->mtd, probes, &mtd_parts, 0); - - /* Restore info->mtd.name */ - info->mtd.name = master_name; } if (mtd_parts_nb <= 0) {