Browse Source

Bugfix: x6500: Only program once for --force-dev-init

Luke Dashjr 12 years ago
parent
commit
08cfd3e3ca
1 changed files with 1 additions and 1 deletions
  1. 1 1
      driver-x6500.c

+ 1 - 1
driver-x6500.c

@@ -392,7 +392,7 @@ static bool x6500_thread_init(struct thr_info *thr)
 		       x6500->proc_repr);
 		       x6500->proc_repr);
 		if (!x6500_fpga_upload_bitstream(x6500, jp))
 		if (!x6500_fpga_upload_bitstream(x6500, jp))
 			return false;
 			return false;
-	} else if (opt_force_dev_init && x6500->status == LIFE_INIT) {
+	} else if (opt_force_dev_init && x6500 == x6500->device) {
 		applog(LOG_DEBUG, "%"PRIprepr": FPGA is already programmed, but --force-dev-init is set",
 		applog(LOG_DEBUG, "%"PRIprepr": FPGA is already programmed, but --force-dev-init is set",
 		       x6500->proc_repr);
 		       x6500->proc_repr);
 		if (!x6500_fpga_upload_bitstream(x6500, jp))
 		if (!x6500_fpga_upload_bitstream(x6500, jp))