Files
exectos/xtoskrnl/rtl/amd64/dispatch.cc
Aiken Harris 2f25107d09
All checks were successful
Builds / ExectOS (amd64, release) (push) Successful in 30s
Builds / ExectOS (amd64, debug) (push) Successful in 31s
Builds / ExectOS (i686, release) (push) Successful in 27s
Builds / ExectOS (i686, debug) (push) Successful in 29s
Replace legacy thread retrieval function calls
2025-09-16 09:20:59 +02:00

34 lines
931 B
C++

/**
* PROJECT: ExectOS
* COPYRIGHT: See COPYING.md in the top level directory
* FILE: xtoskrnl/rtl/amd64/dispatch.cc
* DESCRIPTION: Dispatching support for AMD64 architecture
* DEVELOPERS: Rafal Kupiec <belliash@codingworkshop.eu.org>
*/
#include <xtos.hh>
/**
* Returns the stack limits for the current thread.
*
* @param StackBase
* Supplies a pointer to memory area, where the stack base will be stored.
*
* @param StackLimit
* Suppliws a pointer to memory area, where the stack limit will be stored.
*
* @return This routine does not return any value.
*
* @since XT 1.0
*/
XTAPI
VOID
RTL::Dispatcher::GetStackLimits(OUT PULONG_PTR StackBase,
OUT PULONG_PTR StackLimit)
{
PKTHREAD Thread = KE::Processor::GetCurrentThread();
*StackBase = (ULONG_PTR)Thread->StackBase;
*StackLimit = (ULONG_PTR)Thread->StackLimit;
}