Message ID | 490e1a84b1b4b8d983dc41af147191f79506cdbd.1721050709.git.federico.serafini@bugseng.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | x86: address some violations of MISRA C Rule 16.3 | expand |
On 15.07.2024 18:48, Federico Serafini wrote: > --- a/automation/eclair_analysis/ECLAIR/deviations.ecl > +++ b/automation/eclair_analysis/ECLAIR/deviations.ecl > @@ -499,7 +499,7 @@ safe." > -doc_end > > -doc_begin="Switch clauses ending with an explicit comment indicating the fallthrough intention are safe." > --config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through.? \\*/.*$,0..1))))"} > +-config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through\\.? \\*/.*$,0..2))))"} > -doc_end > > -doc_begin="Switch statements having a controlling expression of enum type deliberately do not have a default case: gcc -Wall enables -Wswitch which warns (and breaks the build as we use -Werror) if one of the enum labels is missing from the switch." This patch doesn't apply. There's a somewhat similar entry, but its doc_begin line is sufficiently different. I have no idea what's going on here; there's no dependency stated anywhere. Jan
On 24/07/24 11:45, Jan Beulich wrote: > On 15.07.2024 18:48, Federico Serafini wrote: >> --- a/automation/eclair_analysis/ECLAIR/deviations.ecl >> +++ b/automation/eclair_analysis/ECLAIR/deviations.ecl >> @@ -499,7 +499,7 @@ safe." >> -doc_end >> >> -doc_begin="Switch clauses ending with an explicit comment indicating the fallthrough intention are safe." >> --config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through.? \\*/.*$,0..1))))"} >> +-config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through\\.? \\*/.*$,0..2))))"} >> -doc_end >> >> -doc_begin="Switch statements having a controlling expression of enum type deliberately do not have a default case: gcc -Wall enables -Wswitch which warns (and breaks the build as we use -Werror) if one of the enum labels is missing from the switch." > > This patch doesn't apply. There's a somewhat similar entry, but its doc_begin > line is sufficiently different. I have no idea what's going on here; there's > no dependency stated anywhere. Right, this patch depends on [1] which has not been committed yet. [1] https://lists.xenproject.org/archives/html/xen-devel/2024-06/msg01347.html
On 24.07.2024 13:32, Federico Serafini wrote: > On 24/07/24 11:45, Jan Beulich wrote: >> On 15.07.2024 18:48, Federico Serafini wrote: >>> --- a/automation/eclair_analysis/ECLAIR/deviations.ecl >>> +++ b/automation/eclair_analysis/ECLAIR/deviations.ecl >>> @@ -499,7 +499,7 @@ safe." >>> -doc_end >>> >>> -doc_begin="Switch clauses ending with an explicit comment indicating the fallthrough intention are safe." >>> --config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through.? \\*/.*$,0..1))))"} >>> +-config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through\\.? \\*/.*$,0..2))))"} >>> -doc_end >>> >>> -doc_begin="Switch statements having a controlling expression of enum type deliberately do not have a default case: gcc -Wall enables -Wswitch which warns (and breaks the build as we use -Werror) if one of the enum labels is missing from the switch." >> >> This patch doesn't apply. There's a somewhat similar entry, but its doc_begin >> line is sufficiently different. I have no idea what's going on here; there's >> no dependency stated anywhere. > > Right, this patch depends on [1] which has not been committed yet. > > [1] > https://lists.xenproject.org/archives/html/xen-devel/2024-06/msg01347.html Which in turn isn't ready to be committed yet afaict, due to a pending question regarding ASSERT_UNREACHABLE(). In any event - please make sure you prominently state dependencies on uncommitted patches (outside of the same series of course). Jan
diff --git a/automation/eclair_analysis/ECLAIR/deviations.ecl b/automation/eclair_analysis/ECLAIR/deviations.ecl index 0d94635275..e95554acae 100644 --- a/automation/eclair_analysis/ECLAIR/deviations.ecl +++ b/automation/eclair_analysis/ECLAIR/deviations.ecl @@ -499,7 +499,7 @@ safe." -doc_end -doc_begin="Switch clauses ending with an explicit comment indicating the fallthrough intention are safe." --config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through.? \\*/.*$,0..1))))"} +-config=MC3R1.R16.3,reports+={safe, "any_area(end_loc(any_exp(text(^(?s).*/\\* [fF]all ?through\\.? \\*/.*$,0..2))))"} -doc_end -doc_begin="Switch statements having a controlling expression of enum type deliberately do not have a default case: gcc -Wall enables -Wswitch which warns (and breaks the build as we use -Werror) if one of the enum labels is missing from the switch."