-
Notifications
You must be signed in to change notification settings - Fork 217
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #599 from klystron78/vxworks7-2
Fix #610, Add vxworks7 support
- Loading branch information
Showing
11 changed files
with
196 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
/* | ||
* NASA Docket No. GSC-18,370-1, and identified as "Operating System Abstraction Layer" | ||
* | ||
* Copyright (c) 2019 United States Government as represented by | ||
* the Administrator of the National Aeronautics and Space Administration. | ||
* All Rights Reserved. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
/** | ||
* \file os-impl-dirs.c | ||
* \ingroup vxworks | ||
* \author [email protected] | ||
* | ||
*/ | ||
|
||
/**************************************************************************************** | ||
INCLUDE FILES | ||
****************************************************************************************/ | ||
|
||
#include "os-vxworks.h" | ||
#include "os-impl-dirs.h" | ||
#include "os-shared-dir.h" | ||
|
||
|
||
/* | ||
* The directory handle table. | ||
*/ | ||
OS_impl_dir_internal_record_t OS_impl_dir_table[OS_MAX_NUM_OPEN_DIRS]; | ||
|
||
|
||
/*---------------------------------------------------------------- | ||
* | ||
* Function: OS_VxWorks_DirAPI_Impl_Init | ||
* | ||
* Purpose: Local helper routine, not part of OSAL API. | ||
* | ||
*-----------------------------------------------------------------*/ | ||
int32 OS_VxWorks_DirAPI_Impl_Init(void) | ||
{ | ||
memset(OS_impl_dir_table, 0, sizeof(OS_impl_dir_table)); | ||
return OS_SUCCESS; | ||
} /* end OS_VxWorks_DirAPI_Impl_Init */ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ set(VXWORKS_MODULE_LIST | |
console | ||
countsem | ||
dirs | ||
dirs-globals | ||
files | ||
filesys | ||
idmap | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
src/unit-test-coverage/vxworks/adaptors/src/ut-adaptor-dirtable-stub.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
/* | ||
* NASA Docket No. GSC-18,370-1, and identified as "Operating System Abstraction Layer" | ||
* | ||
* Copyright (c) 2019 United States Government as represented by | ||
* the Administrator of the National Aeronautics and Space Administration. | ||
* All Rights Reserved. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
/** | ||
* \file ut-adaptor-filetable-stub.c | ||
* \ingroup adaptors | ||
* \author [email protected] | ||
* | ||
*/ | ||
/* pull in the OSAL configuration */ | ||
#include "osconfig.h" | ||
#include "ut-adaptor-filetable-stub.h" | ||
|
||
#include <os-vxworks.h> | ||
#include <os-impl-dirs.h> | ||
#include <os-shared-dir.h> | ||
|
||
OS_impl_dir_internal_record_t OS_impl_dir_table[OS_MAX_NUM_OPEN_DIRS]; | ||
|
76 changes: 76 additions & 0 deletions
76
src/unit-test-coverage/vxworks/src/coveragetest-dirs-globals.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
/* | ||
* NASA Docket No. GSC-18,370-1, and identified as "Operating System Abstraction Layer" | ||
* | ||
* Copyright (c) 2019 United States Government as represented by | ||
* the Administrator of the National Aeronautics and Space Administration. | ||
* All Rights Reserved. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
/** | ||
* \file coveragetest-dirs-globals.c | ||
* \ingroup vxworks | ||
* \author [email protected] | ||
* | ||
*/ | ||
|
||
#include "os-vxworks-coveragetest.h" | ||
#include "ut-adaptor-dirs.h" | ||
|
||
#include "os-shared-dir.h" | ||
|
||
#include <OCS_stdlib.h> | ||
#include <OCS_taskLib.h> | ||
#include <OCS_dirent.h> | ||
#include <OCS_unistd.h> | ||
#include <OCS_stat.h> | ||
|
||
void Test_OS_VxWorks_DirAPI_Impl_Init(void) | ||
{ | ||
/* | ||
* Test Case For: | ||
* int32 OS_VxWorks_DirAPI_Impl_Init(void) | ||
*/ | ||
OSAPI_TEST_FUNCTION_RC(UT_Call_OS_VxWorks_DirAPI_Impl_Init(), OS_SUCCESS); | ||
} | ||
|
||
/* ------------------- End of test cases --------------------------------------*/ | ||
|
||
/* Osapi_Test_Setup | ||
* | ||
* Purpose: | ||
* Called by the unit test tool to set up the app prior to each test | ||
*/ | ||
void Osapi_Test_Setup(void) | ||
{ | ||
UT_ResetState(0); | ||
} | ||
|
||
/* | ||
* Osapi_Test_Teardown | ||
* | ||
* Purpose: | ||
* Called by the unit test tool to tear down the app after each test | ||
*/ | ||
void Osapi_Test_Teardown(void) {} | ||
|
||
/* UtTest_Setup | ||
* | ||
* Purpose: | ||
* Registers the test cases to execute with the unit test tool | ||
*/ | ||
void UtTest_Setup(void) | ||
{ | ||
ADD_TEST(OS_VxWorks_DirAPI_Impl_Init); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters