Play with interrupts in long texts with ten thousand characters: 8088 (10,000) interrupts from the perspective of hardware

foreword

To be honest, I don’t know if this interruption is necessary to write, because there are too many excellent articles on the Internet.

But in the end, after reading a lot of articles by seniors, I seem to understand, but I always feel uncomfortable. In the end, I found that most of the content of the seniors is very partial. This is not because of the abilities of the seniors, but because the seniors want to describe some knowledge in as short words as possible.

So this long-winded article was born, and it happened to be gic before, so both x86 and arm will be involved here, I believe this article will benefit you.

The entire article series is divided into the following two areas:

  • 1. What is an interrupt from the perspective of hardware?
  • 2. What is an interrupt from the perspective of the kernel?

(Thanks for the excellent books and blogs of the predecessors)

1. What is an interrupt from the perspective of hardware?

1 Introduction

The so-called interruption means that when the CPU is running the program normally, the event pre-arranged by the program, or the CPU interrupts the running program caused by internal and external events, and switches to the program that serves the pre-arranged event or internal and external events to go.

  • These events that cause program interruption are called interrupt sources.
  • A pre-scheduled event is an interrupt instruction from the PC .

At this point, immediately go to the corresponding service program to execute.

Internal events refer to some event signals that appear on the system board, and interrupt instructions can also be regarded as internal events .

External events refer to signals sent by some interface devices to interrupt program execution, and these signals are called interrupt request signals .

When interrupt request signals occur is unpredictable , however, they send electrical signals to the CPU as soon as they request an interrupt, so these signals CPU

Guess you like

Origin blog.csdn.net/weixin_45264425/article/details/131714258