From af8252641d9e19dc269912cc1522a602a5cd27d5 Mon Sep 17 00:00:00 2001 From: Robert Schilling Date: Sun, 2 Feb 2025 16:44:21 +0100 Subject: [PATCH] [hw,top_racl_pkg,lint] Explixctely lint the RACL pkg for long file name the RACL might be pulled in in blocl level DV and there pullute tje lint. Therefore, we need to add a dedicated waiver rather than waiving the package in the block level, e.g., in Darjeeling. Signed-off-by: Robert Schilling --- hw/top_darjeeling/lint/top_darjeeling.waiver | 3 -- hw/top_darjeeling/lint/top_racl_pkg.waiver | 8 +++++ .../top_darjeeling_racl_pkg.core | 10 ++++++ hw/top_earlgrey/lint/top_racl_pkg.waiver | 8 +++++ hw/top_earlgrey/top_earlgrey_racl_pkg.core | 10 ++++++ .../lint/top_racl_pkg.waiver | 8 +++++ .../top_englishbreakfast.core | 1 + .../top_englishbreakfast_racl_pkg.core | 31 +++++++++++++++++++ 8 files changed, 76 insertions(+), 3 deletions(-) create mode 100644 hw/top_darjeeling/lint/top_racl_pkg.waiver create mode 100644 hw/top_earlgrey/lint/top_racl_pkg.waiver create mode 100644 hw/top_englishbreakfast/lint/top_racl_pkg.waiver create mode 100644 hw/top_englishbreakfast/top_englishbreakfast_racl_pkg.core diff --git a/hw/top_darjeeling/lint/top_darjeeling.waiver b/hw/top_darjeeling/lint/top_darjeeling.waiver index b4c7ee0cd8532..6822e53f8d53f 100644 --- a/hw/top_darjeeling/lint/top_darjeeling.waiver +++ b/hw/top_darjeeling/lint/top_darjeeling.waiver @@ -71,6 +71,3 @@ waive -rules SAME_NAME_TYPE -location {spi_device.sv mbx.sv} -regexp {'mbx' is u # intentionally unused waive -rules {NOT_READ HIER_NET_NOT_READ} -location {top_darjeeling.sv} -regexp {.*cio_otp_ctrl_test_(en_)?d2p\[7:1\].* is not read} \ -comment "otp test bus made deliberately larger on purpose" - -waive -rules {LINE_LENGTH} -location {top_racl_pkg.sv} -regexp {Line length of \[[0-9]+\] exceeds 100 character limit} \ - -comment "top_racl_pkg is auto-generated and expected to exceed line length limit" diff --git a/hw/top_darjeeling/lint/top_racl_pkg.waiver b/hw/top_darjeeling/lint/top_racl_pkg.waiver new file mode 100644 index 0000000000000..432c79ea07d6d --- /dev/null +++ b/hw/top_darjeeling/lint/top_racl_pkg.waiver @@ -0,0 +1,8 @@ +# Copyright lowRISC contributors (OpenTitan project). +# Licensed under the Apache License, Version 2.0, see LICENSE for details. +# SPDX-License-Identifier: Apache-2.0 +# +# waiver file for top_racl_pkg + +waive -rules {LINE_LENGTH} -location {top_racl_pkg.sv} -regexp {Line length of [0-9]+ exceeds 100 character limit} \ + -comment "top_racl_pkg is auto-generated and expected to exceed line length limit" diff --git a/hw/top_darjeeling/top_darjeeling_racl_pkg.core b/hw/top_darjeeling/top_darjeeling_racl_pkg.core index b6ebe966f8f84..eb69755fd78cd 100644 --- a/hw/top_darjeeling/top_darjeeling_racl_pkg.core +++ b/hw/top_darjeeling/top_darjeeling_racl_pkg.core @@ -15,7 +15,17 @@ filesets: - rtl/autogen/top_racl_pkg.sv file_type: systemVerilogSource + files_ascentlint_waiver: + depend: + # common waivers + - lowrisc:lint:common + - lowrisc:lint:comportable + files: + - lint/top_racl_pkg.waiver + file_type: waiver + targets: default: &default_target filesets: + - tool_ascentlint ? (files_ascentlint_waiver) - files_rtl diff --git a/hw/top_earlgrey/lint/top_racl_pkg.waiver b/hw/top_earlgrey/lint/top_racl_pkg.waiver new file mode 100644 index 0000000000000..432c79ea07d6d --- /dev/null +++ b/hw/top_earlgrey/lint/top_racl_pkg.waiver @@ -0,0 +1,8 @@ +# Copyright lowRISC contributors (OpenTitan project). +# Licensed under the Apache License, Version 2.0, see LICENSE for details. +# SPDX-License-Identifier: Apache-2.0 +# +# waiver file for top_racl_pkg + +waive -rules {LINE_LENGTH} -location {top_racl_pkg.sv} -regexp {Line length of [0-9]+ exceeds 100 character limit} \ + -comment "top_racl_pkg is auto-generated and expected to exceed line length limit" diff --git a/hw/top_earlgrey/top_earlgrey_racl_pkg.core b/hw/top_earlgrey/top_earlgrey_racl_pkg.core index 1d25e0a0e50ed..b819710bcfeb4 100644 --- a/hw/top_earlgrey/top_earlgrey_racl_pkg.core +++ b/hw/top_earlgrey/top_earlgrey_racl_pkg.core @@ -15,7 +15,17 @@ filesets: - rtl/autogen/top_racl_pkg.sv file_type: systemVerilogSource + files_ascentlint_waiver: + depend: + # common waivers + - lowrisc:lint:common + - lowrisc:lint:comportable + files: + - lint/top_racl_pkg.waiver + file_type: waiver + targets: default: &default_target filesets: + - tool_ascentlint ? (files_ascentlint_waiver) - files_rtl diff --git a/hw/top_englishbreakfast/lint/top_racl_pkg.waiver b/hw/top_englishbreakfast/lint/top_racl_pkg.waiver new file mode 100644 index 0000000000000..432c79ea07d6d --- /dev/null +++ b/hw/top_englishbreakfast/lint/top_racl_pkg.waiver @@ -0,0 +1,8 @@ +# Copyright lowRISC contributors (OpenTitan project). +# Licensed under the Apache License, Version 2.0, see LICENSE for details. +# SPDX-License-Identifier: Apache-2.0 +# +# waiver file for top_racl_pkg + +waive -rules {LINE_LENGTH} -location {top_racl_pkg.sv} -regexp {Line length of [0-9]+ exceeds 100 character limit} \ + -comment "top_racl_pkg is auto-generated and expected to exceed line length limit" diff --git a/hw/top_englishbreakfast/top_englishbreakfast.core b/hw/top_englishbreakfast/top_englishbreakfast.core index 0093381a8d80e..73c783e6481ff 100644 --- a/hw/top_englishbreakfast/top_englishbreakfast.core +++ b/hw/top_englishbreakfast/top_englishbreakfast.core @@ -7,6 +7,7 @@ description: "Technology-independent English Breakfast toplevel" filesets: files_rtl_generic: depend: + - lowrisc:systems:top_earlgrey_racl_pkg - lowrisc:opentitan:top_englishbreakfast_pwrmgr_pkg - lowrisc:opentitan:top_earlgrey_alert_handler_pkg # Manually instantiated diff --git a/hw/top_englishbreakfast/top_englishbreakfast_racl_pkg.core b/hw/top_englishbreakfast/top_englishbreakfast_racl_pkg.core new file mode 100644 index 0000000000000..94a2a2197d362 --- /dev/null +++ b/hw/top_englishbreakfast/top_englishbreakfast_racl_pkg.core @@ -0,0 +1,31 @@ +CAPI=2: +# Copyright lowRISC contributors (OpenTitan project). +# Licensed under the Apache License, Version 2.0, see LICENSE for details. +# SPDX-License-Identifier: Apache-2.0 +name: "lowrisc:systems:top_englishbreakfast_racl_pkg:0.1" +description: "Autogenerated top_englishbreakfast_racl_pkg used in RTL and DV." +virtual: + - lowrisc:systems:top_racl_pkg + +filesets: + files_rtl: + depend: + - lowrisc:tlul:headers + files: + - rtl/autogen/top_racl_pkg.sv + file_type: systemVerilogSource + + files_ascentlint_waiver: + depend: + # common waivers + - lowrisc:lint:common + - lowrisc:lint:comportable + files: + - lint/top_racl_pkg.waiver + file_type: waiver + +targets: + default: &default_target + filesets: + - tool_ascentlint ? (files_ascentlint_waiver) + - files_rtl