Commit 4feeaece authored by Stefan Tauner's avatar Stefan Tauner
Browse files

Validate baud rate and clock to be greater than 0

parent 074d886d
......@@ -257,6 +257,7 @@ BEGIN {
unit => 'Hz',
group => 'clock',
order => 20,
values => sub { return $_[0] > 0; },
},
OUTPUT_DIR => {
description => "Output directory",
......@@ -290,6 +291,7 @@ BEGIN {
depends_on => "FREQUENCY",
values => sub {
my ($baud, $old, $fclk) = @_;
return 0 if $baud <= 0;
if (defined $fclk) {
return $baud < $fclk;
} else {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment