Skip to content

Commit f271c7a

Browse files
robertszczepanskitmichalak
authored andcommitted
Resolve width errors
Internal-tag: [#74406]
1 parent 07e0e95 commit f271c7a

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

src/ctrl/descriptor_ibi.sv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ module descriptor_ibi #(
9494
// -1 to compensate for comparison with data_cnt
9595
data_len <= ibi_queue_rdata_i[7:0] - 1;
9696
// Divide by 4 and round up
97-
data_words <= ibi_queue_rdata_i[7:2] + |ibi_queue_rdata_i[1:0];
97+
data_words <= 8'(ibi_queue_rdata_i[7:2] + |ibi_queue_rdata_i[1:0]);
9898
end
9999

100100
// Data counter

src/ctrl/descriptor_tx.sv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ module descriptor_tx #(
102102
end
103103

104104
assign data_len = tx_descriptor[15:0];
105-
assign data_len_words = (data_len >> 2);
105+
assign data_len_words = TtiTxDescDataWidth'(data_len >> 2);
106106
// Add 1 to depth, because there is one word in the Nto8 converter
107107
assign tx_start = ~tx_pending && descriptor_valid &&
108108
((tti_tx_queue_depth_i+1'b1) >= data_len_words);

src/ctrl/ibi.sv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ module ibi (
201201
end
202202
SendTbit: begin
203203
bus_tx_req_bit_o = 1'b1;
204-
bus_tx_req_value_o = !ibi_byte_last_i;
204+
bus_tx_req_value_o = 8'(!ibi_byte_last_i);
205205
bus_tx_sel_od_pp_o = 1'b1;
206206
end
207207
default: begin

src/ctrl/width_converter_Nto8.sv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ module width_converter_Nto8 #(
5050
else begin
5151
if (source_flush_i) sreg <= '0;
5252
else if ((bcnt == '0) & sink_valid_i & sink_ready_o) sreg <= sink_data_i;
53-
else if ((bcnt != '0) & source_valid_o & source_ready_i) sreg <= sreg >> 8;
53+
else if ((bcnt != '0) & source_valid_o & source_ready_i) sreg <= Width'(sreg >> 8);
5454
end
5555

5656
// Data output

src/recovery/recovery_executor.sv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ module recovery_executor
217217
// ....................................................
218218

219219
// Data counter
220-
assign dcnt_next = (|cmd_len_i[1:0]) ? (cmd_len_i / 4 + 1) : (cmd_len_i / 4); // Divide by 4, round up
220+
assign dcnt_next = (|cmd_len_i[1:0]) ? 16'(cmd_len_i / 4 + 1) : 16'(cmd_len_i / 4); // Divide by 4, round up
221221

222222
always_ff @(posedge clk_i)
223223
unique case (state_q)

0 commit comments

Comments
 (0)