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

Function fail_entry

kernel/integration/bf_debug_op_write_str.cpp:143–176  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

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