[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3] misra: add deviation for MISRA C Rule R11.8.



On Tue, 7 Jan 2025, Jan Beulich wrote:
> On 07.01.2025 10:10, Alessandro Zucchelli wrote:
> > --- a/docs/misra/deviations.rst
> > +++ b/docs/misra/deviations.rst
> > @@ -353,6 +353,13 @@ Deviations related to MISRA C:2012 Rules:
> >         Fixing this violation would require to increase code complexity and 
> > lower readability.
> >       - Tagged as `safe` for ECLAIR.
> >  
> > +   * - R11.8
> > +     - Violations caused by function __hvm_copy occour when a const void 
> > attribute is passed,
> > +       as the const qualifier is stripped. However, in such cases, the 
> > function ensures
> > +       that it does not modify the attribute, therefore, this use is 
> > deemed safe.
> > +       Fixing this violation would require to increase code complexity and 
> > lower readability.
> > +     - Tagged as `safe` for ECLAIR.
> 
> Do you really mean "attribute" in both places the word is used? In the
> first case talk appears to be of a function argument / parameter, while
> in the second case it looks to be the buffer referenced be the
> argument / parameter which is meant.

Yes I can see what Jan is saying. What about:

Violations caused by function __hvm_copy occur when a const void
argument is passed, as the const qualifier is stripped. However, in such
cases, the function ensures that it does not modify the buffer
referenced by the argument, therefore, this use is deemed safe. Fixing
this violation would require to increase code complexity and lower
readability.




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.