MCPcopy Create free account
hub / github.com/F-Stack/f-stack / clear_pcb_flags

Function clear_pcb_flags

freebsd/amd64/amd64/machdep.c:2719–2823  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2717}
2718
2719void
2720clear_pcb_flags(struct pcb *pcb, const u_int flags)
2721{
2722
2723 __asm __volatile("andl %1,%0"
2724 : "=m" (pcb->pcb_flags) : "ir" (~flags), "m" (pcb->pcb_flags)
2725 : "cc", "memory");
2726}
2727
2728#ifdef KDB
2729
2730/*
2731 * Provide inb() and outb() as functions. They are normally only available as
2732 * inline functions, thus cannot be called from the debugger.
2733 */
2734
2735/* silence compiler warnings */
2736u_char inb_(u_short);
2737void outb_(u_short, u_char);
2738
2739u_char
2740inb_(u_short port)
2741{
2742 return inb(port);
2743}
2744
2745void
2746outb_(u_short port, u_char data)
2747{
2748 outb(port, data);
2749}
2750
2751#endif /* KDB */
2752
2753#undef memset
2754#undef memmove
2755#undef memcpy
2756
2757void *memset_std(void *buf, int c, size_t len);
2758void *memset_erms(void *buf, int c, size_t len);
2759void *memmove_std(void * _Nonnull dst, const void * _Nonnull src,
2760 size_t len);
2761void *memmove_erms(void * _Nonnull dst, const void * _Nonnull src,
2762 size_t len);
2763void *memcpy_std(void * _Nonnull dst, const void * _Nonnull src,
2764 size_t len);
2765void *memcpy_erms(void * _Nonnull dst, const void * _Nonnull src,
2766 size_t len);
2767
2768#ifdef KCSAN
2769/*
2770 * These fail to build as ifuncs when used with KCSAN.
2771 */
2772void *
2773memset(void *buf, int c, size_t len)
2774{
2775
2776 return (memset_std(buf, c, len));

Callers 8

cpu_thread_exitFunction · 0.85
cpu_copy_threadFunction · 0.85
fpudropFunction · 0.85
fpu_kern_enterFunction · 0.85
fpu_kern_leaveFunction · 0.85
exec_setregsFunction · 0.85
fpstate_dropFunction · 0.85
linux_exec_setregsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected