Introduction to important Linux interrupt functions

Source: Internet
Author: User

The interfaces provided by the kernel include registering and deregistering interrupt handlers, forbidding interruptions, shielding interruption, and checking the status of the interrupt system.

 

The following are several interrupt control methods:

 

Local_irq_disable () Disable local interruption

Local_irq_enable () activates local interrupt

Local_irq_save () saves the current status of the local interruption transfer, and then disables the local interruption transfer.

Local_irq_restore () restores the local interrupt passed to the specified state

Disable_irq () disables a given disconnection and ensures that no handler is running on the interrupt line before the function returns.

Disable_irq_nosync () disables a specified disconnection.

Enable_irq () activates a given disconnection

Irqs_disabled () if the local interruption transmission is disabled, non-0 is returned; otherwise, 0 is returned.

In_interrupt () if it is in the interrupt context, non-0 is returned. If it is in the process context, 0 is returned.

In_irq () if the Interrupt Processing Program is being executed, non-0 is returned. Otherwise, 0 is returned.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.