[dv, flash_ctrl] Split flash_ctrl_rand_ops_vseq

This is a minor enhancement that "renames" the
`flash_ctrl_rand_ops_vseq` to `flash_ctrl_rand_ops_base_vseq` which is
not run directly, but extensions of it that configure the randomization
knobs are. It adds the `flash_ctrl_rand_ops_vseq` which we run as a
test.

The smoke test is now made to extend from the base rand ops class.

Signed-off-by: Srikrishna Iyer <sriyer@google.com>
diff --git a/hw/ip/flash_ctrl/dv/env/flash_ctrl_env.core b/hw/ip/flash_ctrl/dv/env/flash_ctrl_env.core
index 790ab80..05d3a7d 100644
--- a/hw/ip/flash_ctrl/dv/env/flash_ctrl_env.core
+++ b/hw/ip/flash_ctrl/dv/env/flash_ctrl_env.core
@@ -26,8 +26,9 @@
       - seq_lib/flash_ctrl_vseq_list.sv: {is_include_file: true}
       - seq_lib/flash_ctrl_base_vseq.sv: {is_include_file: true}
       - seq_lib/flash_ctrl_common_vseq.sv: {is_include_file: true}
-      - seq_lib/flash_ctrl_rand_ops_vseq.sv: {is_include_file: true}
+      - seq_lib/flash_ctrl_rand_ops_base_vseq.sv: {is_include_file: true}
       - seq_lib/flash_ctrl_smoke_vseq.sv: {is_include_file: true}
+      - seq_lib/flash_ctrl_rand_ops_vseq.sv: {is_include_file: true}
     file_type: systemVerilogSource
 
 generate:
diff --git a/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_rand_ops_base_vseq.sv b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_rand_ops_base_vseq.sv
index ec85523..40d4a23 100644
--- a/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_rand_ops_base_vseq.sv
+++ b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_rand_ops_base_vseq.sv
@@ -6,8 +6,8 @@
 // operations. It is encouraged to extend this vseq to a custom vseq that constrains the
 // randomization by overriding the `configure_vseq()` function. See `flash_ctrl_smoke_vseq` for
 // example.
-class flash_ctrl_rand_ops_vseq extends flash_ctrl_base_vseq;
-  `uvm_object_utils(flash_ctrl_rand_ops_vseq)
+class flash_ctrl_rand_ops_base_vseq extends flash_ctrl_base_vseq;
+  `uvm_object_utils(flash_ctrl_rand_ops_base_vseq)
 
   // Number of times we run a random flash operation with a fully configured flash ctrl.
   rand uint num_flash_ops_per_cfg;
@@ -306,4 +306,4 @@
     endcase
   endfunction
 
-endclass : flash_ctrl_rand_ops_vseq
+endclass : flash_ctrl_rand_ops_base_vseq
diff --git a/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_rand_ops_vseq.sv b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_rand_ops_vseq.sv
new file mode 100644
index 0000000..ce9e7b7
--- /dev/null
+++ b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_rand_ops_vseq.sv
@@ -0,0 +1,34 @@
+// Copyright lowRISC contributors.
+// Licensed under the Apache License, Version 2.0, see LICENSE for details.
+// SPDX-License-Identifier: Apache-2.0
+
+class flash_ctrl_rand_ops_vseq extends flash_ctrl_rand_ops_base_vseq;
+  `uvm_object_utils(flash_ctrl_rand_ops_vseq)
+
+  `uvm_object_new
+
+  // Configure sequence knobs to tailor it to smoke seq.
+  virtual function void configure_vseq();
+    cfg.seq_cfg.max_num_trans = 8;
+
+    // Do fewer flash ops in each rerun for the smoke test.
+    cfg.seq_cfg.max_flash_ops_per_cfg = 20;
+
+    // Do no more than 128 words per op.
+    cfg.seq_cfg.op_max_words = 128;
+
+    // Don't enable any memory protection.
+    cfg.seq_cfg.num_en_mp_regions = 0;
+
+    // Enable default region read/program and erasability.
+    cfg.seq_cfg.default_region_read_en_pc = 100;
+    cfg.seq_cfg.default_region_program_en_pc = 100;
+    cfg.seq_cfg.default_region_erase_en_pc = 100;
+
+    // Allow banks to be erased.
+    cfg.seq_cfg.bank_erase_en_pc = 100;
+
+    cfg.seq_cfg.poll_fifo_status_pc = 0;
+  endfunction
+
+endclass : flash_ctrl_rand_ops_vseq
diff --git a/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_smoke_vseq.sv b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_smoke_vseq.sv
index 8cff2df..2da9c2c 100644
--- a/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_smoke_vseq.sv
+++ b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_smoke_vseq.sv
@@ -3,7 +3,7 @@
 // SPDX-License-Identifier: Apache-2.0
 
 // basic smoke test vseq
-class flash_ctrl_smoke_vseq extends flash_ctrl_rand_ops_vseq;
+class flash_ctrl_smoke_vseq extends flash_ctrl_rand_ops_base_vseq;
   `uvm_object_utils(flash_ctrl_smoke_vseq)
 
   `uvm_object_new
diff --git a/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_vseq_list.sv b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_vseq_list.sv
index 69ecf81..9acc479 100644
--- a/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_vseq_list.sv
+++ b/hw/ip/flash_ctrl/dv/env/seq_lib/flash_ctrl_vseq_list.sv
@@ -4,5 +4,6 @@
 
 `include "flash_ctrl_base_vseq.sv"
 `include "flash_ctrl_common_vseq.sv"
-`include "flash_ctrl_rand_ops_vseq.sv"
+`include "flash_ctrl_rand_ops_base_vseq.sv"
 `include "flash_ctrl_smoke_vseq.sv"
+`include "flash_ctrl_rand_ops_vseq.sv"
diff --git a/hw/ip/flash_ctrl/dv/flash_ctrl_sim_cfg.hjson b/hw/ip/flash_ctrl/dv/flash_ctrl_sim_cfg.hjson
index 9c05ac9..f907e6b 100644
--- a/hw/ip/flash_ctrl/dv/flash_ctrl_sim_cfg.hjson
+++ b/hw/ip/flash_ctrl/dv/flash_ctrl_sim_cfg.hjson
@@ -35,7 +35,7 @@
   overrides: [
     {
       name: design_level
-              value: "top"
+      value: "top"
     }
   ]
 
@@ -54,6 +54,11 @@
     {
       name: flash_ctrl_smoke
       uvm_test_seq: flash_ctrl_smoke_vseq
+      reseed: 5
+    }
+    {
+      name: flash_ctrl_rand_ops
+      uvm_test_seq: flash_ctrl_rand_ops_vseq
     }
   ]