Commit 0dddf20
watchdog/hardlockup: simplify perf event probe and remove per-cpu dependency
Simplify the hardlockup detector's probe path and remove its implicit
dependency on pinned per-cpu execution.
Refactor hardlockup_detector_event_create() to be stateless. Return the
created perf_event pointer to the caller instead of directly modifying the
per-cpu 'watchdog_ev' variable. This allows the probe path to safely
manage a temporary event without the risk of leaving stale pointers should
task migration occur.
Link: https://lkml.kernel.org/r/20260129022629.2201331-1-realwujing@gmail.com
Signed-off-by: Shouxin Sun <sunshx@chinatelecom.cn>
Signed-off-by: Junnan Zhang <zhangjn11@chinatelecom.cn>
Signed-off-by: Qiliang Yuan <yuanql9@chinatelecom.cn>
Signed-off-by: Qiliang Yuan <realwujing@gmail.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Cc: Jinchao Wang <wangjinchao600@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Li Huafei <lihuafei1@huawei.com>
Cc: Song Liu <song@kernel.org>
Cc: Thorsten Blum <thorsten.blum@linux.dev>
Cc: Wang Jinchao <wangjinchao600@gmail.com>
Cc: Yicong Yang <yangyicong@hisilicon.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>1 parent 76149d5 commit 0dddf20
1 file changed
Lines changed: 28 additions & 22 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
118 | 118 | | |
119 | 119 | | |
120 | 120 | | |
121 | | - | |
| 121 | + | |
122 | 122 | | |
123 | | - | |
124 | 123 | | |
125 | 124 | | |
126 | 125 | | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | 126 | | |
134 | 127 | | |
135 | 128 | | |
| |||
143 | 136 | | |
144 | 137 | | |
145 | 138 | | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
| 139 | + | |
154 | 140 | | |
155 | 141 | | |
156 | 142 | | |
| |||
159 | 145 | | |
160 | 146 | | |
161 | 147 | | |
| 148 | + | |
| 149 | + | |
162 | 150 | | |
163 | 151 | | |
164 | | - | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
165 | 156 | | |
| 157 | + | |
166 | 158 | | |
167 | 159 | | |
168 | 160 | | |
169 | 161 | | |
170 | 162 | | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
171 | 166 | | |
172 | | - | |
| 167 | + | |
173 | 168 | | |
174 | 169 | | |
175 | 170 | | |
| |||
263 | 258 | | |
264 | 259 | | |
265 | 260 | | |
| 261 | + | |
| 262 | + | |
266 | 263 | | |
267 | 264 | | |
268 | 265 | | |
269 | 266 | | |
270 | 267 | | |
271 | | - | |
| 268 | + | |
| 269 | + | |
272 | 270 | | |
273 | | - | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
274 | 278 | | |
| 279 | + | |
275 | 280 | | |
276 | | - | |
277 | | - | |
| 281 | + | |
| 282 | + | |
278 | 283 | | |
| 284 | + | |
279 | 285 | | |
280 | 286 | | |
281 | 287 | | |
| |||
0 commit comments