Interrupt Processor Affinity API Changes

Gedare Bloom gedare at rtems.org
Thu Nov 21 14:49:43 UTC 2013


Be sure to address the default set (probably the bootstrap processor only).

On Thu, Nov 21, 2013 at 6:09 AM, Sebastian Huber
<sebastian.huber at embedded-brains.de> wrote:
> Hello,
>
> this is a proposal for an update of the Interrupt Manager Extension
>
> http://www.rtems.org/onlinedocs/doxygen/cpukit/html/group__rtems__interrupt__extension.html
>
> to allow set/get of processor affinities for interrupt vectors.
>
> ==== RTEMS API Changes ====
>
> Each interrupt needs a processor affinity set in the RTEMS SMP
> configuration. The rtems_interrupt_handler_install() function will not alter
> the processor
> affinity set of the interrupt vector.
>
> Two new functions should be added to alter and retrieve the processor
> affinity
> sets of interrupt vectors.
>
>  /**
>   * @brief Sets the processor affinity set of an interrupt vector.
>   *
>   * @param[in] vector The interrupt vector number.
>   * @param[in] affinity_set_size Size of the specified affinity set buffer
> in
>   * bytes.  This value must be positive.
>   * @param[in] affinity_set The new processor affinity set for the interrupt
>   * vector.  This pointer must not be @c NULL.  A set bit in the affinity
> set
>   * means that the interrupt vector can occur on this processor and a
> cleared
>   * bit means the opposite.
>   *
>   * @retval RTEMS_SUCCESSFUL Successful operation.
>   * @retval RTEMS_INVALID_ID The vector number is invalid.
>   * @retval RTEMS_INVALID_CPU_SET Invalid processor affinity set.
>   */
>  rtems_status_code rtems_interrupt_set_affinity(
>    rtems_vector vector,
>    size_t affinity_set_size,
>    const cpu_set_t *affinity_set
>  );
>
>  /**
>   * @brief Gets the processor affinity set of an interrupt vector.
>   *
>   * @param[in] vector The interrupt vector number.
>   * @param[in] affinity_set_size Size of the specified affinity set buffer
> in
>   * bytes.  This value must be positive.
>   * @param[out] affinity_set The current processor affinity set of the
>   * interrupt vector.  This pointer must not be @c NULL.  A set bit in the
>   * affinity set means that the interrupt vector can occur on this processor
>   * and a cleared bit means the opposite.
>   *
>   * @retval RTEMS_SUCCESSFUL Successful operation.
>   * @retval RTEMS_INVALID_ID The vector number is invalid.
>   * @retval RTEMS_INVALID_CPU_SET The affinity set buffer is too small for
> the
>   * current processor affinity set of the interrupt vector.
>   */
>  rtems_status_code rtems_interrupt_get_affinity(
>    rtems_vector vector,
>    size_t affinity_set_size,
>    cpu_set_t *affinity_set
>  );
>
> --
> Sebastian Huber, embedded brains GmbH
>
> Address : Dornierstr. 4, D-82178 Puchheim, Germany
> Phone   : +49 89 189 47 41-16
> Fax     : +49 89 189 47 41-09
> E-Mail  : sebastian.huber at embedded-brains.de
> PGP     : Public key available on request.
>
> Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
> _______________________________________________
> rtems-devel mailing list
> rtems-devel at rtems.org
> http://www.rtems.org/mailman/listinfo/rtems-devel




More information about the devel mailing list