现在的位置: 首页 > 综合 > 正文

Documentation/ia64/IRQ-redir.txt

2013年12月09日 ⁄ 综合 ⁄ 共 3931字 ⁄ 字号 评论关闭

Chinese translated version of Documentation/filesystems/ecryptfs.txt

If you have any comment or update to the content, please contact the

original document maintainer directly.  However, if you have a problem

communicating in English you can also ask the Chinese maintainer for

help.  Contact the Chinese maintainer if this translation is outdated

or if there is a problem with the translation.

Chinese maintainer: 谢尚敬 <1479201451@qq.com>

---------------------------------------------------------------------

Documentation/ia64/IRQ-redir.txt的中文翻译

如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文

交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻

译存在问题,请联系中文版维护者。

中文版维护者: 谢尚敬 <1479201451@qq.com>

中文版翻译者: 谢尚敬 <1479201451@qq.com>

中文版校译者: 谢尚敬 <1479201451@qq.com>

以下为正文

---------------------------------------------------------------------

 

IRQ affinity on IA64 platforms

IRQ在 IA64 平台上的兼容性:

   ------------------------------

                              07.01.2002, Erich Focht <efocht@ess.nec.de>

  

  

   By writing to /proc/irq/IRQ#/smp_affinity the interrupt routing can be controlled. The behavior on IA64 platforms is slightly different from that described in Documentation/IRQ-affinity.txt for
i386 systems.

通过向 /proc/irq/IRQ # 写入 / smp_affinity 可以控制中断的路径。其在IA64 平台上的行为,与它在i386系统中的文件/IRQ-affinity.txt ,所描述略有不同。

 

Because of the usage of SAPIC mode and physical destination mode the IRQ target is one particular CPU and cannot be a mask of several CPUs. Only the first non-zero bit is taken into account.

由于 SAPIC 模式和物理目标模式 IRQ 的使用目标,是一个特定的 CPU,不能作为多个CPU的掩码。只有第一个非零字节才会被考虑在内。

 

  Usage examples:

  用法示例:

 

  The target CPU has to be specified as a hexadecimal CPU mask. The first non-zero bit is the selected CPU. This format has been kept for compatibility reasons with i386.

目标 CPU 必须被指定为一个十六进制的CPU 掩码。非零的第一位是所选的 CPU。出于兼容性原因,这种格式将会一直伴随i386。

 

 

Set the delivery mode of interrupt 41 to fixed and route the interrupts to CPU #3 (logical CPU number) (2^3=0x08):

设置中断 41 的传输模式为固定,并且将中断的路由设置为 CPU #3 (逻辑 CPU 数) (2 ^3 = 0x08):

 

       echo "8" >/proc/irq/41/smp_affinity

 

  Set the default route for IRQ number 41 to CPU 6 in lowest priority delivery mode (redirectable):

将第41个IRQ 的默认路由设置为,最低优先级的CPU 6交付模式 (重定向):

 

       echo "r 40" >/proc/irq/41/smp_affinity

 

  The output of the command

控制的输出:

       cat /proc/irq/IRQ#/smp_affinity

  gives the target CPU mask for the specified interrupt vector. If the CPU mask is preceded by the character "r", the interrupt is redirectable (i.e. lowest priority mode routing is used), otherwise
its route is fixed.

     
把指定的中断矢量给目标 CPU 掩码。如果 CPU 掩码之前的字符是"r",那么中断便是重定向的(即最低优先模式使用路由),否则它的路线就是固定的。

 

 

 

  Initialization and default behavior:

  初始化和默认行为:

 

  If the platform features IRQ redirection (info provided by SAL) all IO-SAPIC interrupts are initialized with CPU#0 as their default target and the routing is the so called "lowest priority mode"
(actually fixed SAPIC mode with hint). The XTP chipset registers are used as hints for the IRQ routing. Currently in Linux XTP registers can have three values:

          - minimal for an idle task,

          - normal if any other task runs,

          - maximal if the CPU is going to be switched off.

如果平台上是,各种功能的IRQ 重定向 (SAL 所提供的信息),那么所有的IO SAPIC中断,都将初始化为 CPU #0 ,并且以此作为,其所谓的默认目标和路由的"最低优先模式"(实际上是带有提示的固定 SAPIC 模式)。作为提示,IRQ 路由被用在 XTP 芯片组寄存器上。目前 Linux XTP 寄存器可以有三个值:

-最小的空闲任务,

-运行任何其他任务时正常,

-CPU就要关掉时达到最大。

 

The IRQ is routed to the CPU with lowest XTP register value, the search begins at the default CPU. Therefore most of the interrupts will be handled by CPU #0.

     
IRQ 路由到 CPU 与最低 XTP 寄存器值、 默认 CPU 从开始搜索。因此大部分的中断将由 CPU #0 处理。

 

If the platform doesn't feature interrupt redirection IOSAPIC fixed routing is used. The target CPUs are distributed in a round robin manner. IRQs will be routed only to the selected target CPUs.
Check with

若该平台没有中断属性,则使用重定向的IOSAPIC 固定路由。Cpu的目标将以循环赛的方式进行分布。IRQ将只由选定目标的Cpu来路由。请检查

 

          cat /proc/interrupts

 

  Comments:

  评论:

 

On large (multi-node) systems it is recommended to route the IRQs to the node to which the corresponding device is connected. For systems like the NEC AzusA we get IRQ node-affinity for free. This
is because usually the chipsets on each node redirect the interrupts only to their own CPUs (as they cannot see the XTP registers on the other nodes).

     
建议大 (多节点) 的系统上能将 Irq 路由到相应设备所连接到的节点上。对于像 NEC
AzusA
这样的系统,我们可以免费获得 IRQ 节点关联。这是因为 (因为他们看不到其他节点上注册 XTP) 每个节点上的芯片组,通常只定向到他们自己 Cpu 的中断。

 

原文地址:http://lxr.linux.no/#linux+v3.11.6/Documentation/ia64/IRQ-redir.txt

抱歉!评论已关闭.