Re: libbsd kernel namespace generation

2021-07-23 Thread Chris Johns
On 23/7/21 5:00 pm, Sebastian Huber wrote: > Hello Chris, > > On 22/07/2021 10:44, Chris Johns wrote: >> Hello, >> >> Libbsd uses the pre-processor to map all the kernel calls into a libbsd >> kernel >> name space by prepending _bsd_ to each symbol. The script ... >> >>

[PATCH] build: Merge default-by-family into by-variant

2021-07-23 Thread Sebastian Huber
Prefix the BSP family name with "bsps/" to make it distinct to the BSP variant names. --- spec/build/bsps/optconsolebaud.yml | 5 + wscript| 10 ++ 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/spec/build/bsps/optconsolebaud.yml

Re: libbsd kernel namespace generation

2021-07-23 Thread Sebastian Huber
Hello Chris, On 22/07/2021 10:44, Chris Johns wrote: Hello, Libbsd uses the pre-processor to map all the kernel calls into a libbsd kernel name space by prepending _bsd_ to each symbol. The script ... https://git.rtems.org/rtems-libbsd/tree/create-kernel-namespace.sh?h=6-freebsd-12 ...

Re: [PATCH] closes #3889

2021-07-23 Thread Gedare Bloom
Hi Zak, Please provide a useful first commit line. I think I've mentioned this before, but the current guidance is found at https://devel.rtems.org/wiki/Developer/Git#GitCommits Put the ticket closing line within the commit message, usually on its own line at the end of your commit message On

[PATCH v3 35/42] validation: Test rtems_interrupt_entry_install()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml|1 + testsuites/validation/tc-intr-entry-install.c | 1364 + 2 files changed, 1365 insertions(+) create mode 100644 testsuites/validation/tc-intr-entry-install.c diff --git

[PATCH v3 31/42] validation: Test rtems_interrupt_get_attributes()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + .../validation/tc-intr-get-attributes.c | 440 ++ 2 files changed, 441 insertions(+) create mode 100644 testsuites/validation/tc-intr-get-attributes.c diff --git

[PATCH v3 40/42] validation: Test rtems_interrupt_raise_on()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + testsuites/validation/tc-intr-raise-on.c | 709 ++ testsuites/validation/ts-default.h| 12 +- testsuites/validation/ts-validation-0.c | 2 +- 4 files changed, 722 insertions(+), 2

[PATCH v3 19/42] bsps/irq: Implement new directives for GICv2/3

2021-07-23 Thread Sebastian Huber
Update #3269. --- bsps/aarch64/a53/include/bsp/irq.h | 2 +- bsps/include/dev/irq/arm-gic-irq.h | 3 + bsps/shared/dev/irq/arm-gicv2.c| 87 +++ bsps/shared/dev/irq/arm-gicv3.c| 129 + 4 files changed, 189 insertions(+), 32 deletions(-)

[PATCH v3 15/42] bsps/irq: bsp_interrupt_vector_enable()

2021-07-23 Thread Sebastian Huber
Return a status code for bsp_interrupt_vector_enable(). Update #3269. --- bsps/arm/beagle/irq/irq.c | 3 ++- bsps/arm/csb336/irq/irq.c | 4 +++- bsps/arm/csb337/irq/irq.c | 3 ++- bsps/arm/edb7312/irq/irq.c| 4 +++-

[PATCH v3 37/42] validation: Test rtems_interrupt_raise()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + testsuites/validation/tc-intr-raise.c | 576 ++ 2 files changed, 577 insertions(+) create mode 100644 testsuites/validation/tc-intr-raise.c diff --git

[PATCH v3 13/42] bsps/irq: Add rtems_interrupt_get_attributes()

2021-07-23 Thread Sebastian Huber
Add a default implementation which clears the attributes to zero and just returns RTEMS_SUCCESSFUL for valid parameters. Update #3269. --- bsps/arm/beagle/irq/irq.c | 8 ++ bsps/arm/csb336/irq/irq.c | 8 ++ bsps/arm/csb337/irq/irq.c | 8

[PATCH v3 39/42] validation: Test rtems_interrupt_is_pending()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + testsuites/validation/tc-intr-is-pending.c| 629 ++ 2 files changed, 630 insertions(+) create mode 100644 testsuites/validation/tc-intr-is-pending.c diff --git

[PATCH v3 32/42] validation: rtems_interrupt_vector_is_enabled()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + .../validation/tc-intr-vector-is-enabled.c| 627 ++ 2 files changed, 628 insertions(+) create mode 100644 testsuites/validation/tc-intr-vector-is-enabled.c diff --git

[PATCH v3 24/42] bsps/irq: Move bsp_interrupt_handler_is_empty()

2021-07-23 Thread Sebastian Huber
This function is only used by one BSP. Update #3269. --- bsps/i386/shared/irq/irq.c | 11 +++ bsps/include/bsp/irq-generic.h | 11 --- bsps/shared/irq/irq-generic.c | 19 --- 3 files changed, 11 insertions(+), 30 deletions(-) diff --git

[PATCH v3 34/42] validation: Test rtems_interrupt_vector_disable()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + .../validation/tc-intr-vector-disable.c | 632 ++ 2 files changed, 633 insertions(+) create mode 100644 testsuites/validation/tc-intr-vector-disable.c diff --git

Re: libbsd kernel namespace generation

2021-07-23 Thread Joel Sherrill
On Fri, Jul 23, 2021, 2:00 AM Sebastian Huber < sebastian.hu...@embedded-brains.de> wrote: > Hello Chris, > > On 22/07/2021 10:44, Chris Johns wrote: > > Hello, > > > > Libbsd uses the pre-processor to map all the kernel calls into a libbsd > kernel > > name space by prepending _bsd_ to each

Re: [PATCH] build: Merge default-by-family into by-variant

2021-07-23 Thread Gedare Bloom
ok. we need default-by-family documentation in rtems-docs/eng On Fri, Jul 23, 2021 at 12:49 AM Sebastian Huber wrote: > > Prefix the BSP family name with "bsps/" to make it distinct to the BSP > variant names. > --- > spec/build/bsps/optconsolebaud.yml | 5 + > wscript

[PATCH v3 06/42] rtems: Add rtems_interrupt_get_attributes()

2021-07-23 Thread Sebastian Huber
Add a directive to query the attributes of an interrupt vector. This can be used for generic tests and system diagnostics. Update #3269. --- cpukit/include/rtems/irq-extension.h | 207 +++ 1 file changed, 207 insertions(+) diff --git

[PATCH v3 00/42] Document, enhance, and test Interrupt Manager Extension

2021-07-23 Thread Sebastian Huber
This patch set enhances the Interrupt Manager Extension so that it can be tested with generic tests. The following new directives are introduced for this purpose: * rtems_interrupt_get_attributes() * rtems_interrupt_vector_is_enabled() * rtems_interrupt_vector_enable() *

[PATCH v3 08/42] rtems: Add rtems_interrupt_vector_is_enabled()

2021-07-23 Thread Sebastian Huber
Update #3269. --- cpukit/include/rtems/irq-extension.h | 50 1 file changed, 50 insertions(+) diff --git a/cpukit/include/rtems/irq-extension.h b/cpukit/include/rtems/irq-extension.h index e0d63c9dcb..f538297b3c 100644 --- a/cpukit/include/rtems/irq-extension.h +++

[PATCH v3 04/42] rtems: Add rtems_interrupt_raise()

2021-07-23 Thread Sebastian Huber
Add rtems_interrupt_raise_on(). Document the currently not implemented rtems_interrupt_clear(). Remove the not implemented and badly named rtems_interrupt_cause() directive. Update #3269. --- cpukit/include/rtems/rtems/intr.h | 162 +++--- 1 file changed, 125

[PATCH v3 03/42] bsps/irq: Move handler iterate to separate file

2021-07-23 Thread Sebastian Huber
Update #3269. --- bsps/include/bsp/irq-generic.h | 57 bsps/shared/irq-default-sources.am | 1 + bsps/shared/irq-sources.am | 1 + bsps/shared/irq/irq-generic.c| 86 +- bsps/shared/irq/irq-handler-iterate.c

[PATCH v3 17/42] bsps/irq: bsp_interrupt_get_affinity()

2021-07-23 Thread Sebastian Huber
Return a status code for bsp_interrupt_get_affinity(). Update #3269. --- bsps/include/dev/irq/arm-gic-irq.h | 2 +- bsps/powerpc/qoriq/include/bsp/irq.h | 2 +- bsps/powerpc/qoriq/irq/irq.c | 5 +++-- bsps/powerpc/t32mppc/include/bsp/irq.h | 3 ++-

[PATCH v3 27/42] validation: Add CallWithinISR()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/libvalidation.yml | 1 + testsuites/validation/tx-call-within-isr.c| 134 ++ testsuites/validation/tx-support.h| 14 ++ 3 files changed, 149 insertions(+) create mode 100644

[PATCH v3 16/42] bsps/irq: bsp_interrupt_vector_disable()

2021-07-23 Thread Sebastian Huber
Return a status code for bsp_interrupt_vector_disable(). Update #3269. --- bsps/arm/beagle/irq/irq.c | 3 ++- bsps/arm/csb336/irq/irq.c | 4 +++- bsps/arm/csb337/irq/irq.c | 3 ++- bsps/arm/edb7312/irq/irq.c| 4 +++-

[PATCH v3 02/42] bsps/irq: Canonicalize get/set affinity errors

2021-07-23 Thread Sebastian Huber
Bring the error conditions and status in line with rtems_task_get_affinity() and rtems_task_set_affinity(). Update #3269. --- bsps/shared/irq/irq-affinity.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/bsps/shared/irq/irq-affinity.c

[PATCH v3 01/42] bsps/irq: Move get/set affinity to separate file

2021-07-23 Thread Sebastian Huber
Update #3269. --- bsps/shared/irq-default-sources.am | 1 + bsps/shared/irq-sources.am | 1 + bsps/shared/irq/irq-affinity.c | 90 bsps/shared/irq/irq-generic.c| 52 ---

Re: [PATCH v3 19/42] bsps/irq: Implement new directives for GICv2/3

2021-07-23 Thread Gedare Bloom
On Fri, Jul 23, 2021 at 7:58 AM Sebastian Huber wrote: > > Update #3269. > --- > bsps/aarch64/a53/include/bsp/irq.h | 2 +- > bsps/include/dev/irq/arm-gic-irq.h | 3 + > bsps/shared/dev/irq/arm-gicv2.c| 87 +++ > bsps/shared/dev/irq/arm-gicv3.c| 129

Re: [PATCH v3 20/42] sparc/irq: Implement new interrupt directives

2021-07-23 Thread Gedare Bloom
On Fri, Jul 23, 2021 at 7:58 AM Sebastian Huber wrote: > > Update #3269. > --- > bsps/sparc/erc32/include/bsp/irq.h | 3 +- > bsps/sparc/erc32/include/erc32.h | 12 - > bsps/sparc/leon2/include/bsp/irq.h | 3 +- > bsps/sparc/leon2/include/leon.h| 16 +- >

[PATCH v3 36/42] validation: Test rtems_interrupt_entry_remove()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml|1 + testsuites/validation/tc-intr-entry-remove.c | 1432 + 2 files changed, 1433 insertions(+) create mode 100644 testsuites/validation/tc-intr-entry-remove.c diff --git

[PATCH v3 11/42] bsps/irq: Add rtems_interrupt_vector_is_enabled()

2021-07-23 Thread Sebastian Huber
Add a default implementation which just returns RTEMS_UNSATISFIED for valid parameters. Update #3269. --- bsps/arm/beagle/irq/irq.c | 11 +++ bsps/arm/csb336/irq/irq.c | 11 +++ bsps/arm/csb337/irq/irq.c | 11 +++

[PATCH v3 25/42] bsps/irq: Add rtems_interrupt_entry_install()

2021-07-23 Thread Sebastian Huber
Add rtems_interrupt_entry_remove(). Split up irq-generic.c into several files. In particular, place all functions which use dynamic memory into their own file. Add optional macros to let the BSP customize the vector installation after installing the first entry and the vector removal before

[PATCH v3 21/42] rtems: Add rtems_interrupt_entry_install()

2021-07-23 Thread Sebastian Huber
Add RTEMS_INTERRUPT_ENTRY_INITIALIZER(), rtems_interrupt_entry_initialize(), and rtems_interrupt_entry_remove(). This allows to install interrupt handlers using user-provided storage as an alternative to rtems_interrupt_handler_install() which has to allocate memory. Update #3269. ---

[PATCH v3 05/42] rtems: Generate

2021-07-23 Thread Sebastian Huber
Use which just provides the data types and avoid a dependency on which contains the full chain implementation. Change license to BSD-2-Clause according to file histories and documentation re-licensing agreement. Update #3269. Update #3899. Update #3993. ---

[PATCH v3 22/42] bsps/irq: Use rtems_interrupt_entry

2021-07-23 Thread Sebastian Huber
Update #3269. --- bsps/include/bsp/irq-generic.h| 15 +++ bsps/shared/irq/irq-generic.c | 24 bsps/shared/irq/irq-handler-iterate.c | 2 +- 3 files changed, 16 insertions(+), 25 deletions(-) diff --git a/bsps/include/bsp/irq-generic.h

[PATCH v3 28/42] validation: HasInterruptVectorEntriesInstalled()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/libvalidation.yml | 1 + testsuites/validation/tx-interrupt.c | 79 +++ testsuites/validation/tx-support.h| 2 + 3 files changed, 82 insertions(+) create mode 100644 testsuites/validation/tx-interrupt.c diff

[PATCH v3 29/42] validation: GetValidInterruptVectorNumber()

2021-07-23 Thread Sebastian Huber
Update #3269. --- testsuites/validation/tx-interrupt.c | 26 ++ testsuites/validation/tx-support.h | 5 + 2 files changed, 31 insertions(+) diff --git a/testsuites/validation/tx-interrupt.c b/testsuites/validation/tx-interrupt.c index d056af5abc..0ff5ec017f 100644

[PATCH v3 12/42] bsps/irq: Add rtems_interrupt_raise()

2021-07-23 Thread Sebastian Huber
Add rtems_interrupt_raise_on() and rtems_interrupt_clear(). Add a default implementation which just returns RTEMS_UNSATISFIED for valid parameters. Update #3269. --- bsps/arm/beagle/irq/irq.c| 12 +++ bsps/arm/csb336/irq/irq.c| 12 +++

[PATCH v3 14/42] bsps/irq: Add rtems_interrupt_is_pending()

2021-07-23 Thread Sebastian Huber
Add a default implementation which just returns RTEMS_UNSATISFIED. Update #3269. --- bsps/arm/beagle/irq/irq.c | 11 ++ bsps/arm/csb336/irq/irq.c | 11 ++ bsps/arm/csb337/irq/irq.c | 11 ++ bsps/arm/edb7312/irq/irq.c

[PATCH v3 42/42] validation: Test rtems_interrupt_set_affinity()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + testsuites/validation/tc-intr-set-affinity.c | 670 ++ 2 files changed, 671 insertions(+) create mode 100644 testsuites/validation/tc-intr-set-affinity.c diff --git

[PATCH v3 38/42] validation: Test rtems_interrupt_clear()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + testsuites/validation/tc-intr-clear.c | 586 ++ 2 files changed, 587 insertions(+) create mode 100644 testsuites/validation/tc-intr-clear.c diff --git

[PATCH v3 18/42] bsps/irq: bsp_interrupt_set_affinity()

2021-07-23 Thread Sebastian Huber
Return a status code for bsp_interrupt_set_affinity(). Update #3269. --- bsps/include/dev/irq/arm-gic-irq.h | 2 +- bsps/powerpc/qoriq/include/bsp/irq.h | 2 +- bsps/powerpc/qoriq/irq/irq.c | 5 +++-- bsps/powerpc/t32mppc/include/bsp/irq.h | 3 ++-

[PATCH v3 09/42] rtems: Add rtems_interrupt_is_pending()

2021-07-23 Thread Sebastian Huber
Update #3269. --- cpukit/include/rtems/irq-extension.h | 54 1 file changed, 54 insertions(+) diff --git a/cpukit/include/rtems/irq-extension.h b/cpukit/include/rtems/irq-extension.h index f538297b3c..0a26ef959c 100644 --- a/cpukit/include/rtems/irq-extension.h +++

[PATCH v3 07/42] rtems: Add rtems_interrupt_vector_enable()

2021-07-23 Thread Sebastian Huber
Add rtems_interrupt_vector_disable(). Update #3269. --- bsps/shared/irq-default-sources.am | 1 + bsps/shared/irq-sources.am | 1 + bsps/shared/irq/irq-enable-disable.c | 59 + c/src/lib/libbsp/m68k/genmcf548x/Makefile.am | 1 +

[PATCH v3 41/42] validation: Test rtems_interrupt_get_affinity()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + testsuites/validation/tc-intr-get-affinity.c | 639 ++ 2 files changed, 640 insertions(+) create mode 100644 testsuites/validation/tc-intr-get-affinity.c diff --git

[PATCH v3 23/42] bsps/irq: Add bsp_interrupt_check_and_lock()

2021-07-23 Thread Sebastian Huber
Return RTEMS_INCORRECT_STATE instead of RTEMS_INTERNAL_ERROR in case the interrupt support is not initialized. This is similar to rtems_timer_server_fire_after() for example. Update #3269. --- bsps/include/bsp/irq-generic.h| 38 - bsps/shared/irq/irq-generic.c |

[PATCH v3 20/42] sparc/irq: Implement new interrupt directives

2021-07-23 Thread Sebastian Huber
Update #3269. --- bsps/sparc/erc32/include/bsp/irq.h | 3 +- bsps/sparc/erc32/include/erc32.h | 12 - bsps/sparc/leon2/include/bsp/irq.h | 3 +- bsps/sparc/leon2/include/leon.h| 16 +- bsps/sparc/leon3/start/eirq.c | 87 +++---

[PATCH v3 33/42] validation: Test rtems_interrupt_vector_enable()

2021-07-23 Thread Sebastian Huber
Update #3269. --- .../testsuites/validation/validation-0.yml| 1 + testsuites/validation/tc-intr-vector-enable.c | 638 ++ 2 files changed, 639 insertions(+) create mode 100644 testsuites/validation/tc-intr-vector-enable.c diff --git

[PATCH v3 30/42] validation: GetTestableInterruptVector()

2021-07-23 Thread Sebastian Huber
Update #3269. --- testsuites/validation/tx-interrupt.c | 47 testsuites/validation/tx-support.h | 2 ++ 2 files changed, 49 insertions(+) diff --git a/testsuites/validation/tx-interrupt.c b/testsuites/validation/tx-interrupt.c index 0ff5ec017f..e75c7a2aa0 100644

[PATCH v3 10/42] rtems: Add RTEMS_FATAL_SOURCE_SPURIOUS_INTERRUPT

2021-07-23 Thread Sebastian Huber
Add RTEMS_FATAL_SOURCE_SPURIOUS_INTERRUPT as the fatal source for spurious interrupts. Use the interrupt vector number of the spurious interrupt for the fatal code. Update #3269. --- bsps/shared/irq/irq-default-handler.c | 12 +--- cpukit/include/rtems/score/interr.h | 7

[PATCH v3 26/42] bsp/raspberrypi: Add interrupt get/set affinity

2021-07-23 Thread Sebastian Huber
Add default implementations for bsp_interrupt_get_affinity() and bsp_interrupt_set_affinity() which are required to link all tests in SMP configurations. Update #3269. --- bsps/arm/raspberrypi/include/bsp/irq.h | 26 ++ 1 file changed, 26 insertions(+) diff --git

Re: [PATCH v3 19/42] bsps/irq: Implement new directives for GICv2/3

2021-07-23 Thread Sebastian Huber
On 23/07/2021 17:03, Gedare Bloom wrote: @@ -195,15 +246,35 @@ rtems_status_code bsp_interrupt_raise_on( uint32_tcpu_index ) { - bsp_interrupt_assert(bsp_interrupt_is_valid_vector(vector)); - return RTEMS_UNSATISFIED; + if (vector >= 16) { Use (vector >

Re: [PATCH v3 00/42] Document, enhance, and test Interrupt Manager Extension

2021-07-23 Thread Gedare Bloom
I checked the attributes, raise, and sparc/arm implementations. My minor points can be done while pushing, I'm good with the patch set. On Fri, Jul 23, 2021 at 7:57 AM Sebastian Huber wrote: > > This patch set enhances the Interrupt Manager Extension so that it can be > tested with generic

Re: [PATCH] closes #3889

2021-07-23 Thread Joel Sherrill
I concur with Gedare's comments. I would think your commit message would be similar to the subject of the ticket. This looks like a decent example: https://git.rtems.org/rtems/commit/?id=6c23252cdd8ea63d0fe13d9f99b7befbf070fe80 Please update and submit. Pay attention to compiler warnings. On