Re: CVS commit: src/sys/kern

2019-12-08 Thread Martin Husemann
On Sun, Dec 08, 2019 at 12:58:20PM +0100, Maxime Villard wrote:
> kMSan has special constraints which, in this specific case, come down to: each
> function called from a KCOV instrumentation callback must be a static inline
> tagged with __nomsan.
> 
> This was not the case with the updated in_interrupt(), but also still isn't 
> the
> case with the lwp_getspecific() call, which will have to be dropped.

This does not sound like a good reason to introduce MD code in sys/kern to
me. Could should not be made worse to deal with sanitizer restrictions.

Are there any alternatives?

Martin


Re: CVS commit: src/sys/kern

2019-12-08 Thread Maxime Villard

Le 08/12/2019 à 00:51, Kamil Rytarowski a écrit :

On 08.12.2019 00:35, matthew green wrote:

Module Name:src
Committed By:   kamil
Date:   Sat Dec  7 19:50:34 UTC 2019

Modified Files:
src/sys/kern: subr_kcov.c

Log Message:
Revert the in_interrupt() change to use again the x86 specific code

This is prerequisite for kMSan and upcoming kernel changes.

Discussed with 


why is this?  what is the problem?


kMSan has special constraints which, in this specific case, come down to: each
function called from a KCOV instrumentation callback must be a static inline
tagged with __nomsan.

This was not the case with the updated in_interrupt(), but also still isn't the
case with the lwp_getspecific() call, which will have to be dropped.