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

Function fail_entry

kernel/integration/bf_mem_op_alloc_page.cpp:160–193  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

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