MCPcopy Create free account
hub / github.com/Bareflank/hypervisor / fail_entry

Function fail_entry

kernel/integration/bf_vm_op_create_vm.cpp:150–183  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

148 /// input is undefined.
149 ///
150 extern "C" void
151 fail_entry(bsl::safe_u64::value_type const errc, bsl::safe_u64::value_type const addr) noexcept
152 {
153 /// NOTE:
154 /// - Call into the fast fail handler. This entry point serves as a
155 /// trampoline between C and C++. Specifically, the microkernel
156 /// cannot call a member function directly, and can only call
157 /// a C style function.
158 ///
159
160 auto const ret{dispatch_fail( // --
161 g_mut_gs, // --
162 g_mut_tls, // --
163 g_mut_sys, // --
164 g_mut_intrinsic, // --
165 g_mut_vp_pool, // --
166 g_mut_vs_pool, // --
167 bsl::to_u64(errc), // --
168 bsl::to_u64(addr))};
169
170 if (bsl::unlikely(!ret)) {
171 bsl::print<bsl::V>() << bsl::here();
172 return bf_control_op_exit();
173 }
174
175 /// NOTE:
176 /// - This code should never be reached. The fast fail handler should
177 /// always call one of the "run" ABIs to return back to the
178 /// microkernel when a fast fail is finished. If this is called, it
179 /// is because the fast fail handler returned with an error.
180 ///
181
182 return bf_control_op_exit();
183 }
184
185 /// <!-- description -->
186 /// @brief Implements the VMExit entry function. This is registered

Callers

nothing calls this directly

Calls 2

dispatch_failFunction · 0.50
bf_control_op_exitFunction · 0.50

Tested by

no test coverage detected