lowRISC / lowRISC/opentitan

[fpv/lc_ctrl] Does not treat long enum numbers correctly

Open
#12,693 4 comments 0 reactions 1 assignee View on GitHub

@cindychip is already working on this.

Since May 16, 2022.

Component:FPV Component:Tooling Earlgrey-PROD Triaged IP:lc_ctrl Type:Icebox
Dominant language
SystemVerilog
Stars
3.6k
Forks
1.1k
Avg merge
2d 22h
Merged PRs (30d)
141

Description

In LC_CTRL, these two sec_cm assertions failed: https://github.com/lowRISC/opentitan/blob/master/hw/ip/lc_ctrl/rtl/lc_ctrl.sv#L729-L740
because enum type incorrectly categorized two declared values.
https://github.com/lowRISC/opentitan/blob/master/hw/ip/prim/rtl/prim_sparse_fsm_flop.sv#L43-L50

I think the reason is because the enum type is too large -
The lc_state_e is 320 bits enum, and lc_cnt_e is 600 bits enum.
But when I reduce both of them to 16 bits, the assertions passed.

![image](https://user-images.githubusercontent.com/11466553/168650441-fb013539-54ab-4ebc-b946-05aa3c0f8051.png)

Contacting AE to see if we have a solution for that.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.