Skip to content

Commit bf3c80b

Browse files
committed
BUGFIX: Fix a/val lib consistency error in the nearest power 2 function
1 parent 2c6e2dc commit bf3c80b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hdl/psi_common_math_pkg.vhd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -620,7 +620,7 @@ package body psi_common_math_pkg is
620620
power_of_two := (others => '0');
621621

622622
for i in 0 to num_bits-1 loop
623-
if (2**i >= val) then
623+
if (2**i >= a) then
624624
power_of_two := (others => '0');
625625
power_of_two(i) := '1';
626626
exit;

0 commit comments

Comments
 (0)