From 8d7ec2a209073ce4a403378fa6c828397f5011e9 Mon Sep 17 00:00:00 2001
From: Urja Rannikko <urjaman@gmail.com>
Date: Mon, 21 Oct 2013 21:49:08 +0000
Subject: [PATCH] programmer_delay: filter 0 usec delays

We use 0 as delay value for some chips. Just skipping these here is the
most elegant, maintainable solution.

Corresponding to flashrom svn r1760.

Signed-off-by: Urja Rannikko <urjaman@gmail.com>
Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
---
 flashrom.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/flashrom.c b/flashrom.c
index afab57c..092572e 100644
--- a/flashrom.c
+++ b/flashrom.c
@@ -487,7 +487,8 @@ void chip_readn(const struct flashctx *flash, uint8_t *buf, chipaddr addr,
 
 void programmer_delay(int usecs)
 {
-	programmer_table[programmer].delay(usecs);
+	if (usecs > 0)
+		programmer_table[programmer].delay(usecs);
 }
 
 void map_flash_registers(struct flashctx *flash)
-- 
GitLab