From: Wolfgang Denk Date: Wed, 04 Feb 2009 22:53:26 +0100 Subject: [U-Boot] [PATCH] nand_base: Add timeout for NAND reset command In-Reply-To: <1233782967.7067.338.camel@localhost.localdomain> References: <1233776842-23379-1-git-send-email-ptyser@xes-inc.com> <4989F25A.6090400@freescale.com> <1233778972.7067.261.camel@localhost.localdomain> <4989FE57.80404@freescale.com> <20090204212253.27C538322908@gemini.denx.de> <1233782967.7067.338.camel@localhost.localdomain> Message-ID: <20090204215326.613B88322908@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Peter Tyser, In message <1233782967.7067.338.camel@localhost.localdomain> you wrote: > > > get_ticks() not a public interface. It should not be used in any > > common code. > > > > Please use get_timer(). Ah, I see. > The problem is that the NAND code is used prior to interrupts being > enabled, thus we can't use get_timer(). I used a hokey delay based on > (read times * number of iterations). Whats worse, my hokey loop or > get_ticks()? I can't tell. Thing is that get_ticks() may or may not exist. I don't think all architectures have it. I don't see it for ixp, leon*, mcf*, microblaze, mips, nios*, ... Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de "There is nothing new under the sun, but there are lots of old things we don't know yet." - Ambrose Bierce