made initialization routine a regular subroutine

This commit is contained in:
Joel Sherrill
1996-04-22 16:46:00 +00:00
parent a155b3c52d
commit 6365f81898
6 changed files with 0 additions and 264 deletions
@@ -17,53 +17,6 @@
#ifndef __WORKSPACE_inl
#define __WORKSPACE_inl
/*PAGE
*
* _Workspace_Handler_initialization
*
* DESCRIPTION:
*
* This routine performs the initialization necessary for this handler.
*/
STATIC INLINE void _Workspace_Handler_initialization(
void *starting_address,
unsigned32 size
)
{
unsigned32 *zero_out_array;
unsigned32 index;
unsigned32 memory_available;
if ( !starting_address || !_Addresses_Is_aligned( starting_address ) )
_Internal_error_Occurred(
INTERNAL_ERROR_CORE,
TRUE,
INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS
);
if ( _CPU_Table.do_zero_of_workspace ) {
for( zero_out_array = (unsigned32 *) starting_address, index = 0 ;
index < size / 4 ;
index++ )
zero_out_array[ index ] = 0;
}
memory_available = _Heap_Initialize(
&_Workspace_Area,
starting_address,
size,
CPU_HEAP_ALIGNMENT
);
if ( memory_available == 0 )
_Internal_error_Occurred(
INTERNAL_ERROR_CORE,
TRUE,
INTERNAL_ERROR_TOO_LITTLE_WORKSPACE
);
}
/*PAGE
*
* _Workspace_Allocate
-47
View File
@@ -17,53 +17,6 @@
#ifndef __WORKSPACE_inl
#define __WORKSPACE_inl
/*PAGE
*
* _Workspace_Handler_initialization
*
* DESCRIPTION:
*
* This routine performs the initialization necessary for this handler.
*/
STATIC INLINE void _Workspace_Handler_initialization(
void *starting_address,
unsigned32 size
)
{
unsigned32 *zero_out_array;
unsigned32 index;
unsigned32 memory_available;
if ( !starting_address || !_Addresses_Is_aligned( starting_address ) )
_Internal_error_Occurred(
INTERNAL_ERROR_CORE,
TRUE,
INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS
);
if ( _CPU_Table.do_zero_of_workspace ) {
for( zero_out_array = (unsigned32 *) starting_address, index = 0 ;
index < size / 4 ;
index++ )
zero_out_array[ index ] = 0;
}
memory_available = _Heap_Initialize(
&_Workspace_Area,
starting_address,
size,
CPU_HEAP_ALIGNMENT
);
if ( memory_available == 0 )
_Internal_error_Occurred(
INTERNAL_ERROR_CORE,
TRUE,
INTERNAL_ERROR_TOO_LITTLE_WORKSPACE
);
}
/*PAGE
*
* _Workspace_Allocate
@@ -17,47 +17,6 @@
#ifndef __WORKSPACE_inl
#define __WORKSPACE_inl
/*PAGE
*
* _Workspace_Handler_initialization
*
*/
#define _Workspace_Handler_initialization( _starting_address, _size ) \
{ \
unsigned32 *zero_out_array; \
unsigned32 index; \
unsigned32 memory_available; \
\
if ( !(_starting_address) || !_Addresses_Is_aligned( (_starting_address) ) ) \
_Internal_error_Occurred( \
INTERNAL_ERROR_CORE, \
TRUE, \
INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS \
); \
\
if ( _CPU_Table.do_zero_of_workspace ) { \
for( zero_out_array = (unsigned32 *) (_starting_address), index = 0 ; \
index < (_size) / 4 ; \
index++ ) \
zero_out_array[ index ] = 0; \
} \
\
memory_available = _Heap_Initialize( \
&_Workspace_Area, \
(_starting_address), \
(_size), \
CPU_HEAP_ALIGNMENT \
); \
\
if ( memory_available == 0 ) \
_Internal_error_Occurred( \
INTERNAL_ERROR_CORE, \
TRUE, \
INTERNAL_ERROR_TOO_LITTLE_WORKSPACE \
); \
}
/*PAGE
*
* _Workspace_Allocate
-41
View File
@@ -17,47 +17,6 @@
#ifndef __WORKSPACE_inl
#define __WORKSPACE_inl
/*PAGE
*
* _Workspace_Handler_initialization
*
*/
#define _Workspace_Handler_initialization( _starting_address, _size ) \
{ \
unsigned32 *zero_out_array; \
unsigned32 index; \
unsigned32 memory_available; \
\
if ( !(_starting_address) || !_Addresses_Is_aligned( (_starting_address) ) ) \
_Internal_error_Occurred( \
INTERNAL_ERROR_CORE, \
TRUE, \
INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS \
); \
\
if ( _CPU_Table.do_zero_of_workspace ) { \
for( zero_out_array = (unsigned32 *) (_starting_address), index = 0 ; \
index < (_size) / 4 ; \
index++ ) \
zero_out_array[ index ] = 0; \
} \
\
memory_available = _Heap_Initialize( \
&_Workspace_Area, \
(_starting_address), \
(_size), \
CPU_HEAP_ALIGNMENT \
); \
\
if ( memory_available == 0 ) \
_Internal_error_Occurred( \
INTERNAL_ERROR_CORE, \
TRUE, \
INTERNAL_ERROR_TOO_LITTLE_WORKSPACE \
); \
}
/*PAGE
*
* _Workspace_Allocate
@@ -17,53 +17,6 @@
#ifndef __WORKSPACE_inl
#define __WORKSPACE_inl
/*PAGE
*
* _Workspace_Handler_initialization
*
* DESCRIPTION:
*
* This routine performs the initialization necessary for this handler.
*/
STATIC INLINE void _Workspace_Handler_initialization(
void *starting_address,
unsigned32 size
)
{
unsigned32 *zero_out_array;
unsigned32 index;
unsigned32 memory_available;
if ( !starting_address || !_Addresses_Is_aligned( starting_address ) )
_Internal_error_Occurred(
INTERNAL_ERROR_CORE,
TRUE,
INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS
);
if ( _CPU_Table.do_zero_of_workspace ) {
for( zero_out_array = (unsigned32 *) starting_address, index = 0 ;
index < size / 4 ;
index++ )
zero_out_array[ index ] = 0;
}
memory_available = _Heap_Initialize(
&_Workspace_Area,
starting_address,
size,
CPU_HEAP_ALIGNMENT
);
if ( memory_available == 0 )
_Internal_error_Occurred(
INTERNAL_ERROR_CORE,
TRUE,
INTERNAL_ERROR_TOO_LITTLE_WORKSPACE
);
}
/*PAGE
*
* _Workspace_Allocate
@@ -17,47 +17,6 @@
#ifndef __WORKSPACE_inl
#define __WORKSPACE_inl
/*PAGE
*
* _Workspace_Handler_initialization
*
*/
#define _Workspace_Handler_initialization( _starting_address, _size ) \
{ \
unsigned32 *zero_out_array; \
unsigned32 index; \
unsigned32 memory_available; \
\
if ( !(_starting_address) || !_Addresses_Is_aligned( (_starting_address) ) ) \
_Internal_error_Occurred( \
INTERNAL_ERROR_CORE, \
TRUE, \
INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS \
); \
\
if ( _CPU_Table.do_zero_of_workspace ) { \
for( zero_out_array = (unsigned32 *) (_starting_address), index = 0 ; \
index < (_size) / 4 ; \
index++ ) \
zero_out_array[ index ] = 0; \
} \
\
memory_available = _Heap_Initialize( \
&_Workspace_Area, \
(_starting_address), \
(_size), \
CPU_HEAP_ALIGNMENT \
); \
\
if ( memory_available == 0 ) \
_Internal_error_Occurred( \
INTERNAL_ERROR_CORE, \
TRUE, \
INTERNAL_ERROR_TOO_LITTLE_WORKSPACE \
); \
}
/*PAGE
*
* _Workspace_Allocate