Introduce process quota management
This commit is contained in:
@@ -12,6 +12,7 @@
|
||||
#include <xtos.hh>
|
||||
|
||||
#include <ps/process.hh>
|
||||
#include <ps/quota.hh>
|
||||
#include <ps/thread.hh>
|
||||
|
||||
|
||||
|
||||
38
xtoskrnl/includes/ps/quota.hh
Normal file
38
xtoskrnl/includes/ps/quota.hh
Normal file
@@ -0,0 +1,38 @@
|
||||
/**
|
||||
* PROJECT: ExectOS
|
||||
* COPYRIGHT: See COPYING.md in the top level directory
|
||||
* FILE: xtoskrnl/includes/ps/quota.hh
|
||||
* DESCRIPTION: Process Quota Management
|
||||
* DEVELOPERS: Aiken Harris <harraiken91@gmail.com>
|
||||
*/
|
||||
|
||||
#ifndef __XTOSKRNL_PS_QUOTA_HH
|
||||
#define __XTOSKRNL_PS_QUOTA_HH
|
||||
|
||||
#include <xtos.hh>
|
||||
|
||||
|
||||
/* Process and thread management */
|
||||
namespace PS
|
||||
{
|
||||
class Quota
|
||||
{
|
||||
private:
|
||||
STATIC EPROCESS_QUOTA_BLOCK DefaultQuotaBlock;
|
||||
|
||||
public:
|
||||
STATIC XTAPI VOID ReturnSharedPoolQuota(IN PEPROCESS_QUOTA_BLOCK QuotaBlock,
|
||||
IN SIZE_T PagedAmount,
|
||||
IN SIZE_T NonPagedAmount);
|
||||
|
||||
private:
|
||||
STATIC XTAPI VOID DereferenceQuotaBlock(IN PEPROCESS_QUOTA_BLOCK QuotaBlock);
|
||||
STATIC XTFASTCALL VOID ReturnProcessQuota(IN PEPROCESS_QUOTA_BLOCK QuotaBlock,
|
||||
IN PEPROCESS Process,
|
||||
IN PS_QUOTA_TYPE QuotaType,
|
||||
IN SIZE_T Amount);
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
#endif /* __XTOSKRNL_PS_QUOTA_HH */
|
||||
Reference in New Issue
Block a user