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

Function spinlock_enter

freebsd/amd64/amd64/machdep.c:2010–2024  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2008 "Raw EFI Memory Map");
2009
2010void
2011spinlock_enter(void)
2012{
2013 struct thread *td;
2014 register_t flags;
2015
2016 td = curthread;
2017 if (td->td_md.md_spinlock_count == 0) {
2018 flags = intr_disable();
2019 td->td_md.md_spinlock_count = 1;
2020 td->td_md.md_saved_flags = flags;
2021 critical_enter();
2022 } else
2023 td->td_md.md_spinlock_count++;
2024}
2025
2026void
2027spinlock_exit(void)

Callers 1

pmap_activateFunction · 0.70

Calls 2

intr_disableFunction · 0.50
critical_enterFunction · 0.50

Tested by

no test coverage detected