• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# hwi
2
3
4## Command Function
5
6This command is used to query information about interrupts.
7
8
9## Syntax
10
11hwi
12
13
14## Parameters
15
16None.
17
18
19## Usage Guidelines
20
21- Run **hwi** to display the interrupt IDs, count of interrupts, and registered interrupt names of the system.
22
23- If **LOSCFG_CPUP_INCLUDE_IRQ** is enabled, the interrupt handling time (ATime), CPU usage, and type of each interrupt are also displayed.
24
25
26## Example
27
28Run **hwi**.
29
30
31## Output
32
33- Interrupt information (**LOSCFG_CPUP_INCLUDE_IRQ** disabled):
34
35  ```
36  OHOS # hwi
37   InterruptNo     Count     Name
38          0:         0:
39          1:   1025641:
40          2:         0:
41         29:    824049:
42         37:         0:      rtc_alarm
43         38:        24:      uart_pl011
44         48:         3:      GPIO
45         59:         0:
46         62:       530:      MMC_IRQ
47         63:        70:      MMC_IRQ
48         64:       280:      ETH
49         67:        58:      tde
50         68:         0:      JPGE_0
51         69:         0:      IVE
52         70:         0:      VGS
53         72:         0:      VEDU_0
54         73:         0:      nnie0
55         74:         0:      nnie_gdc0
56         75:         0:      VPSS
57         76:         0:      VI_PROC0
58         77:         0:      JPEGD_0
59         83:     49455:      HIFB_SOFT_INT
60         87:         0:      AIO interrupt
61         88:         0:      VI_CAP0
62         89:         0:      MIPI_RX
63         90:     49455:      VO int
64         91:     49456:      HIFB Int
65         96:     17601:      MMC_IRQ
66        100:         0:      SPI_HI35XX
67        101:         0:      SPI_HI35XX
68        102:         0:      SPI_HI35XX
69  ```
70
71- Interrupt information (**LOSCFG_CPUP_INCLUDE_IRQ** enabled):
72
73  ```
74  OHOS # hwi
75   InterruptNo      Count  ATime(us)   CPUUSE  CPUUSE10s  CPUUSE1s   Mode Name
76            0:          0          0     0.0        0.0       0.0  normal
77            1:     937031          0     0.1        0.1       0.1  normal
78            2:          0          0     0.0        0.0       0.0  normal
79           29:     726166          5     0.54       0.57      0.59 normal
80           37:          0          0     0.0        0.0       0.0  normal rtc_alarm
81           38:         17          5     0.0        0.0       0.0  normal uart_pl011
82           48:          3          4     0.0        0.0       0.0  normal GPIO
83           59:          0          0     0.0        0.0       0.0  normal
84           62:        531          1     0.0        0.0       0.0  normal MMC_IRQ
85           63:         69          1     0.0        0.0       0.0  normal MMC_IRQ
86           64:        292          2     0.0        0.0       0.0  normal ETH
87           67:         54         76     0.0        0.0       0.0  shared tde
88           68:          0          0     0.0        0.0       0.0  shared JPGE_0
89           69:          0          0     0.0        0.0       0.0  shared IVE
90           70:          0          0     0.0        0.0       0.0  shared VGS
91           72:          0          0     0.0        0.0       0.0  shared VEDU_0
92           73:          0          0     0.0        0.0       0.0  shared nnie0
93           74:          0          0     0.0        0.0       0.0  shared nnie_gdc0
94           75:          0          0     0.0        0.0       0.0  shared VPSS
95           76:          0          0     0.0        0.0       0.0  shared VI_PROC0
96           77:          0          0     0.0        0.0       0.0  shared JPEGD_0
97           83:      45529          8     0.5        0.5       0.5  shared HIFB_SOFT_INT
98           87:          0          0     0.0        0.0       0.0  shared AIO interrupt
99           88:          0          0     0.0        0.0       0.0  shared VI_CAP0
100           89:          0          0     0.0        0.0       0.0  shared MIPI_RX
101           90:      45534         11     0.6        0.7       0.7  shared VO int
102           91:      45533          2     0.1        0.1       0.1  shared HIFB Int
103           96:      17383          2     0.0        0.0       0.0  normal MMC_IRQ
104          100:          0          0     0.0        0.0       0.0  normal SPI_HI35XX
105          101:          0          0     0.0        0.0       0.0  normal SPI_HI35XX
106          102:          0          0     0.0        0.0       0.0  normal SPI_HI35XX
107  ```
108
109**Table 1** Output description
110
111| Parameter| Description|
112| -------- | -------- |
113| InterruptNo | Interrupt number.|
114| Count | Number of interrupts.|
115| Name | Registered interrupt name.|
116| ATime | Interrupt handling time.|
117| CPUUSE | CPU usage.|
118| CPUUSE10s | CPU usage in the last 10s.|
119| CPUUSE1s | CPU usage in the last 1s.|
120| mode | Interrupt type, which can be any of the following:<br>- **normal**:   non-shared interrupt.<br>- **shared**: shared interrupt.|
121