[PATCH 00/12] Enable PPS API in RTEMS6

2022-04-07 Thread Gabriel Moyano
e and call the functions pps_capture() and pps_event(). Gabriel Moyano (12): kern_ntptime.c: Disable freebsd features kern_ntptime.c: Enable status variables when PPS_SYNC is defined kern_ntptime.c: Add lmax() qmin() definitions timepps: Add missing include for atomic type kern_tc.

[PATCH 01/12] kern_ntptime.c: Disable freebsd features

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index cb39133408..610386833c 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -73,9

[PATCH 02/12] kern_ntptime.c: Enable status variables when PPS_SYNC is defined

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index 610386833c..3bbb3290f9 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -534,6 +534,7 @@

[PATCH 03/12] kern_ntptime.c: Add lmax() qmin() definitions

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index 3bbb3290f9..d4a233f67e 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -71,6 +71,8 @@

[PATCH 04/12] timepps: Add missing include for atomic type

2022-04-07 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 01212f0b43..621afb08ec 100644 --- a/cpukit/include/sys/timepps.h +++ b/cpukit/include/sys/timepps.h @@ -24,6 +24,9 @@ #include #include

[PATCH 05/12] kern_tc.c: Replace atomic functions required by PPS API

2022-04-07 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 4 cpukit/score/src/kern_tc.c | 7 +++ 2 files changed, 11 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 621afb08ec..5703381ffa 100644 --- a/cpukit/include/sys/timepps.h +++

[PATCH 07/12] kern_tc.c: Remove verification of th_generation for pps functions

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index a5c7b4b841..a8ba268ea3 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -2109,9 +2109,11 @@ pps_capture(struct

[PATCH 06/12] kern_tc.c: Replace FREEBSD event mechanism by adding pointers to function

2022-04-07 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 11 +++ cpukit/score/src/kern_tc.c | 20 +++- 2 files changed, 30 insertions(+), 1 deletion(-) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 5703381ffa..a72579d5d7 100644 ---

[PATCH 09/12] kern_tc.c: Add definitions required by PPS API

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index dd718b3bab..5db924cebe 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -56,6 +56,11 @@ #definetimecounter

[PATCH 10/12] kern_tc.c: Enable PPS API support

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 4 1 file changed, 4 deletions(-) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 5db924cebe..c94e85f85b 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -1896,7 +1896,6 @@ SYSCTL_PROC(_kern_timecounter,

[PATCH 08/12] kern_tc.c: Add definition of tc_getfrequency in kern_tc

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index a8ba268ea3..dd718b3bab 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -1506,7 +1506,6 @@ unlock: #endif /*

[PATCH 11/12] kern_ntptime: Add define in order to remove warning

2022-04-07 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index d4a233f67e..d6ea739f5b 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -58,6 +58,9 @@

[PATCH 12/12] spec/build/cpukit: Add option for enabling PPS synchronization

2022-04-07 Thread Gabriel Moyano
--- spec/build/cpukit/cpuopts.yml| 2 ++ spec/build/cpukit/optppssync.yml | 16 2 files changed, 18 insertions(+) create mode 100644 spec/build/cpukit/optppssync.yml diff --git a/spec/build/cpukit/cpuopts.yml b/spec/build/cpukit/cpuopts.yml index 301d49ccea..db0e05395f

[PATCH v4 04/11] kern_tc.c: Replace FreeBSD event mechanism by adding pointers to function

2022-05-20 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 24 + cpukit/score/src/kern_tc.c | 41 2 files changed, 65 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 5703381ffa..2513298557 100644 ---

[PATCH v4 03/11] kern_tc.c: Add atomic dependencies required by the PPS API

2022-05-20 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 7 +++ cpukit/score/src/kern_tc.c | 7 +++ 2 files changed, 14 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 01212f0b43..5703381ffa 100644 --- a/cpukit/include/sys/timepps.h +++

[PATCH v4 05/11] timecounter.h: Rename tc_getfrequency() to _Timecounter_Get_frequency()

2022-05-20 Thread Gabriel Moyano
--- cpukit/include/rtems/score/timecounter.h | 8 cpukit/include/sys/timetc.h | 3 +++ cpukit/score/src/kern_tc.c | 2 +- 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/cpukit/include/rtems/score/timecounter.h

[PATCH v4 00/11] ENABLE PPS in RTEMS6

2022-05-20 Thread Gabriel Moyano
This is the 4th version of the patches for enabling the PPS API in RTEMS6. Gabriel Moyano (11): kern_ntptime.c: Disable freebsd features kern_ntptime.c: Add lmax() qmin() definitions kern_tc.c: Add atomic dependencies required by the PPS API kern_tc.c: Replace FreeBSD event mechanism

[PATCH v4 02/11] kern_ntptime.c: Add lmax() qmin() definitions

2022-05-20 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index 610386833c..da6b425064 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -71,6 +71,8 @@

[PATCH v4 01/11] kern_ntptime.c: Disable freebsd features

2022-05-20 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index cb39133408..610386833c 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -73,9

[PATCH v4 09/11] timepps.h: PPS_SYNC defined by default

2022-05-20 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 1 + cpukit/score/src/kern_ntptime.c | 10 -- testsuites/sptests/spntp01/init.c | 2 +- 3 files changed, 2 insertions(+), 11 deletions(-) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 2513298557..30bca70c8d

[PATCH v4 06/11] kern_tc.c: Add definitions required by PPS API

2022-05-20 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 2e2ffd8ef1..25d0837b63 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -56,6 +56,11 @@ #definetimecounter

[PATCH v4 08/11] kern_ntptime.c: Add define in order to remove warning

2022-05-20 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index da6b425064..c1b4013e9b 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -58,6 +58,9 @@

[PATCH v4 11/11] testsuites/sptests: Add sppps01 test

2022-05-20 Thread Gabriel Moyano
--- spec/build/testsuites/sptests/grp.yml | 2 + spec/build/testsuites/sptests/sppps01.yml | 19 +++ testsuites/sptests/sppps01/init.c | 191 ++ 3 files changed, 212 insertions(+) create mode 100644 spec/build/testsuites/sptests/sppps01.yml create mode 100644

[PATCH v4 07/11] kern_tc.c: Enable PPS API support

2022-05-20 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 4 1 file changed, 4 deletions(-) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 25d0837b63..80b1be364c 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -1903,7 +1903,6 @@ SYSCTL_PROC(_kern_timecounter,

[PATCH v4 10/11] timecounter.h: Add _Timecounter_Discipline()

2022-05-20 Thread Gabriel Moyano
--- cpukit/include/rtems/score/timecounter.h | 17 + cpukit/include/sys/timepps.h | 3 +++ 2 files changed, 20 insertions(+) diff --git a/cpukit/include/rtems/score/timecounter.h b/cpukit/include/rtems/score/timecounter.h index fdade06128..95e0839cff 100644 ---

[PATCH 0/1] Improve test sppps01

2022-05-25 Thread Gabriel Moyano
The test that verifies if the default wait() handler is improved by checking with and without timeout. Gabriel Moyano (1): sppps01: Improve default handler test testsuites/sptests/sppps01/init.c | 6 ++ 1 file changed, 6 insertions(+) -- 2.25.1

[PATCH 1/1] sppps01: Improve default handler test

2022-05-25 Thread Gabriel Moyano
--- testsuites/sptests/sppps01/init.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/testsuites/sptests/sppps01/init.c b/testsuites/sptests/sppps01/init.c index 850c21f1f2..996a3a1e16 100644 --- a/testsuites/sptests/sppps01/init.c +++ b/testsuites/sptests/sppps01/init.c @@ -66,6

[PATCH] kern_tc.c: Update pps_event() for uniprocessor configurations

2022-05-30 Thread Gabriel Moyano
Since pps->capgen is not used in uniprocessor configurations, there is no need to verified if it is equal to zero Update #2349 --- cpukit/score/src/kern_tc.c | 4 1 file changed, 4 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index

[PATCH 1/1] kern_tc.c: th_generation starts with 1 after overflow for single-core

2022-05-27 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 23 ++- 1 file changed, 10 insertions(+), 13 deletions(-) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 89ece1fbde..3256b646ef 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -1659,9

[PATCH 0/1] Solves th_generation overflow issue for single-core configuration

2022-05-27 Thread Gabriel Moyano
After increasing th_generation if an overflow happens its value should be 1 since 0 means that the timehand is being updated. In single-core configurations, this wasn't corrected. This patch solves this issue for RTEMS 6. Gabriel Moyano (1): kern_tc.c: th_generation starts with 1 after

[PATCH v2] sppps01: Add test case for early returns of pps_event()

2022-07-01 Thread Gabriel Moyano
--- testsuites/sptests/sppps01/init.c | 49 +-- 1 file changed, 46 insertions(+), 3 deletions(-) diff --git a/testsuites/sptests/sppps01/init.c b/testsuites/sptests/sppps01/init.c index 996a3a1e16..7779f7d9e7 100644 --- a/testsuites/sptests/sppps01/init.c +++

[PATCH] kern_tc.c: Update pps_event() for uniprocessor configurations

2022-06-10 Thread Gabriel Moyano
Since pps->capgen is not used in uniprocessor configurations, there is no need to verified if it is equal to zero Update #2349 --- cpukit/score/src/kern_tc.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index

[PATCH v2] kern_tc.c: Update pps_event() for uniprocessor configurations

2022-06-10 Thread Gabriel Moyano
Since pps->capgen equal to zero is not a special value in uniprocessor configurations, there is no need to check for this condition. Update #2349 --- cpukit/score/src/kern_tc.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c

[PATCH] sppps01: Add test case for early returns of pps_event()

2022-06-15 Thread Gabriel Moyano
--- testsuites/sptests/sppps01/init.c | 42 +++ 1 file changed, 42 insertions(+) diff --git a/testsuites/sptests/sppps01/init.c b/testsuites/sptests/sppps01/init.c index 996a3a1e16..ee3fe1645b 100644 --- a/testsuites/sptests/sppps01/init.c +++

[PATCH v3 10/11] timecounter.h: Add _Timecounter_Discipline()

2022-05-04 Thread Gabriel Moyano
--- cpukit/include/rtems/score/timecounter.h | 17 + cpukit/include/sys/timepps.h | 3 +++ 2 files changed, 20 insertions(+) diff --git a/cpukit/include/rtems/score/timecounter.h b/cpukit/include/rtems/score/timecounter.h index fdade06128..95e0839cff 100644 ---

[PATCH v3 09/11] timepps.h: PPS_SYNC defined by default

2022-05-04 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h| 1 + cpukit/score/src/kern_ntptime.c | 10 -- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index b734c6f841..56c1cc43ca 100644 --- a/cpukit/include/sys/timepps.h +++

[PATCH v3 11/11] testsuites/sptests: Add sppps01 test

2022-05-04 Thread Gabriel Moyano
--- spec/build/testsuites/sptests/grp.yml | 2 + spec/build/testsuites/sptests/sppps01.yml | 19 +++ testsuites/sptests/sppps01/init.c | 173 ++ 3 files changed, 194 insertions(+) create mode 100644 spec/build/testsuites/sptests/sppps01.yml create mode 100644

[PATCH v3 05/11] timecounter.h: Rename tc_getfrequency() to _Timecounter_Get_frequency()

2022-05-04 Thread Gabriel Moyano
--- cpukit/include/rtems/score/timecounter.h | 8 cpukit/include/sys/timetc.h | 3 +++ cpukit/score/src/kern_tc.c | 2 +- 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/cpukit/include/rtems/score/timecounter.h

[PATCH v3 07/11] kern_tc.c: Enable PPS API support

2022-05-04 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 4 1 file changed, 4 deletions(-) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 64a11bae20..0bad76c329 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -1903,7 +1903,6 @@ SYSCTL_PROC(_kern_timecounter,

[PATCH v3 08/11] kern_ntptime.c: Add define in order to remove warning

2022-05-04 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index da6b425064..c1b4013e9b 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -58,6 +58,9 @@

[PATCH v3 04/11] kern_tc.c: Replace FREEBSD event mechanism by adding pointers to function

2022-05-04 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 21 cpukit/score/src/kern_tc.c | 38 2 files changed, 59 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 5703381ffa..b734c6f841 100644 ---

[PATCH v3 06/11] kern_tc.c: Add definitions required by PPS API

2022-05-04 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 133a6ea5e0..64a11bae20 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -56,6 +56,11 @@ #definetimecounter

[PATCH v3 00/11] ENABLE PPS API in RTEMS6

2022-05-04 Thread Gabriel Moyano
This is the 3rd version of the patches for enabling the PPS API in RTEMS6. It contains the changes suggested by Sebastian from yesterday (03/05/2022). Gabriel Moyano (11): kern_ntptime.c: Disable freebsd features kern_ntptime.c: Add lmax() qmin() definitions kern_tc.c: Add atomic

[PATCH v3 02/11] kern_ntptime.c: Add lmax() qmin() definitions

2022-05-04 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index 610386833c..da6b425064 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -71,6 +71,8 @@

[PATCH v3 01/11] kern_ntptime.c: Disable freebsd features

2022-05-04 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index cb39133408..610386833c 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -73,9

[PATCH v3 03/11] kern_tc.c: Add atomic dependencies required by the PPS API

2022-05-04 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 7 +++ cpukit/score/src/kern_tc.c | 7 +++ 2 files changed, 14 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 01212f0b43..5703381ffa 100644 --- a/cpukit/include/sys/timepps.h +++

[PATCH v2 10/12] timepps.h: PPS_SYNC defined by default

2022-04-29 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h| 1 + cpukit/score/src/kern_ntptime.c | 10 -- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 0d666a4f2e..b13ac6bf26 100644 --- a/cpukit/include/sys/timepps.h +++

[PATCH v2 11/12] timepps.h: Move hardpps to the _ namespace

2022-04-29 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 1 + 1 file changed, 1 insertion(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index b13ac6bf26..25370f3f4b 100644 --- a/cpukit/include/sys/timepps.h +++ b/cpukit/include/sys/timepps.h @@ -28,6 +28,7 @@ #include #include

[PATCH v2 01/12] kern_ntptime.c: Disable freebsd features

2022-04-29 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index cb39133408..610386833c 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -73,9

[PATCH v2 00/12] Enable PPS API in RTEMS6

2022-04-29 Thread Gabriel Moyano
() as a relaxed atomic load - Remove the option for PPS_SYNC and add the #define Gabriel Moyano (12): kern_ntptime.c: Disable freebsd features kern_ntptime.c: Add lmax() qmin() definitions timepps.h: Add missing include for atomic type kern_tc.c: Add definition of atomic_load_int() required by PPS

[PATCH v2 03/12] timepps.h: Add missing include for atomic type

2022-04-29 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 01212f0b43..621afb08ec 100644 --- a/cpukit/include/sys/timepps.h +++ b/cpukit/include/sys/timepps.h @@ -24,6 +24,9 @@ #include #include

[PATCH v2 02/12] kern_ntptime.c: Add lmax() qmin() definitions

2022-04-29 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index 610386833c..da6b425064 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -71,6 +71,8 @@

[PATCH v2 04/12] kern_tc.c: Add definition of atomic_load_int() required by PPS API

2022-04-29 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 4 cpukit/score/src/kern_tc.c | 7 +++ 2 files changed, 11 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 621afb08ec..5703381ffa 100644 --- a/cpukit/include/sys/timepps.h +++

[PATCH v2 07/12] kern_tc.c: Add definitions required by PPS API

2022-04-29 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 7c2feb5be3..7e030c50d4 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -56,6 +56,11 @@ #definetimecounter

[PATCH v2 06/12] timecounter.h: Rename tc_getfrequency() to _Timecounter_Get_frequency()

2022-04-29 Thread Gabriel Moyano
--- cpukit/include/rtems/score/timecounter.h | 7 +++ cpukit/include/sys/timetc.h | 3 +++ cpukit/score/src/kern_tc.c | 2 +- 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/cpukit/include/rtems/score/timecounter.h

[PATCH v2 08/12] kern_tc.c: Enable PPS API support

2022-04-29 Thread Gabriel Moyano
--- cpukit/score/src/kern_tc.c | 4 1 file changed, 4 deletions(-) diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 7e030c50d4..1b794fd0e3 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -1903,7 +1903,6 @@ SYSCTL_PROC(_kern_timecounter,

[PATCH v2 09/12] kern_ntptime: Add define in order to remove warning

2022-04-29 Thread Gabriel Moyano
--- cpukit/score/src/kern_ntptime.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpukit/score/src/kern_ntptime.c b/cpukit/score/src/kern_ntptime.c index da6b425064..c1b4013e9b 100644 --- a/cpukit/score/src/kern_ntptime.c +++ b/cpukit/score/src/kern_ntptime.c @@ -58,6 +58,9 @@

[PATCH v2 12/12] testsuites/sptests: Add sppps01 test

2022-04-29 Thread Gabriel Moyano
--- spec/build/testsuites/sptests/grp.yml | 2 + spec/build/testsuites/sptests/sppps01.yml | 19 +++ testsuites/sptests/sppps01/init.c | 160 ++ 3 files changed, 181 insertions(+) create mode 100644 spec/build/testsuites/sptests/sppps01.yml create mode 100644

[PATCH v2 05/12] kern_tc.c: Replace FREEBSD event mechanism by adding pointers to function

2022-04-29 Thread Gabriel Moyano
--- cpukit/include/sys/timepps.h | 6 ++ cpukit/score/src/kern_tc.c | 25 + 2 files changed, 31 insertions(+) diff --git a/cpukit/include/sys/timepps.h b/cpukit/include/sys/timepps.h index 5703381ffa..0d666a4f2e 100644 --- a/cpukit/include/sys/timepps.h +++

[PATCH 08/18] ptpd: Define GLOB_ABORTED as GLOB_ABEND

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/dep/sys.c | 4 1 file changed, 4 insertions(+) diff --git a/freebsd/contrib/ptpd/src/dep/sys.c b/freebsd/contrib/ptpd/src/dep/sys.c index bf459a62..b5831701 100644 --- a/freebsd/contrib/ptpd/src/dep/sys.c +++

[PATCH 17/18] rtemsbsd: Add ptpd as a shell command

2023-04-12 Thread Gabriel Moyano
--- libbsd.py | 12 +++ rtemsbsd/include/machine/rtems-bsd-commands.h | 2 + rtemsbsd/include/rtems/ptpd.h | 20 + rtemsbsd/ptpd/ptpd.c | 78 +++ rtemsbsd/rtems/rtems-bsd-shell-ptpd.c | 66

[PATCH 07/18] ptpd: Saving rtOpst in ptpClock earlier

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/dep/startup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/freebsd/contrib/ptpd/src/dep/startup.c b/freebsd/contrib/ptpd/src/dep/startup.c index 97231d99..ace980fa 100644 --- a/freebsd/contrib/ptpd/src/dep/startup.c +++

[PATCH 04/18] ptpd: Add implementation of eventtimer based on kqueue

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/dep/datatypes_dep.h | 10 + freebsd/contrib/ptpd/src/dep/eventtimer.h | 6 +- .../contrib/ptpd/src/dep/eventtimer_kqueue.c | 184 ++ freebsd/contrib/ptpd/src/dep/kqueue.c | 80

[PATCH 00/18] Port PTPd to rtems-libbsd

2023-04-12 Thread Gabriel Moyano
in ptpClock earlier ptpd: Define GLOB_ABORTED as GLOB_ABEND ptpd: Add malloc definitions for RTEMS ptpd: Undefine FALSE and TRUE in ptp_primitives.h ptpd: Rename main function for RTEMS Gabriel Moyano (9): ptpd: Add files as contrib ptpd: Add VERSION file ptpd: XMALLOC macro defined for RTEMS

[PATCH 16/18] ptpd: Add to build system

2023-04-12 Thread Gabriel Moyano
--- buildset/default.ini | 1 + libbsd.py| 47 2 files changed, 48 insertions(+) diff --git a/buildset/default.ini b/buildset/default.ini index 88379a96..9145be9b 100644 --- a/buildset/default.ini +++ b/buildset/default.ini @@ -40,6 +40,7

[PATCH 02/18] ptpd: Add VERSION file

2023-04-12 Thread Gabriel Moyano
--- freebsd/contrib/ptpd/VERSION | 11 +++ 1 file changed, 11 insertions(+) create mode 100644 freebsd/contrib/ptpd/VERSION diff --git a/freebsd/contrib/ptpd/VERSION b/freebsd/contrib/ptpd/VERSION new file mode 100644 index ..4c95e563 --- /dev/null +++

[PATCH 18/18] testsuite: Add test ptpd01

2023-04-12 Thread Gabriel Moyano
@@ -0,0 +1,171 @@ +/** + * @file + * + * @brief It runs a PTPd instance configured as slave only. + * + * PTPd logs are printed out. + * For changing the configuration, update ptpd_conf. + */ + +/* + * Copyright (c) 2023 Gabriel Moyano, German Aerospace Center (DLR) + * + * Redistribution and use

[PATCH 09/18] ptpd: Add malloc definitions for RTEMS

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/dep/sys.c | 16 1 file changed, 16 insertions(+) diff --git a/freebsd/contrib/ptpd/src/dep/sys.c b/freebsd/contrib/ptpd/src/dep/sys.c index b5831701..6c93bf4c 100644 --- a/freebsd/contrib/ptpd/src/dep/sys.c +++

[PATCH 10/18] ptpd: Undefine FALSE and TRUE in ptp_primitives.h

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/ptp_primitives.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/freebsd/contrib/ptpd/src/ptp_primitives.h b/freebsd/contrib/ptpd/src/ptp_primitives.h index 56ded20c..d70ae06e 100644 ---

[PATCH 05/18] ptpd: Add missing cast in dictionary.c

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/dep/iniparser/dictionary.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/freebsd/contrib/ptpd/src/dep/iniparser/dictionary.c b/freebsd/contrib/ptpd/src/dep/iniparser/dictionary.c index ffe35791..772ff8ce 100644 ---

[PATCH 06/18] ptpd: Add debug prints for ipv4 in net.c

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/dep/net.c | 12 1 file changed, 12 insertions(+) diff --git a/freebsd/contrib/ptpd/src/dep/net.c b/freebsd/contrib/ptpd/src/dep/net.c index edee5dc6..a0f44098 100644 --- a/freebsd/contrib/ptpd/src/dep/net.c +++

[PATCH 03/18] ptpd: Add conditional macros for RTEMS

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/dep/constants_dep.h | 5 +++-- freebsd/contrib/ptpd/src/dep/net.c | 7 ++- freebsd/contrib/ptpd/src/dep/ptpd_dep.h | 8 freebsd/contrib/ptpd/src/dep/startup.c | 2 ++ freebsd/contrib/ptpd/src/dep/sys.c |

[PATCH 12/18] ptpd: XMALLOC macro defined for RTEMS

2023-04-12 Thread Gabriel Moyano
--- freebsd/contrib/ptpd/src/ptpd.h | 9 + 1 file changed, 9 insertions(+) diff --git a/freebsd/contrib/ptpd/src/ptpd.h b/freebsd/contrib/ptpd/src/ptpd.h index 08090317..387d6525 100644 --- a/freebsd/contrib/ptpd/src/ptpd.h +++ b/freebsd/contrib/ptpd/src/ptpd.h @@ -183,12 +183,21 @@

[PATCH 13/18] ptpd: Add missing includes for RTEMS

2023-04-12 Thread Gabriel Moyano
--- freebsd/contrib/ptpd/src/constants.h | 4 freebsd/contrib/ptpd/src/dep/datatypes_dep.h | 7 +++ freebsd/contrib/ptpd/src/dep/sys.c | 4 freebsd/contrib/ptpd/src/ptpd.h | 6 ++ freebsd/contrib/ptpd/src/timingdomain.c | 4 5 files

[PATCH 14/18] ptpd: Includes needed to compile statistics dependencies for RTEMS

2023-04-12 Thread Gabriel Moyano
--- freebsd/contrib/ptpd/src/ptpd.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/freebsd/contrib/ptpd/src/ptpd.h b/freebsd/contrib/ptpd/src/ptpd.h index d8bb4b1e..e0e2b1ac 100644 --- a/freebsd/contrib/ptpd/src/ptpd.h +++ b/freebsd/contrib/ptpd/src/ptpd.h @@ -169,13

[PATCH 11/18] ptpd: Rename main function for RTEMS

2023-04-12 Thread Gabriel Moyano
From: Chris Johns --- freebsd/contrib/ptpd/src/ptpd.c | 4 1 file changed, 4 insertions(+) diff --git a/freebsd/contrib/ptpd/src/ptpd.c b/freebsd/contrib/ptpd/src/ptpd.c index 3462dd21..f1026f3b 100644 --- a/freebsd/contrib/ptpd/src/ptpd.c +++ b/freebsd/contrib/ptpd/src/ptpd.c @@ -75,7

[PATCH v2 12/18] ptpd: XMALLOC macro defined for RTEMS

2023-04-17 Thread Gabriel Moyano
--- rtemsbsd/ptpd/src/ptpd.h | 9 + 1 file changed, 9 insertions(+) diff --git a/rtemsbsd/ptpd/src/ptpd.h b/rtemsbsd/ptpd/src/ptpd.h index 08090317..387d6525 100644 --- a/rtemsbsd/ptpd/src/ptpd.h +++ b/rtemsbsd/ptpd/src/ptpd.h @@ -183,12 +183,21 @@ /* NOTE: this macro can be

[PATCH v2 07/18] ptpd: Saving rtOpst in ptpClock earlier

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/dep/startup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rtemsbsd/ptpd/src/dep/startup.c b/rtemsbsd/ptpd/src/dep/startup.c index 97231d99..ace980fa 100644 --- a/rtemsbsd/ptpd/src/dep/startup.c +++

[PATCH v2 18/18] testsuite: Add test ptpd01

2023-04-17 Thread Gabriel Moyano
@@ -0,0 +1,171 @@ +/** + * @file + * + * @brief It runs a PTPd instance configured as slave only. + * + * PTPd logs are printed out. + * For changing the configuration, update ptpd_conf. + */ + +/* + * Copyright (c) 2023 Gabriel Moyano, German Aerospace Center (DLR) + * + * Redistribution and use

[PATCH v2 14/18] ptpd: Includes needed to compile statistics dependencies for RTEMS

2023-04-17 Thread Gabriel Moyano
--- rtemsbsd/ptpd/src/ptpd.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rtemsbsd/ptpd/src/ptpd.h b/rtemsbsd/ptpd/src/ptpd.h index d8bb4b1e..e0e2b1ac 100644 --- a/rtemsbsd/ptpd/src/ptpd.h +++ b/rtemsbsd/ptpd/src/ptpd.h @@ -169,13 +169,13 @@ #include "timingdomain.h"

[PATCH v2 03/18] ptpd: Add conditional macros for RTEMS

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/dep/constants_dep.h | 5 +++-- rtemsbsd/ptpd/src/dep/net.c | 7 ++- rtemsbsd/ptpd/src/dep/ptpd_dep.h | 8 rtemsbsd/ptpd/src/dep/startup.c | 2 ++ rtemsbsd/ptpd/src/dep/sys.c | 7 ++- 5 files changed, 25

[PATCH v2 16/18] ptpd: Add to build system

2023-04-17 Thread Gabriel Moyano
--- buildset/default.ini | 1 + libbsd.py| 49 +++- 2 files changed, 49 insertions(+), 1 deletion(-) diff --git a/buildset/default.ini b/buildset/default.ini index 88379a96..9145be9b 100644 --- a/buildset/default.ini +++ b/buildset/default.ini

[PATCH v2 08/18] ptpd: Define GLOB_ABORTED as GLOB_ABEND

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/dep/sys.c | 4 1 file changed, 4 insertions(+) diff --git a/rtemsbsd/ptpd/src/dep/sys.c b/rtemsbsd/ptpd/src/dep/sys.c index bf459a62..b5831701 100644 --- a/rtemsbsd/ptpd/src/dep/sys.c +++ b/rtemsbsd/ptpd/src/dep/sys.c @@ -69,6 +69,10 @@ # include

[PATCH v2 10/18] ptpd: Undefine FALSE and TRUE in ptp_primitives.h

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/ptp_primitives.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rtemsbsd/ptpd/src/ptp_primitives.h b/rtemsbsd/ptpd/src/ptp_primitives.h index 56ded20c..d70ae06e 100644 --- a/rtemsbsd/ptpd/src/ptp_primitives.h +++

[PATCH v2 00/18] Port PTPd to rtems-libbsd

2023-04-17 Thread Gabriel Moyano
earlier ptpd: Define GLOB_ABORTED as GLOB_ABEND ptpd: Add malloc definitions for RTEMS ptpd: Undefine FALSE and TRUE in ptp_primitives.h ptpd: Rename main function for RTEMS Gabriel Moyano (9): ptpd: Add files in rtemsbsd ptpd: Add VERSION file ptpd: XMALLOC macro defined for RTEMS

[PATCH v2 06/18] ptpd: Add debug prints for ipv4 in net.c

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/dep/net.c | 12 1 file changed, 12 insertions(+) diff --git a/rtemsbsd/ptpd/src/dep/net.c b/rtemsbsd/ptpd/src/dep/net.c index edee5dc6..a0f44098 100644 --- a/rtemsbsd/ptpd/src/dep/net.c +++ b/rtemsbsd/ptpd/src/dep/net.c @@ -102,6 +102,12 @@

[PATCH v2 04/18] ptpd: Add implementation of eventtimer based on kqueue

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/dep/datatypes_dep.h | 10 ++ rtemsbsd/ptpd/src/dep/eventtimer.h| 6 +- rtemsbsd/ptpd/src/dep/eventtimer_kqueue.c | 184 ++ rtemsbsd/ptpd/src/dep/kqueue.c| 80 ++ rtemsbsd/ptpd/src/dep/net.c

[PATCH v2 05/18] ptpd: Add missing cast in dictionary.c

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/dep/iniparser/dictionary.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rtemsbsd/ptpd/src/dep/iniparser/dictionary.c b/rtemsbsd/ptpd/src/dep/iniparser/dictionary.c index ffe35791..772ff8ce 100644 ---

[PATCH v2 13/18] ptpd: Add missing includes for RTEMS

2023-04-17 Thread Gabriel Moyano
--- rtemsbsd/ptpd/src/constants.h | 4 rtemsbsd/ptpd/src/dep/datatypes_dep.h | 7 +++ rtemsbsd/ptpd/src/dep/sys.c | 4 rtemsbsd/ptpd/src/ptpd.h | 6 ++ rtemsbsd/ptpd/src/timingdomain.c | 4 5 files changed, 25 insertions(+) diff --git

[PATCH v2 15/18] ptpd: Add config file

2023-04-17 Thread Gabriel Moyano
--- rtemsbsd/include/ptpd/config.h | 248 + 1 file changed, 248 insertions(+) create mode 100644 rtemsbsd/include/ptpd/config.h diff --git a/rtemsbsd/include/ptpd/config.h b/rtemsbsd/include/ptpd/config.h new file mode 100644 index ..a050a3f9 ---

[PATCH v2 17/18] rtemsbsd: Add ptpd as a shell command

2023-04-17 Thread Gabriel Moyano
--- libbsd.py | 2 + rtemsbsd/include/machine/rtems-bsd-commands.h | 2 + rtemsbsd/include/rtems/ptpd.h | 20 + rtemsbsd/ptpd/rtems/ptpd.c| 78 +++ rtemsbsd/rtems/rtems-bsd-shell-ptpd.c | 66

[PATCH v2 09/18] ptpd: Add malloc definitions for RTEMS

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/dep/sys.c | 16 1 file changed, 16 insertions(+) diff --git a/rtemsbsd/ptpd/src/dep/sys.c b/rtemsbsd/ptpd/src/dep/sys.c index b5831701..6c93bf4c 100644 --- a/rtemsbsd/ptpd/src/dep/sys.c +++ b/rtemsbsd/ptpd/src/dep/sys.c @@ -2668,3

[PATCH v2 11/18] ptpd: Rename main function for RTEMS

2023-04-17 Thread Gabriel Moyano
From: Chris Johns --- rtemsbsd/ptpd/src/ptpd.c | 4 1 file changed, 4 insertions(+) diff --git a/rtemsbsd/ptpd/src/ptpd.c b/rtemsbsd/ptpd/src/ptpd.c index 3462dd21..f1026f3b 100644 --- a/rtemsbsd/ptpd/src/ptpd.c +++ b/rtemsbsd/ptpd/src/ptpd.c @@ -75,7 +75,11 @@ PtpClock *G_ptpClock =

[PATCH v2 02/18] ptpd: Add VERSION file

2023-04-17 Thread Gabriel Moyano
--- rtemsbsd/ptpd/rtems/VERSION | 11 +++ 1 file changed, 11 insertions(+) create mode 100644 rtemsbsd/ptpd/rtems/VERSION diff --git a/rtemsbsd/ptpd/rtems/VERSION b/rtemsbsd/ptpd/rtems/VERSION new file mode 100644 index ..4c95e563 --- /dev/null +++ b/rtemsbsd/ptpd/rtems/VERSION