Commit a82b264
Peter Zijlstra (Intel)
x86/its: explicitly manage permissions for ITS pages
execmem_alloc() sets permissions differently depending on the kernel
configuration, CPU support for PSE and whether a page is allocated
before or after mark_rodata_ro().
Add tracking for pages allocated for ITS when patching the core kernel
and make sure the permissions for ITS pages are explicitly managed for
both kernel and module allocations.
Fixes: 872df34 ("x86/its: Use dynamic thunks for indirect branches")
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Co-developed-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Nikolay Borisov <nik.borisov@suse.com>
Cc: stable@vger.kernel.org
Link: https://lkml.kernel.org/r/20250603111446.2609381-5-rppt@kernel.org1 parent 0b0cae7 commit a82b264
1 file changed
+52
-22
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
116 | 116 | | |
117 | 117 | | |
118 | 118 | | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
119 | 137 | | |
120 | 138 | | |
121 | 139 | | |
| |||
151 | 169 | | |
152 | 170 | | |
153 | 171 | | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
154 | 187 | | |
155 | 188 | | |
156 | 189 | | |
| |||
173 | 206 | | |
174 | 207 | | |
175 | 208 | | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
| 209 | + | |
| 210 | + | |
180 | 211 | | |
181 | 212 | | |
182 | 213 | | |
| |||
194 | 225 | | |
195 | 226 | | |
196 | 227 | | |
197 | | - | |
| 228 | + | |
| 229 | + | |
198 | 230 | | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
199 | 237 | | |
200 | 238 | | |
201 | 239 | | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
213 | 243 | | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
| 244 | + | |
219 | 245 | | |
220 | 246 | | |
221 | 247 | | |
| |||
269 | 295 | | |
270 | 296 | | |
271 | 297 | | |
272 | | - | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
273 | 301 | | |
274 | 302 | | |
275 | 303 | | |
| |||
2339 | 2367 | | |
2340 | 2368 | | |
2341 | 2369 | | |
| 2370 | + | |
| 2371 | + | |
2342 | 2372 | | |
2343 | 2373 | | |
2344 | 2374 | | |
| |||
0 commit comments