-
Notifications
You must be signed in to change notification settings - Fork 113
Open
Description
Hi, first, thank you for all the content and code you publish, I've been following for a while. Right now I'm studying your crossbar code and realized that the request array has the same implementation for OPT_NONESEL and for !(OPT_NONESEL) & !(NS == 1).
I'm guessing a "nonesel slave" is missing as indicated by the comment, but is the code supposed to be duplicated this way or some difference in the actual request decoding is to be implemented?
Lines 124 to 161 in c36b2a8
generate if (OPT_NONESEL) | |
begin : NO_DEFAULT_REQUEST | |
// {{{ | |
reg [NS-1:0] r_request; | |
// Need to create a slave to describe when nothing is selected | |
// | |
always @(*) | |
begin | |
for(iM=0; iM<NS; iM=iM+1) | |
r_request[iM] = i_valid && prerequest[iM]; | |
if (!OPT_NONESEL && (NS > 1 && |prerequest[NS-1:1])) | |
r_request[0] = 1'b0; | |
end | |
assign request[NS-1:0] = r_request; | |
// }}} | |
end else if (NS == 1) | |
begin : SINGLE_SLAVE | |
// {{{ | |
assign request[0] = i_valid; | |
// }}} | |
end else begin | |
// {{{ | |
reg [NS-1:0] r_request; | |
always @(*) | |
begin | |
for(iM=0; iM<NS; iM=iM+1) | |
r_request[iM] = i_valid && prerequest[iM]; | |
if (!OPT_NONESEL && (NS > 1 && |prerequest[NS-1:1])) | |
r_request[0] = 1'b0; | |
end | |
assign request[NS-1:0] = r_request; | |
// }}} | |
end endgenerate | |
// }}} |
Metadata
Metadata
Assignees
Labels
No labels