Only use board clock speed if user does not specify an alternate freq
This commit is contained in:
parent
797785ce93
commit
f8831f329c
|
|
@ -30,6 +30,8 @@
|
||||||
#include "rawParser.hpp"
|
#include "rawParser.hpp"
|
||||||
#include "xilinx.hpp"
|
#include "xilinx.hpp"
|
||||||
|
|
||||||
|
#define DEFAULT_FREQ 6000000
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
struct arguments {
|
struct arguments {
|
||||||
|
|
@ -70,7 +72,7 @@ int main(int argc, char **argv)
|
||||||
|
|
||||||
/* command line args. */
|
/* command line args. */
|
||||||
struct arguments args = {0, false, false, false, 0, "", "", "-", "", -1,
|
struct arguments args = {0, false, false, false, 0, "", "", "-", "", -1,
|
||||||
6000000, "-", false, false, false, false, Device::WR_SRAM, false,
|
DEFAULT_FREQ, "-", false, false, false, false, Device::WR_SRAM, false,
|
||||||
false, false, "", "", "", -1, 0};
|
false, false, "", "", "", -1, 0};
|
||||||
/* parse arguments */
|
/* parse arguments */
|
||||||
try {
|
try {
|
||||||
|
|
@ -127,7 +129,7 @@ int main(int argc, char **argv)
|
||||||
args.fpga_part = board->fpga_part;
|
args.fpga_part = board->fpga_part;
|
||||||
|
|
||||||
/* Some boards can override the default clock speed */
|
/* Some boards can override the default clock speed */
|
||||||
if (board->default_freq != CABLE_DEFAULT)
|
if (board->default_freq != CABLE_DEFAULT && freq == DEFAULT_FREQ)
|
||||||
freq = board->default_freq;
|
freq = board->default_freq;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue