1-eval_file=out_of_initial_scope.ecl
2-eval_file=language_extensions.ecl
3-eval_file=call_properties.ecl
4-eval_file=extra.ecl
5
6-doc="Hides all reports that have all areas out of scope."
7-reports+={hide,all_exp_external}
8
9-doc="The API interface files are allowed to contain unused macros."
10-config=MC3R1.R2.5,reports+={hide, "any_area(macro(loc(top(public()||kind(pseudo)))))"}
11
12-doc="Several header files are meant to be included in C as well as in C++ translation units."
13-config=MC3R1.R20.1,exception=extern_C
14
15-default_call_properties+="pointee_read(1..=never)"
16-default_call_properties+="pointee_write(1..=always)"
17-default_call_properties+="taken()"
18
19-doc_begin="These macros pass its first argument in a safe way to related compiler intrinsics."
20-config=MC3R1.R20.7,macros={safe,"^(va_start||va_arg)$"}
21-doc_end
22
23-doc_begin="The value-preserving conversions of integer constants are safe"
24-config=MC3R1.R10.1,etypes={safe,"any()","preserved_integer_constant()"}
25-config=MC3R1.R10.3,etypes={safe,"any()","preserved_integer_constant()"}
26-config=MC3R1.R10.4,etypes={safe,"any()","preserved_integer_constant()||sibling(rhs,preserved_integer_constant())"}
27-doc_end
28
29-doc_begin="Some macros are deliberately compile-time constants due to project configurability."
30-macro_selector={const_wrapper_macros,"name(CONSTEXPR)"}
31-config=MC3R1.R14.3,statements={safe, "node(if_stmt||conditional_operator)&&child(cond,wrapped(node(paren_expr)&&!macro(const_wrapper_macros), macro(const_wrapper_macros)))"}
32-doc_end
33
34-doc="Casts to log_arg_t in logging macros are safe and expected."
35-config=MC3R1.R11.6,reports+={deliberate,"any_area(any_loc(any_exp(macro(name(__LOG_ARG_CAST)))))"}
36
37-doc_begin="The following function-like macros are not writable as inline functions."
38-config=MC3R1.D4.9,macros+={deliberate,"name(ARG_UNUSED)"}
39-config=MC3R1.D4.9,macros+={deliberate,"name(CONSTEXPR)"}
40-config=MC3R1.D4.9,macros+={deliberate,"name(compiler_barrier)"}
41-config=MC3R1.D4.9,macros+={deliberate,"name(likely)"}
42-config=MC3R1.D4.9,macros+={deliberate,"name(unlikely)"}
43-doc_end
44
45-doc_begin="For the following function-like macros it should be decided whether substitution with equivalent static inline functions is wanted and feasible."
46-config=MC3R1.D4.9,macros+={questionable,"name(ATOMIC_ELEM)"}
47-config=MC3R1.D4.9,macros+={questionable,"name(ATOMIC_MASK)"}
48-config=MC3R1.D4.9,macros+={questionable,"name(BIT32)"}
49-config=MC3R1.D4.9,macros+={questionable,"name(BIT64)"}
50-config=MC3R1.D4.9,macros+={questionable,"name(BIT64_MASK)"}
51-config=MC3R1.D4.9,macros+={questionable,"name(BIT_MASK)"}
52-config=MC3R1.D4.9,macros+={questionable,"name(DEVICE_MMIO_GET)"}
53-config=MC3R1.D4.9,macros+={questionable,"name(DEVICE_MMIO_MAP)"}
54-config=MC3R1.D4.9,macros+={questionable,"name(DEVICE_MMIO_RAM_PTR)"}
55-config=MC3R1.D4.9,macros+={questionable,"name(IN)"}
56-config=MC3R1.D4.9,macros+={questionable,"name(LOG_CORE_INIT)"}
57-config=MC3R1.D4.9,macros+={questionable,"name(MAX)"}
58-config=MC3R1.D4.9,macros+={questionable,"name(MB)"}
59-config=MC3R1.D4.9,macros+={questionable,"name(MIN)"}
60-config=MC3R1.D4.9,macros+={questionable,"name(OUT)"}
61-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_BDF)"}
62-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_BDF_TO_BUS)"}
63-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_BAR_64)"}
64-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_BAR_ADDR)"}
65-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_BAR_INVAL_FLAGS)"}
66-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_BAR_IO)"}
67-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_BAR_MEM)"}
68-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_CAPPTR_FIRST)"}
69-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_CAP_ID)"}
70-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_CAP_NEXT)"}
71-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_EXT_CAP_ID)"}
72-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_EXT_CAP_NEXT)"}
73-config=MC3R1.D4.9,macros+={questionable,"name(PCIE_CONF_INTR_IRQ)"}
74-config=MC3R1.D4.9,macros+={questionable,"name(POINTER_TO_UINT)"}
75-config=MC3R1.D4.9,macros+={questionable,"name(ROUND_DOWN)"}
76-config=MC3R1.D4.9,macros+={questionable,"name(ROUND_UP)"}
77-config=MC3R1.D4.9,macros+={questionable,"name(UINT_TO_POINTER)"}
78-config=MC3R1.D4.9,macros+={questionable,"name(Z_BOOT_VIRT_TO_PHYS)"}
79-config=MC3R1.D4.9,macros+={questionable,"name(Z_IRQ_TO_INTERRUPT_VECTOR)"}
80-config=MC3R1.D4.9,macros+={questionable,"name(Z_KERNEL_STACK_SIZE_ADJUST)"}
81-config=MC3R1.D4.9,macros+={questionable,"name(Z_LOG_MSG2_ALIGNED_WLEN)"}
82-config=MC3R1.D4.9,macros+={questionable,"name(Z_MEM_PHYS_ADDR)"}
83-config=MC3R1.D4.9,macros+={questionable,"name(Z_MEM_VIRT_ADDR)"}
84-config=MC3R1.D4.9,macros+={questionable,"name(Z_STACK_PTR_ALIGN)"}
85-config=MC3R1.D4.9,macros+={questionable,"name(Z_THREAD_STACK_SIZE_ADJUST)"}
86-config=MC3R1.D4.9,macros+={questionable,"name(Z_TICK_ABS)"}
87-config=MC3R1.D4.9,macros+={questionable,"name(ceiling_fraction)"}
88-config=MC3R1.D4.9,macros+={questionable,"name(irq_enable)"}
89-config=MC3R1.D4.9,macros+={questionable,"name(irq_lock)"}
90-config=MC3R1.D4.9,macros+={questionable,"name(irq_unlock)"}
91-config=MC3R1.D4.9,macros+={questionable,"name(k_panic)"}
92-doc_end
93
94-doc="Use of CODE_UNREACHABLE is defensive programming."
95-config=MC3R1.R2.1,reports+={safe,"any_area(any_loc(any_exp(macro(name(CODE_UNREACHABLE)))))"}
96
97-doc_begin="Identifers beginning with _ are tolerated."
98-config=MC3R1.R21.1,macros={relied,"^_.*$"}
99-config=MC3R1.R21.2,declarations={relied,"^(.*::)?_.*$"}
100-doc_end
101
102-eval_file=adopted_code.ecl
103-eval_file=adopted_deviations.ecl
104
105-doc="Hide reports marked as compliant."
106-remap_rtag={compliant,hide}
107
108-doc="Hide reports marked as safe."
109-remap_rtag={safe,hide}
110
111-doc="Hide reports marked as relied."
112-remap_rtag={relied,hide}
113
114-doc="Hide reports marked as questionable."
115-remap_rtag={questionable,hide}
116
117-doc="Hide reports marked as deliberate."
118-remap_rtag={deliberate,hide}
119
120-doc="Hide reports marked as disapplied."
121-remap_rtag={disapplied,hide}
122