Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add labels to generate blocks #79

Merged
merged 1 commit into from
Dec 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions rtl/system/gpio.sv
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ module gpio #(
logic gp_i_dbnc_rd_en_d, gp_i_dbnc_rd_en_q;

// instantiate debouncers for all GP inputs
for (genvar i = 0; i < GpiWidth; i++) begin
for (genvar i = 0; i < GpiWidth; i++) begin : gen_debounce
debounce #(
.ClkCount(500)
) dbnc (
Expand Down Expand Up @@ -66,8 +66,8 @@ module gpio #(
end

// assign gp_o_d regarding to device_be_i and GpoWidth
for (genvar i_byte = 0; i_byte < 4; ++i_byte) begin : g_gp_o_d;
if (i_byte * 8 < GpoWidth) begin : g_gp_o_d_inner
for (genvar i_byte = 0; i_byte < 4; ++i_byte) begin : gen_gp_o_d;
if (i_byte * 8 < GpoWidth) begin : gen_gp_o_d_inner
localparam int gpo_byte_end = (i_byte + 1) * 8 <= GpoWidth ? (i_byte + 1) * 8 : GpoWidth;
assign gp_o_d[gpo_byte_end - 1 : i_byte * 8] =
device_be_i[i_byte] ? device_wdata_i[gpo_byte_end - 1 : i_byte * 8] :
Expand Down
4 changes: 2 additions & 2 deletions rtl/system/ibex_demo_system.sv
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ module ibex_demo_system #(
end
end

if (DBG) begin : g_dm_top
if (DBG) begin : gen_dm_top
dm_top #(
.NrHarts ( 1 )
) u_dm_top (
Expand Down Expand Up @@ -472,7 +472,7 @@ module ibex_demo_system #(
.host_r_valid_i (host_rvalid[DbgHost]),
.host_r_rdata_i (host_rdata[DbgHost])
);
end else begin
end else begin : gen_no_dm
assign dm_debug_req = 1'b0;
assign ndmreset_req = 1'b0;
end
Expand Down
4 changes: 2 additions & 2 deletions rtl/system/spi_host.sv
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ module spi_host #(
generate
// If CPHA is HIGH, incoming data will be sampled on the falling edge while outgoing
// data will get shifted out on the rising edge.
if (CPHA) begin
if (CPHA) begin : gen_cpha
always_ff @(posedge clk_i or negedge rst_ni) begin
if (!rst_ni) begin
current_byte_q <= '0;
Expand All @@ -136,7 +136,7 @@ module spi_host #(
end
// If CPHA is LOW, incoming data will be sampled on the rising edge while outgoing
// data will get shifted out on the falling edge.
end else begin
end else begin : gen_no_cpha
always_ff @(posedge clk_i or negedge rst_ni) begin
if (!rst_ni) begin
current_byte_q <= '0;
Expand Down