The mechanism of interruptions of a code stream on the part of a hardware (Механизм прерываний кодового потока со стороны аппаратной часть компьютера)

Страницы работы

Содержание работы

BELORUSSIAN STATE UNIVERSITY OF TRANSPORT

Foreign Languages Chair 51 Students Scientific Conference

Report

Operational system internals

Matylitskij I. V. a Student of group ES-21

Rubtsov K. M. a Student of group ES-21

Done by

Supervisor Ivanova S. V.

2006


Оглавление.

Annotation……………………………………………………………………………...3

Description……………………………………………………………………………..4

Conclusion……………………………………………………………………………..8

Аннотация……………………………………………………………………………..9

Описание………………………………………………………………………………10

Заключение……………………………………………………………………………14

Список использованной литературы……………………………………………...15


Annotation

This report is devoted to the mechanism of interruptions of a code stream on the part of a hardware. In it mechanisms of reaction of operational system Windows NT on hardware events speak: pressing of keys, movement of the mouse, etc.


Description

The answer to a question on interruptions it is necessary to search in hardware depths of system, with finishing a chain of research up to the end - for reception by the applied program of the message on pressing a key, with the information, for example about a virtual code of this key.

So, for an illustration of all mechanism, we shall make small mental experiment - the user of a computer has pressed a key on the keyboard. We shall look after a chain of transformations of this event of the physical form in logic, and further - formalized program.

What occurs by pressing any key? The circuit which key this key is, becomes isolated, and on an input of the special microchip which are taking place in the case of the keyboard which the given circuit comes to an end, appears the potential corresponding to logic unit. This microchip is called the controller and is the programmed device (the micro-computer in integral execution). According to the program of the protocol of information interchange with the accepting device - port of a computer to which this keyboard is attached, it sends a package of byte in port. The port too is controller's device, and that we see on the back panel of a computer - only its socket. The accepting controller receives this package of byte and decodes already in a package of other protocol. The given controller is the affiliated device of that bus to which it is attached.

The controller of port will transform the arrived package of the protocol of concrete port to a package of the protocol of the concrete bus by which the given port is served. Further this package gets on the controller of the arbitrator of the bus.

The controller of the bus establish a signal of logic unit on an input of the special device-intermediary between inquiries of devices about processing of events, with them occuring, and the processor - a PIC-microchip (Programmable Interrupt Controller). It is the controller too.

The basic scheme of hardware service of interruptions.

At receipt of a signal on the controller it will check up this line in the internal table of masking for those concerning the given input. If the line is marked in the table as maskable the controller will not react in any way, and the signal will be present still on a line of interruption, expecting the processing until while in table to not change a condition of scheduling of this line as not maskable.

We admit, that interruption of the keyboard at present does not mask. Then the controller gives out to the controller of port a reciprocal signal - IRQA (Interrupt Request Acknowledgement). In a consequence the controller removes inquiry from a line of interruption and continues expectation of processing of event in not alarm mode. The controller also submits a signal on one of inputs of the processor on processing of interruption. It is necessary to note, that this process occurs at direct hardware interaction PIC and the central processor. Further the processor requests at PIC, on which line interruption has arrived.

From here the stage of processing specific to concrete operational system begins. It was earlier stipulated, that the question will be platform Windows NT. So, the processor x86 finds in the special system structure, supported is hardware, and taking place in memory, - table IDT (Interrupt Descriptors Table), record with a descriptor of the given interruption. This descriptor - a usual bit field in which, in addition, there is an address of the special program being a field of system structure, which created by system at loading and initialization of devices - object of interruption.

In object of interruption there is a small assembly subroutine which makes a call of the true dispatcher of interruptions.

The given stage is not supervised by system and the object of interruption is applied for this purpose, which causes actually the dispatcher with necessary parameters.

Also in object there is ISR address of the driver, IRQL of interruption and the auxiliary information (back-blocking, etc.).

Assembly procedure in object of interruption is applied same and copied from a special system template during loading. This shift Windows allows it to take the initiative of  execution of a code in the hands.

Further procedure causes the true dispatcher of interruptions, copying in a stack of a call the information from object. If IRQL not shared there is a setting on processor IRQL by special function of a core of system and direct call ISR of the driver.

The generalized scheme of processing of hardware interruption.

If IRQL is shared there is interrogation ISR of the drivers corresponding to caused object of interruption while one of drivers will not notify, that the it's served device expects processing inquiry.

Похожие материалы

Информация о работе