- 1、本文档共14页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
- 5、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
- 6、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们。
- 7、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
- 8、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
ia32上linux内核中断机制分析(Interrupt mechanism analysis of Linux kernel on IA32)
ia32上linux内核中断机制分析(Interrupt mechanism analysis of Linux kernel on IA32)
425SAVE_ALL\# save register
426movl%esp,%eax; \
427callsmp_/**/name \ \
428jmpret_from_intr;
Among them, the SAVE_ALL macro is used to save the register.
The interrupt context often referred to in kernel books means that the kernel is running an interrupt service program or softirq, and cannot represent the current process. Interrupt context does not have its own proprietary stack, on the contrary, it is used to interrupt the process of the kernel stack, IA-32 Linux the default stack size of only 8K, and probably in the process of handling the interrupt in another interrupt interrupt source. Therefore, if you write interrupt handlers yourself, the recursion level is too deep, or the function local variables are too large, it may cause stack overflow. (i386 has a 4KStacks patch, and if the option is opened at compile time, the interrupt context uses a separate stack without taking up the interrupt process.)
In the include/linux/irq.h file, an interrupt description array iqr_desc[NR_IRQS] is defined, and each interrupt vector is associated with one of its elements:
70typedefstructirq_desc{
71hw_irq_controller*handler;
72void*handler_data;
73structirqaction*action; /*IRQactionlist*/
74unsignedintstatus; /*IRQstatus*/
75unsignedintdepth; /*nestedirqdisables*/
76unsignedintirq_count; /*Fordetectingbrokeninterrupts*/
77unsignedintirqs_unhandled;
78spinlock_tlock;
79#ifdefined (CONFIG_GENERIC_PENDING_IRQ) ||defined (CONFIG_IRQBALANCE)
80unsignedintmove_irq; /*Flagneedtore-targetintrdest*/
81#endif
82}____cacheline_alignedirq_desc_t; / * and CPU L1 told the GCC cache alignment.
Eighty-three
84externirq_desc_tirq_desc[NR_IRQS];
When an interrupt occurs, the kernel is handled like this (arch/i386/kernel/entry.S):
416common_interrupt:
417SAVE_ALL
418movl%esp,%eax
419calldo_IRQ
420jmpret_from_intr
The SAVE_ALL macro definition in entry.S is responsible for saving the register, then transferring the%esp reg
您可能关注的文档
- f3gfdeqsfeedgtesadcc3e4212311(f3gfdeqsfeedgtesadcc3e4212311).doc
- f3gfdeqsfeedgtesadcc3e42123(f3gfdeqsfeedgtesadcc3e42123).doc
- fab产品介绍法(Fab product introduction).doc
- facebook管理招聘新职位拓展越南业务(Facebook manage new recruitment positions and expand business in Vietnam).doc
- e学堂暑促考试终极题库(E school examination questions the ultimate fashion).doc
- fans心理与品牌营销之关联(The relationship between fans psychology and brand marketing).doc
- fbx文件(FBX file).doc
- fdbd-0.5、fsbd—0.5电(手)动多叶蝶阀,电动(手动)风机启动阀,风机启动调节阀(Fdbd-0.5, fsbd - 0.5 electric (hand) dynamic multi leaf butterfly valve, electric (manual) fan start valve, fan start control valve).doc
- fdisk分区挂载(fdisk分区挂载).doc
- ff fr为车的驱动方式(FF FR is the driving mode of the car).doc
- 2025年安徽演艺集团有限责任公司招聘20人笔试备考题库及答案详解(有一套).docx
- 2025年安徽演艺集团有限责任公司招聘20人笔试备考题库及答案详解(网校专用).docx
- 2025年安徽演艺集团有限责任公司招聘20人笔试备考题库及答案详解(最新).docx
- 2025年安徽演艺集团有限责任公司招聘20人笔试备考题库精选答案详解.docx
- 2025年宝鸡先行电力(集团)有限责任公司招聘(4人)笔试备考题库附答案详解(基础题).docx
- 2025年宝鸡先行电力(集团)有限责任公司招聘(4人)笔试备考题库附答案详解(考试直接用).docx
- 2025年宝鸡先行电力(集团)有限责任公司招聘(4人)笔试备考题库附答案详解(名师推荐).docx
- 2025年宝鸡先行电力(集团)有限责任公司招聘(4人)笔试备考题库附答案详解(培优).docx
- 2025年宝鸡先行电力(集团)有限责任公司招聘(4人)笔试备考题库附答案详解(培优b卷).docx
- 2025年宝鸡先行电力(集团)有限责任公司招聘(4人)笔试备考题库附答案详解(实用).docx
文档评论(0)