WO2012019627A1 - Device and method for executing applications under real-time conditions in an embedded system - Google Patents

Device and method for executing applications under real-time conditions in an embedded system Download PDF

Info

Publication number
WO2012019627A1
WO2012019627A1 PCT/EP2010/004920 EP2010004920W WO2012019627A1 WO 2012019627 A1 WO2012019627 A1 WO 2012019627A1 EP 2010004920 W EP2010004920 W EP 2010004920W WO 2012019627 A1 WO2012019627 A1 WO 2012019627A1
Authority
WO
WIPO (PCT)
Prior art keywords
interrupt
kernel
real
computer
time conditions
Prior art date
Application number
PCT/EP2010/004920
Other languages
German (de)
French (fr)
Inventor
Wolfgang Hartmann
Karl-Heinz Krause
Original Assignee
Siemens Aktiengesellschaft
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Siemens Aktiengesellschaft filed Critical Siemens Aktiengesellschaft
Priority to PCT/EP2010/004920 priority Critical patent/WO2012019627A1/en
Publication of WO2012019627A1 publication Critical patent/WO2012019627A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4812Task transfer initiation or dispatching by interrupt, e.g. masked
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • G06F9/4887Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues involving deadlines, e.g. rate based, periodic

Definitions

  • embedded system refers to an electronic computer or computer that is embedded (embedded) in a technical context.
  • the computer either has the task to control the system in which it is embedded, to control, to monitor or the computer is responsible for a form of data or Signalverarbei device, for example, during encryption or decryption, coding or decoding or filtering.
  • Embedded systems perform the service in a wide variety of application areas and devices - largely invisible to the user. Often embedded systems are specially adapted to a task. Such a design combines the great flexibility of software with the performance of the hardware. The software serves both to control the system itself and, if necessary, to interact with the outside world via defined interfaces or protocols.
  • Linux interrupts are mapped to an S-lock bit for Linux. Once all real-time activities have ended, Linux will continue to run. Only if the SW-Lock bit for Linux is not set, the memory bits are also processed, d. H. running the appropriate original ISRs from Linux.
  • the device for executing at least one application even under real-time conditions in an embedded system comprises a first computer kernel for processing applications and a second computer kernel in particular for processing tasks within the application under real time conditions , wherein the second computer kernel is embedded in the first computer kernel.
  • the apparatus further comprises means for storing interrupt requests occurring during the execution of the at least one application, and means for checking the interrupt requests stored in the means for storage. Forwarding of the interrupt request occurring during the execution of the at least one application and intended for the first computer core can be blocked with the aid of at least one suitable filter mask if the at least one task is being executed under real-time conditions.
  • the object is further achieved by a method according to claim 6.
  • the method for performing at least one application even under real time conditions runs on an embedded system containing at least a first
  • An interrupt request occurring during the execution of the at least one application is stored and the stored interrupt request is checked. Then, a forwarding of the interrupt request occurring during the execution of the at least one application and determined for the first computer core is blocked with the aid of at least one suitable filter mask, provided that the at least one task is executed under real-time conditions.
  • An interrupt controller is the functional unit in the computer that is responsible for receiving and distributing the interrupts.
  • Virtually every interrupt controller has the ability to disable ("disarm") each individual interrupt, realized by a mask register located between the interrupt request register and the CPU.
  • Incoming interrupts are thus stored or delayed until the masking is canceled again.
  • This capability is typically used to secure (eg masking unconnected interrupt lines) or special device drivers (eg for overlapping between device and ISR).
  • a Linux interrupts lock must also be mapped to the masking of all Linux interrupts.
  • the implementation must, however, take into account that interrupt masking can be changed within interrupt inhibits.
  • another interrupt mask the so-called "shadow_mask”
  • the "shadow_mask” is an image of the HW mask register, which is only needed if the Linux interrupts are disabled and with unmask (irq) the interrupt masking of one Interrupt request is canceled. This must not be done in the HW mask register in this situation, otherwise a Linux interrupt would be unlocked within the Linux interrupts, but will be noted in the "shadow_mask.” If the Linux interrupts are canceled afterwards, then the "shadow_mask loaded into the HW mask register.
  • the Linux routine unmask (irq) only changes the "shadow_mask” and only when the interrupt is cleared with local_irq_enable () is the mask register loaded with the value of shadow_mask.
  • interrupts are already set to HW for Linux ISRs as well.
  • an additional stable bit (SW lock bit) is used.
  • An additional stable bit also leads to a performance gain, ie an acceleration of the processing of the application. Unnecessary changes of interrupt masking can thus be avoided.
  • the interrupt masking comprises a plurality of mask registers, this is particularly relevant.
  • Figure 1 is a schematic representation of the hardware
  • Figure 2 is a flowchart.
  • FIG. 1 shows a schematic structure of the device according to the invention.
  • Linux kernel is another core of computers, realtime kernel, embedded. All interrupt requests arrive through a register that can be used to store interrupt requests, an interrupt request register. By means of a suitable masking of the interruptions by means of an interrupt mask register, only such interrupt requests to the real-time computer kernel are transmitted when real-time critical applications expire, all further interrupt requests which are "only" intended for the Linux kernel are first stored in the register and retrieved at a later date.
  • the execution of the RT-ISR may have triggered the awakening of a (higher-priced) real-time thread. If necessary, switch to processing of the awake real-time thread with a check "Check for RT-Preemption", 17. It should be noted that until then the entire sequence runs under central interrupt lock, and is not until the beginning of the thread processing The release of the intrinsic controller, 16, could thus also take place earlier.At the end of the real-time processing, branching takes place due to the blocking state of the interrupted state, 18 ,.
  • VIRQs virtual interrupts

Abstract

Embedded systems operate in numerous application areas and devices. Even if there are hard real-time requirements for a computer deployment in the embedded field depending on the deployment and application, tasks without real-time requirements must also be processed in large volume. The aim of the invention is to specify a method that enables in particular Linux to be deployed on a two-kernel system for real-time requirements. Practically every interrupt controller has the ability to deactivate each individual interrupt. This is realized by a mask register, which is located between the interrupt request register and the CPU. Occurring interrupts are stored or delayed until the mask is lifted. Said ability is commonly used for protection (e.g., masking unconnected interrupt lines) or by special device drivers (e.g., for overlapped work between a device and an ISR). The use of said hardware function for the interrupt logging of a two-kernel solution is novel. If the real-time domain is always active (processing of real-time ISR or real-time threads), all Linux interrupts are masked.

Description

Beschreibung description
Vorrichtung und Verfahren zur Ausführung von Anwendungen unter Echtzeitbedingungen in einem eingebetteten System Apparatus and method for executing applications under real-time conditions in an embedded system
Fachgebiet der Erfindung Field of the invention
Der Ausdruck eingebettetes System (embedded System) bezeich- net einen elektronischen Rechner oder auch Computer, der in einen technischen Kontext eingebunden (eingebettet) ist. Dabei hat der Rechner entweder die Aufgabe, das System, in das er eingebettet ist, zu steuern, zu regeln, zu überwachen ode der Rechner ist für eine Form der Daten- bzw. Signalverarbei tung zuständig, beispielsweise beim Ver- bzw. Entschlüsseln, Codieren bzw. Decodieren oder Filtern. The term "embedded system" refers to an electronic computer or computer that is embedded (embedded) in a technical context. The computer either has the task to control the system in which it is embedded, to control, to monitor or the computer is responsible for a form of data or Signalverarbei device, for example, during encryption or decryption, coding or decoding or filtering.
Eingebettete Systeme verrichten - weitestgehend unsichtbar für den Benutzer - den Dienst in einer Vielzahl von Anwen- dungsbereichen und Geräten. Oft werden eingebettete Systeme speziell an eine Aufgabe angepasst. Dabei vereinigt eine sol che Konstruktion die große Flexibilität von Software mit der Leistungsfähigkeit der Hardware. Die Software dient sowohl zur Steuerung des Systems selbst, als auch ggf. zur Interak- tion des Systems mit der Außenwelt über definierte Schnittstellen oder Protokolle. Embedded systems perform the service in a wide variety of application areas and devices - largely invisible to the user. Often embedded systems are specially adapted to a task. Such a design combines the great flexibility of software with the performance of the hardware. The software serves both to control the system itself and, if necessary, to interact with the outside world via defined interfaces or protocols.
Auch wenn bei einem Rechnereinsatz im embedded Bereich je nach Einsatz und Anwendung harte EchtZeitanforderungen beste hen, so sind darüber hinaus Aufgaben ohne Echtzeitanforderun gen im größeren Umfang zu bearbeiten. Even if computer applications in the embedded sector are based on hard real-time requirements depending on the application and application, tasks without real-time requirements are also required to be processed on a larger scale.
Die Vielfalt dieser Aufgaben und die Unterstützung vieler im embedded Bereich etablierten Rechnerarchitekturen machen bei spielsweise Linux zu einem bevorzugt verwendeten Betriebssys tem. Leider ist aber der Linux-Kern nicht für Aufgaben mit sehr harten Echtzeitanforderungen geeignet. Stand der Technik Das Problem wird üblicherweise durch den Einsatz eines zweiten, in den Linux-Kern eingebetteten, Kernes gelöst. Dieser zweite Kern verwaltet die Aufgaben (Tasks) , die harten Echtzeitanforderungen gerecht werden müssen. Damit diese erfüllt werden können, dürfen insbesondere lang laufende Unterbre- chungsbehandlungen (Interrupt Service Routinen, ISRs) (von Linux) und lang dauernde Interruptsperren (von Linux) nicht die Bearbeitung von Echtzeit-ISRs bzw. Echtzeit-Tasks verzögern . Dazu werden sich für Linux bestimmte Unterbrechungen (Interrupts) erst einmal nur gemerkt ( Interrupt-Logging) . Das heisst, an Stelle der Original-Unterbrechungsroutine von Linux tritt eine kurze ISR, die beispielsweise nur ein entsprechendes Merker-Bit setzt. The diversity of these tasks and the support of many computer architectures established in the embedded sector make Linux, for example, a preferred operating system. Unfortunately, the Linux kernel is not suitable for tasks with very hard real-time requirements. Background Art The problem is usually solved by the use of a second kernel embedded in the Linux kernel. This second core manages the tasks that must meet hard real-time requirements. In particular, long-running Interrupt Service Routines (ISRs) (by Linux) and long-running interrupt locks (by Linux) must not delay the processing of real-time ISRs or real-time tasks so that these can be met. For this purpose, for Linux certain interruptions (interrupts) once only noticed (interrupt logging). That is, instead of the original Linux interrupt routine, a short ISR occurs, setting only a corresponding flag bit, for example.
Zum anderen werden Linux-Interruptsperren abgebildet auf ein S -Lock-Bit für Linux. Sobald alle Echtzeitaktivitäten beendet sind wird die Ausführung von Linux fortgesetzt. Nur wenn das SW-Lock-Bit für Linux nicht gesetzt ist, werden auch die Merkerbits bearbeitet, d. h. die entsprechenden Original- ISRs von Linux ausgeführt. On the other hand, Linux interrupts are mapped to an S-lock bit for Linux. Once all real-time activities have ended, Linux will continue to run. Only if the SW-Lock bit for Linux is not set, the memory bits are also processed, d. H. running the appropriate original ISRs from Linux.
Auch die kurzen Unterbrechungen zum Setzen des Merker-Bits (Logging-ISRs) verursachen eine Verzögerung der Echtzeitbear- beitung. Insbesondere dann, wenn mehrere solche Aktivitäten unmittelbar aufeinander folgen, und wenn der Prozessor nicht sehr schnell ist. Even the short interruptions for setting the flag bit (logging ISRs) cause a delay in real-time processing. In particular, when several such activities are immediately following each other, and when the processor is not very fast.
Es ist Aufgabe der Erfindung, ein Verfahren anzugeben, wel- ches den Einsatz von Linux auf einem zwei-Kernel-System für Echtzeit-Anforderungen ermöglicht und dabei die oben ausgeführten Nachteile vermeidet. Darstellung der Erfindung It is an object of the invention to specify a method which makes it possible to use Linux on a two-kernel system for real-time requirements while avoiding the disadvantages outlined above. Presentation of the invention
Diese Aufgabe wird gelöst durch eine Vorrichtung gemäß Patentanspruch 1. Die Vorrichtung zur Ausführung von zumindest einer Anwendung auch unter Echtzeitbedingungen in einem eingebetteten System umfasst einen ersten Rechnerkernel zur Be- arbeitung von Anwendungen und einen zweiten Rechnerkernel insbesondere zur Bearbeitung von Aufgaben innerhalb der Anwendung unter EchtZeitbedingungen, wobei der zweite Rechnerkernel in den ersten Rechnerkernel eingebettet ist. Die Vorrichtung umfasst weiterhin Mitteln zur Speicherung von wäh- rend der Ausführung der zumindest einen Anwendung auftretenden Unterbrechungsanforderungen, und Mittel zur Prüfung der in den Mitteln zur Speicherung gespeicherten Unterbrechungsanforderungen . Eine Weiterleitung der während der Ausführung der zumindest einen Anwendung auftretenden und für den ersten Rechnerkerne bestimmten Unterbrechungsanforderung ist mit Hilfe von zumindest einer geeigneten Filtermaske blockierbar, sofern die zumindest eine Aufgabe gerade unter Echtzeitbedingungen ausge- führt wird. This object is achieved by a device according to claim 1. The device for executing at least one application even under real-time conditions in an embedded system comprises a first computer kernel for processing applications and a second computer kernel in particular for processing tasks within the application under real time conditions , wherein the second computer kernel is embedded in the first computer kernel. The apparatus further comprises means for storing interrupt requests occurring during the execution of the at least one application, and means for checking the interrupt requests stored in the means for storage. Forwarding of the interrupt request occurring during the execution of the at least one application and intended for the first computer core can be blocked with the aid of at least one suitable filter mask if the at least one task is being executed under real-time conditions.
Die Aufgabe wird weiterhin gelöst mit einem Verfahren gemäß Patentanspruch 6. Das Verfahren zur Ausführung von zumindest- einer Anwendung auch unter EchtZeitbedingungen läuft auf ei- nem eingebetteten System enthaltend zumindest einen erstenThe object is further achieved by a method according to claim 6. The method for performing at least one application even under real time conditions runs on an embedded system containing at least a first
Rechnerkernel und zumindest einem zweiten Rechnerkernel insbesondere zur Bearbeitung von Aufgaben unter Echtzeitbedin- gungen ab, wobei der zweite Rechnerkernel in den ersten Rechnerkernel eingebettet ist. Eine während der Ausführung der zumindest einen Anwendung auftretenden Unterbrechungsanforderung wird gespeichert und die gespeicherte Unterbrechungsanforderung wird geprüft. Dann wird eine Weiterleitung der während der Ausführung der zumindest einen Anwendung auftretenden und für den ersten Rechnerkerne bestimmten Unterbrechungsanforderung mit Hilfe von zumindest einer geeigneten Filtermaske blockiert, sofern die zumindest eine Aufgabe gerade unter EchtZeitbedingungen ausgeführt wird. Computer kernel and at least a second computer kernel in particular for processing tasks under real-time conditions from, wherein the second computer kernel is embedded in the first computer kernel. An interrupt request occurring during the execution of the at least one application is stored and the stored interrupt request is checked. Then, a forwarding of the interrupt request occurring during the execution of the at least one application and determined for the first computer core is blocked with the aid of at least one suitable filter mask, provided that the at least one task is executed under real-time conditions.
Der oben aufgeführte Nachteil lässt sich umgehen, indem der (HW-) Interrupt Controller für ein Interrupt Logging genutzt wird. The above drawback can be avoided by using the (HW) interrupt controller for interrupt logging.
Als Interrupt Controller bezeichnet man die Funktionseinheit im Computer, die für die Entgegennahme und Verteilung der Interrupts zuständig ist. An interrupt controller is the functional unit in the computer that is responsible for receiving and distributing the interrupts.
Praktisch jeder Interrupt Controller hat die Fähigkeit, jeden einzelnen Interrupt zu deaktivieren („disarmen") . Realisiert ist dies durch ein Maskierungsregister, das sich zwischen dem Interrupt Request Register und der CPU befindet. Virtually every interrupt controller has the ability to disable ("disarm") each individual interrupt, realized by a mask register located between the interrupt request register and the CPU.
Eintreffende Interrupts werden damit gespeichert bzw. solange verzögert bis die Maskierung wieder aufgehoben wird. Genutzt wird diese Fähigkeit üblicherweise zur Absicherung (z. B. Maskierung nicht angeschlossener Interrupt-Leitungen) oder von speziellen Geräte-Treibern (z. B. für überlapptes Arbeiten zwischen Gerät und ISR) . Incoming interrupts are thus stored or delayed until the masking is canceled again. This capability is typically used to secure (eg masking unconnected interrupt lines) or special device drivers (eg for overlapping between device and ISR).
Neu ist die Nutzung dieser Hardwarefunktion für das Interrupt Logging einer Zweikernellösung. Wenn immer die Echtzeitdomäne aktiv ist (Bearbeitung von Echtzeit-ISR oder Echtzeit- Threads) werden alle Linux-Interrupts maskiert. What's new is the use of this hardware function for the interrupt logging of a two-core solution. Whenever the real-time domain is active (processing real-time ISR or real-time threads), all Linux interrupts are masked.
Weitere vorteilhafte Ausgestaltungen sind in den Unteransprüchen beschrieben. Further advantageous embodiments are described in the subclaims.
Eine Linux-Interruptsperre muss ebenso auf die Maskierung aller Linux-Interrupts abgebildet werden. Die Implementierung muss aber berücksichtigen, dass die Interruptmaskierung innerhalb von Interruptsperren geändert werden kann. Dazu wird eine weitere Interrupt-Maske, die sogenannte „shadow_mask" eingeführt. Die „shadow_mask" ist ein Abbild des HW- Maskenregisters, die nur benötigt wird, wenn die Linux- Interrupts gesperrt sind und mit unmask (irq) die Interrupt- Maskierung einer Unterbrechungsanforderung aufgehoben wird. Das darf in dieser Situation nicht im HW-Maskenregister erfolgen, sonst würde innerhalb der Linux-Interruptsperre ein Linux-Interrupt entsperrt, sondern wird in der „shadow_mask" vermerkt. Wenn die Linux-Interruptsperre danach wieder aufge hoben wird, dann wird die „shadow_mask" in das HW- Maskenregister geladen. A Linux interrupts lock must also be mapped to the masking of all Linux interrupts. The implementation must, however, take into account that interrupt masking can be changed within interrupt inhibits. For this, another interrupt mask, the so-called "shadow_mask", is introduced The "shadow_mask" is an image of the HW mask register, which is only needed if the Linux interrupts are disabled and with unmask (irq) the interrupt masking of one Interrupt request is canceled. This must not be done in the HW mask register in this situation, otherwise a Linux interrupt would be unlocked within the Linux interrupts, but will be noted in the "shadow_mask." If the Linux interrupts are canceled afterwards, then the "shadow_mask loaded into the HW mask register.
Die Linux-Routine unmask (irq) verändert nur die „shadow_mask und erst beim Aufheben der Interruptsperre mit lo- cal_irq_enable () wird das Maskenregister mit dem Wert von shadow_mask geladen. The Linux routine unmask (irq) only changes the "shadow_mask" and only when the interrupt is cleared with local_irq_enable () is the mask register loaded with the value of shadow_mask.
Weiterhin muss berücksichtigt werden, dass beim Eintritt in die ISR-Bearbeitung auch für Linux-ISRs die Interruptsperre bereits per HW gesetzt ist. Um Eindeutigkeit bzw. Einheitlichkeit zu erreichen (z. B. für die Implementierung der Funktion irqs_disabled () ) wird mit einem zusätzlichen Stall- Bit (SW-Lock-Bit) gearbeitet. Ein zusätzliches Stall-Bit führt auch noch zu einem Performancegewinn, also einer Beschleunigung der Abarbeitung der Anwendung. Unnötige Änderun gen der Interrupt-Maskierung können damit vermieden werden. Insbesondere dann, wenn die Interrupt- Maskierung mehrere Maskenregister umfasst, ist dies besonders relevant. Furthermore, it must be taken into account that when ISR processing is started, the interrupts are already set to HW for Linux ISRs as well. In order to achieve unambiguity or uniformity (eg for the implementation of the function irqs_disabled ()), an additional stable bit (SW lock bit) is used. An additional stable bit also leads to a performance gain, ie an acceleration of the processing of the application. Unnecessary changes of interrupt masking can thus be avoided. In particular, when the interrupt masking comprises a plurality of mask registers, this is particularly relevant.
Mit diesen Maßnahmen lässt sich mit minimalen Änderungen am Linux-Code eine Verzögerung der EchtZeitbearbeitung durch Li nux-ISRs und Linux-Interruptsperren vollständig vermeiden. Beschreibung der bevorzugten Ausgestaltungsformen These measures can be used to completely avoid a delay in realtime processing by Li nux ISRs and Linux interrupts with minimal changes to the Linux code. Description of the preferred embodiments
Kurzbeschreibung der Zeichnungen Im Folgenden wird die Erfindung anhand von Ausführungsbeispielen erläutert. Dabei zeigen BRIEF DESCRIPTION OF THE DRAWINGS The invention is explained below on the basis of exemplary embodiments. Show
Figur 1 eine schematische Darstellung der Hardware, Figur 2 ein Ablaufdiagramm. Figure 1 is a schematic representation of the hardware, Figure 2 is a flowchart.
Figur 1 zeigt einen schematischen Aufbau der erfindungsgemä- ften Vorrichtung. In einem ersten Rechnerkern, Linux kernel ist ein weiterer Rechnerkern, realtime kernel, eingebettet. Sämtliche Unterbrechungsanforderungen treffen durch ein Register, welches zur Speicherung von Unterbrechungsanforderungen verwendet werden kann, ein, Interrupt Request Register. Durch eine geeignete Maskierung der Unterbrechungen mittels eines Interrupt Masken Registers werden bei Ablauf von Echt- zeitkritischen Anwendungen nur solche Unterbrechungsanforderungen an den Echtzeit-Rechnerkernel durchgelassen, alle weiteren Unterbrechungsanforderungen, die „nur" für den Linux- Kernes bestimmt sind, weden zunächst im Register abgelegt und zu einem späteren Zeitpunkt abgerufen. FIG. 1 shows a schematic structure of the device according to the invention. In a first computer core, Linux kernel is another core of computers, realtime kernel, embedded. All interrupt requests arrive through a register that can be used to store interrupt requests, an interrupt request register. By means of a suitable masking of the interruptions by means of an interrupt mask register, only such interrupt requests to the real-time computer kernel are transmitted when real-time critical applications expire, all further interrupt requests which are "only" intended for the Linux kernel are first stored in the register and retrieved at a later date.
Die Ermittlung des Interrupts durch den IR-Controller-Prolog wird in Figur 2 dargestellt, 11, sie ist hardwarespezifischer aber unveränderter Linux-Code, meist in Assembler geschrieben. Der Sperrzustand des unterbrochenen Zustands wird auf den Stack gerettet. Nur wenn die Linux-Interrupts noch nicht gesperrt, 12, waren, ist es notwendig die Interrupt Maskierung zu setzen, 21 . Für die Interruptbearbeitung muss differenziert werden zwischen einem Linuxinterrupt, 31, und einem Echtzeit-Interrupt, 14. Dazu ist ein Tabelleneintrag der "Li- nux-Interrupt-Tabelle" um ein Element erweitert. Dieses Element ist ein Funktionszeiger auf eine "Echtzeit-ISR" . Ein gültiger Funktionszeiger (!= NULL) bedeutet, dass für diesen Interrupt eine Echt Zeitbearbeitung eingerichtet ist, 15. The determination of the interrupt by the IR controller prologue is shown in Figure 2, 11, it is hardware-specific but unmodified Linux code, usually written in assembler. The lock state of the suspended state is saved to the stack. Only if the Linux interrupts were not locked, 12, it is necessary to set the interrupt masking, 21. For interrupt processing, a distinction must be made between a Linux interrupt, 31, and a real-time interrupt, 14. For this, a table entry of the "Linux interrupt table" has been extended by one element. This element is a function pointer to a "real-time ISR". One valid function pointer (! = NULL) means that a real time processing has been set up for this interrupt, 15.
Die Ausführung der RT-ISR kann das Aufwecken eines (höherpri- oren) Echtzeit-Threads bewirkt haben. Mit einer Abfrage „Check for RT- Preemption" , 17, wird gegebenenfalls auf die Bearbeitung des aufgeweckten Echtzeit-Threads umgeschaltet. Anzumerken ist, dass bis dahin die gesamte Sequenz unter zentraler Interrupt-Sperre läuft. Erst mit Beginn der Thread- Bearbeitung ist sie wieder aufgehoben. Die Freigabe des In- terrupt-Controllers, 16, könnte also auch früher erfolgen. Am Ende der Echtzeitbearbeitung wird aufgrund des Sperrzustands des unterbrochenen Zustand verzweigt, 18,. The execution of the RT-ISR may have triggered the awakening of a (higher-priced) real-time thread. If necessary, switch to processing of the awake real-time thread with a check "Check for RT-Preemption", 17. It should be noted that until then the entire sequence runs under central interrupt lock, and is not until the beginning of the thread processing The release of the intrinsic controller, 16, could thus also take place earlier.At the end of the real-time processing, branching takes place due to the blocking state of the interrupted state, 18 ,.
- war der unterbrochene Zustand bereits gesperrt (Linux- Interruptsperre oder RT-Thread Ausführung wurde unterbro- chen) , so wird der " Interrupt-Zustand" direkt verlassen, 19 - if the interrupted state was already blocked (Linux interrupt disable or RT thread execution was interrupted), the "interrupt state" is left directly, 19
- wird in den ungesperrten Linux-Zustand zurückgekehrt, so wird das Interrupt-Maskenregister mit dem aktuellen Zustand (s adow_mas/ geladen und der " Interrupt-Zustand" über den Standard Linux Interrupt Epilog verlassen, 43, 52. Die Echt- zeit-Aktivität kann auch eine Benachrichtigung von Linux zur Folge haben, die über sogenannte virtuelle Interrupts (VIRQs) erfolgt, 42. Die Behandlung solcher pending VIRQs erfolgt vor dem Epilog, 43. - If the system returns to the unlocked Linux state, then the interrupt mask register is loaded with the current state (s adow_mas / and the "interrupt state" is exited via the standard Linux Interrupt Epilog, 43, 52. The real-time activity may also result in notification of Linux via so-called virtual interrupts (VIRQs), 42. The treatment of such pending VIRQs occurs before the epilogue, 43.

Claims

Patentansprüche claims
Vorrichtung zur Ausführung von zumindest einer Anwendung auch unter EchtZeitbedingungen in einem eingebetteten Sys tem Device for executing at least one application even under real time conditions in an embedded system
mit einem ersten Rechnerkernel (Linux kernel)  with a first computer kernel (Linux kernel)
und einem zweiten Rechnerkernel (realtime kernel) zur Bearbeitung von Aufgaben unter Echtzeitbedingungen, wobei der zweite Rechnerkernel in den ersten Rechnerkernel eingebettet ist, mit  and a second computer kernel (realtime kernel) for processing tasks under real-time conditions, wherein the second computer kernel is embedded in the first computer kernel, with
Mitteln zur Speicherung (IRR) von während der Ausführung der zumindest einen Anwendung auftretenden Unterbrechungs anforderungen, und  Means for storing (IRR) interruption requests occurring during the execution of the at least one application, and
Mittel zur Prüfung (IMR) der in den Mitteln zur Speicherung (IRR) gespeicherten Unterbrechungsanforderungen, wobei eine Weiterleitung der während der Ausführung der zumindest einen Anwendung auftretenden und für den ersten Rechnerkerne bestimmten Unterbrechungsanforderung mit Hil fe von zumindest einer geeigneten Filtermaske blockierbar ist sofern die zumindest eine Aufgabe gerade unter Echtzeitbedingungen ausgeführt wird.  Means for checking (IMR) the interrupt requests stored in the means for storing (IRR), wherein a forwarding of the interrupt request occurring during the execution of the at least one application and determined for the first computer core can be blocked by means of at least one suitable filter mask provided that at least a task is being executed under real-time conditions.
Vorrichtung nach Patentanspruch 1, Device according to claim 1,
dadurch gekennzeichnet, dass  characterized in that
die zumindest eine Filtermaske deaktivierbar ist, und gespeicherte Unterbrechungsanforderungen weiterleitbar sind sofern keine Aufgaben zur Ausführung unter Echtzeitbedin- gungen vorliegen.  the at least one filter mask can be deactivated and stored interrupt requests can be forwarded provided that there are no tasks for execution under real-time conditions.
Vorrichtung nach Patentanspruch 1 oder 2, Device according to claim 1 or 2,
dadurch gekennzeichnet, dass  characterized in that
die in den Mittel zur Prüfung (IMR) der auftretenden Unterbrechungsanforderungen enthaltene zumindest eine Filtermaske änderbar ist. Vorrichtung nach einem der vorherigen Patentansprüche, dadurch gekennzeichnet, dass the at least one filter mask contained in the means for checking (IMR) the occurring interrupt requests is changeable. Device according to one of the preceding claims, characterized in that
die Mittel zur Speicherung (IRR) von während der Ausführung der zumindest einen Anwendung auftretenden Unterbrechungsanforderungen eine Tabelle umfasst und the means for storing (IRR) interrupt requests occurring during the execution of the at least one application comprises a table and
die Tabelle ein zusätzliches Feld pro Unterbrechungsanfor- derungseintrag enthält, the table contains one extra field per interrupt request entry,
in welchem ein Funktionszeiger ablegbar ist, welcher auf eine Bearbeitungsroutine für die zugehörige Unterbrechungsanforderungen verweist. in which a function pointer can be stored, which refers to a processing routine for the associated interrupt requests.
Vorrichtung nach einem der vorherigen Patentansprüche, dadurch gekennzeichnet, dass Device according to one of the preceding claims, characterized in that
die Mittel zur Prüfung ein Maskierungsregister umfasst, das sich zwischen dem Mitteln zur Speicherung, welche das Interrupt Request Register beinhalten und der CPU, die den zumindest ersten und zumindest zweiten Rechnerkernel umfasst, befindet. the means for checking comprises a masking register located between the means for storing the interrupt request register and the CPU comprising the at least first and at least second computer kernel.
Verfahren zur Ausführung von zumindest einer Anwendung auch unter EchtZeitbedingungen auf einem eingebetteten System enthaltend zumindest einen ersten Rechnerkernel (Linux kernel) und zumindest einem zweiten Rechnerkernel (realtime kernel) insbesondere zur Bearbeitung von Aufgaben unter EchtZeitbedingungen, wobei der zweite Rechnerkernel in den ersten Rechnerkernel eingebettet ist, bei dem Method for executing at least one application even under real time conditions on an embedded system containing at least a first computer kernel (Linux kernel) and at least one second computer kernel (realtime kernel), in particular for processing tasks under real time conditions, wherein the second computer kernel is embedded in the first computer kernel , in which
eine während der Ausführung der zumindest einen Anwendung auftretenden Unterbrechungsanforderung gespeichert wird, und an interrupt request occurring during the execution of the at least one application is stored, and
die gespeicherte Unterbrechungsanforderung geprüft wird, wobei eine Weiterleitung der während der Ausführung der zumindest einen Anwendung auftretenden und für den ersten Rechnerkerne bestimmten Unterbrechungsanforderung mit Hilfe von zumindest einer geeigneten Filtermaske blockiert wird sofern die zumindest eine Aufgabe gerade unter Echtzeitbedingungen ausgeführt wird. Verfahren nach einem der vorherigen Patentansprüche, dadurch gekennzeichnet dass the stored interrupt request is checked, wherein a forwarding of the interrupt request occurring during the execution of the at least one application and determined for the first computer core is blocked by means of at least one suitable filter mask if the at least one task is being executed under real-time conditions. Method according to one of the preceding claims, characterized in that
die zumindest eine Filtermaske deaktiviert wird, und gespeicherte Unterbrechungsanforderungen weitergeleitet werden sofern keine Aufgaben zur Ausführung unter Echtzeitbedingungen vorliegen. the at least one filter mask is deactivated, and stored interrupt requests are forwarded unless there are tasks to perform under real-time conditions.
Verfahren nach einem der Patentansprüche 1 bis 3, dadurch gekennzeichnet dass Method according to one of the claims 1 to 3, characterized in that
die zur Prüfung (IMR) der auftretenden Unterbrechungsanforderungen enthaltene zumindest eine Filtermaske änderbar ist . the at least one filter mask contained for checking (IMR) of the occurring interrupt requests can be changed.
Verfahren nach einem der vorherigen Patentansprüche, dadurch gekennzeichnet, dass Method according to one of the preceding claims, characterized in that
die während der Ausführung der zumindest einen Anwendung auftretenden Unterbrechungsanforderungen in einer Tabelle gespeichert werden und the interrupt requests occurring during the execution of the at least one application are stored in a table and
die Tabelle ein zusätzliches Feld pro Ünterbrechungsanfor- derungseintrag enthält, the table contains an additional field per interruption entry,
für ein Funktionszeiger, welcher auf eine Bearbeitungsroutine für die zugehörige Unterbrechungsanforderungen verweist. for a function pointer, which points to a processing routine for the associated interrupt requests.
PCT/EP2010/004920 2010-08-11 2010-08-11 Device and method for executing applications under real-time conditions in an embedded system WO2012019627A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/EP2010/004920 WO2012019627A1 (en) 2010-08-11 2010-08-11 Device and method for executing applications under real-time conditions in an embedded system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/EP2010/004920 WO2012019627A1 (en) 2010-08-11 2010-08-11 Device and method for executing applications under real-time conditions in an embedded system

Publications (1)

Publication Number Publication Date
WO2012019627A1 true WO2012019627A1 (en) 2012-02-16

Family

ID=42711997

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/EP2010/004920 WO2012019627A1 (en) 2010-08-11 2010-08-11 Device and method for executing applications under real-time conditions in an embedded system

Country Status (1)

Country Link
WO (1) WO2012019627A1 (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1996018152A1 (en) * 1994-12-06 1996-06-13 Intel Corporation An improved method and apparatus for embedding a real-time multi-tasking kernel in a non-real-time operating system
US5995745A (en) * 1996-12-23 1999-11-30 Yodaiken; Victor J. Adding real-time support to general purpose operating systems

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1996018152A1 (en) * 1994-12-06 1996-06-13 Intel Corporation An improved method and apparatus for embedding a real-time multi-tasking kernel in a non-real-time operating system
US5995745A (en) * 1996-12-23 1999-11-30 Yodaiken; Victor J. Adding real-time support to general purpose operating systems

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
REGNIER P ET AL: "Evaluation of interrupt handling timeliness in real-time Linux operating systems", OPERATING SYSTEMS REVIEW, vol. 42, no. 6, October 2008 (2008-10-01), ACM USA, pages 52 - 63, XP002601614, ISSN: 0163-5980, DOI: 10.1145/1453775.1453787 *

Similar Documents

Publication Publication Date Title
DE69533312T2 (en) PROTECTED STORAGE SYSTEM AND METHOD THEREFOR
EP0011685B1 (en) Programmable memory protection arrangement for microprocessors and circuitry with such an arrangement
DE69926365T2 (en) SOFTWARE CONFIGURABLE TECHNIQUE TO PRIORIZE INTERRUPTIONS IN A SYSTEM BASED ON A MICROPROCESSOR
EP1019819B1 (en) Program controlled unit and method for debugging same
DE2629459A1 (en) DATA PROCESSING SYSTEM
DE102005037230A1 (en) Method and device for monitoring functions of a computer system
DE102005037228A1 (en) Method and device for controlling a computer system
DE112011102876T5 (en) Resource Management and Security System
DE4406094C2 (en) Device for operating a control application
EP1817662B1 (en) Method and device for switching between operating modes of a multiprocessor system by means of at least an external signal
DE102013021231A1 (en) Method for operating an assistance system of a vehicle and vehicle control unit
EP2494488B1 (en) Method for executing security-relevant and non-security-relevant software components on a hardware platform
DE102014204417A1 (en) Apparatus and method for detecting a manipulation of a program code
WO2012019627A1 (en) Device and method for executing applications under real-time conditions in an embedded system
EP3311273A1 (en) Method and apparatus for protecting a program counter structure of a processor system and for monitoring the handling of an interrupt request
DE102017220764A1 (en) One-chip system for a vehicle
DE112018002612T5 (en) Vehicle control device
EP3752911A1 (en) Method for installing a program code packet onto a device, device, and motor vehicle
DE102009001048A1 (en) Device for testing functioning of dual-core computer system for e.g. security-relevant control system of motor vehicle, has switching and comparison unit triggered-off by signal, where signal is led back to test unit
DE102004048945B4 (en) System monitoring unit
DE102016222691A1 (en) Microcontroller system and method for controlling memory accesses in a microcontroller system
DE102012204644B4 (en) CONTROL DEVICE
EP3391279B1 (en) Microcontroller system and method for controlling memory access in a microcontroller system
EP1915674B1 (en) Method and device for controlling a computer system comprising at least two execution units and at least two groups of internal states
DE102013204037B4 (en) microcomputer

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 10744525

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 10744525

Country of ref document: EP

Kind code of ref document: A1