[riot-commits] [RIOT-OS/RIOT] c5c83c: cpu/msp430_common: Update to inline-able IRQ API

Francisco noreply at github.com
Wed Jul 15 15:34:21 CEST 2020


  Branch: refs/heads/master
  Home:   https://github.com/RIOT-OS/RIOT
  Commit: c5c83cfe3cc25eae0c3cdc342bcb0f564e1929d1
      https://github.com/RIOT-OS/RIOT/commit/c5c83cfe3cc25eae0c3cdc342bcb0f564e1929d1
  Author: Marian Buschsieweke <marian.buschsieweke at ovgu.de>
  Date:   2020-06-25 (Thu, 25 Jun 2020)

  Changed paths:
    M cpu/msp430_common/include/cpu_conf.h
    A cpu/msp430_common/include/irq_arch.h
    M cpu/msp430_common/irq.c

  Log Message:
  -----------
  cpu/msp430_common: Update to inline-able IRQ API

- Updated to inline-able IRQ API
- Improved robustness of functions
    - Added memory barrier to prevent the compiler from moving code outside of
      a critical section guarded by irq_disable() ... irq_restore()
- Reduced overhead of `irq_disable()`
    - After clearing the global interrupt enable (GIE) bit, IRQs remain enabled
      for up to one CPU cycle
    - The previous implementation just added a nop to fill that cycle
    - This implementation uses the cycle for masking the return value
- Reduced overhead of `irq_restore()`
    - Now only one CPU cycle is needed
- `irq_disable()`, `irq_restore()`, and `irq_enable()` work now in constant time


  Commit: 1a8defd2095d33c818aefbfdfc8bcb70ff398823
      https://github.com/RIOT-OS/RIOT/commit/1a8defd2095d33c818aefbfdfc8bcb70ff398823
  Author: Marian Buschsieweke <marian.buschsieweke at ovgu.de>
  Date:   2020-07-15 (Wed, 15 Jul 2020)

  Changed paths:
    M cpu/msp430_common/cpu.c
    M cpu/msp430_common/include/cpu.h

  Log Message:
  -----------
  cpu/msp430_common: Refactor cpu.{c,h}

Drop `__enable_irq()` and `__disable_irq()` and replace single remaining
call of them with the standard IRQ API, as this is now equally fast.


  Commit: 1167867d02fff8643262022f7a6328b2cf46d519
      https://github.com/RIOT-OS/RIOT/commit/1167867d02fff8643262022f7a6328b2cf46d519
  Author: Francisco <femolina at uc.cl>
  Date:   2020-07-15 (Wed, 15 Jul 2020)

  Changed paths:
    M cpu/msp430_common/cpu.c
    M cpu/msp430_common/include/cpu.h
    M cpu/msp430_common/include/cpu_conf.h
    A cpu/msp430_common/include/irq_arch.h
    M cpu/msp430_common/irq.c

  Log Message:
  -----------
  Merge pull request #14362 from maribu/msp430-irq-inline

cpu/msp430_common: Update to inline-able IRQ API


Compare: https://github.com/RIOT-OS/RIOT/compare/90911f4bf99a...1167867d02ff


More information about the commits mailing list