Commit 668aaaf
committed
vmm/linux/tee: Handle KVM_EXIT_HYPERCALL exits
SEV-SNP guests use KVM_EXIT_HYPERCALL exits to signal to the hypervisor
it would like some pages set to private or shared.
Implements a handler that manages guest memory and can set regions to
private or shared. vCPUs can send "memory properties" messages
to the handler indicating:
- Guest GPA
- Size of memory region
- Whether the region should be set to private or shared
The handler will read these messages and configure the memory regions
accordingly.
Signed-off-by: Tyler Fanelli <[email protected]>1 parent d70169f commit 668aaaf
File tree
6 files changed
+198
-7
lines changed- src
- libkrun
- src
- vmm
- src
- linux
6 files changed
+198
-7
lines changedSome generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
34 | 38 | | |
35 | 39 | | |
36 | 40 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
| 9 | + | |
8 | 10 | | |
9 | 11 | | |
10 | 12 | | |
| |||
20 | 22 | | |
21 | 23 | | |
22 | 24 | | |
23 | | - | |
| 25 | + | |
24 | 26 | | |
25 | 27 | | |
26 | 28 | | |
| |||
54 | 56 | | |
55 | 57 | | |
56 | 58 | | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
57 | 70 | | |
58 | 71 | | |
59 | 72 | | |
| |||
1454 | 1467 | | |
1455 | 1468 | | |
1456 | 1469 | | |
| 1470 | + | |
| 1471 | + | |
| 1472 | + | |
| 1473 | + | |
| 1474 | + | |
| 1475 | + | |
1457 | 1476 | | |
1458 | 1477 | | |
1459 | 1478 | | |
1460 | 1479 | | |
1461 | 1480 | | |
1462 | 1481 | | |
| 1482 | + | |
| 1483 | + | |
| 1484 | + | |
| 1485 | + | |
| 1486 | + | |
| 1487 | + | |
| 1488 | + | |
1463 | 1489 | | |
1464 | 1490 | | |
1465 | 1491 | | |
| |||
1468 | 1494 | | |
1469 | 1495 | | |
1470 | 1496 | | |
1471 | | - | |
| 1497 | + | |
1472 | 1498 | | |
1473 | 1499 | | |
1474 | 1500 | | |
| |||
1491 | 1517 | | |
1492 | 1518 | | |
1493 | 1519 | | |
| 1520 | + | |
| 1521 | + | |
| 1522 | + | |
| 1523 | + | |
| 1524 | + | |
| 1525 | + | |
| 1526 | + | |
| 1527 | + | |
| 1528 | + | |
| 1529 | + | |
| 1530 | + | |
| 1531 | + | |
| 1532 | + | |
| 1533 | + | |
| 1534 | + | |
| 1535 | + | |
| 1536 | + | |
| 1537 | + | |
| 1538 | + | |
| 1539 | + | |
| 1540 | + | |
| 1541 | + | |
| 1542 | + | |
| 1543 | + | |
| 1544 | + | |
| 1545 | + | |
| 1546 | + | |
| 1547 | + | |
| 1548 | + | |
| 1549 | + | |
| 1550 | + | |
| 1551 | + | |
| 1552 | + | |
| 1553 | + | |
| 1554 | + | |
| 1555 | + | |
| 1556 | + | |
| 1557 | + | |
| 1558 | + | |
| 1559 | + | |
| 1560 | + | |
| 1561 | + | |
| 1562 | + | |
| 1563 | + | |
| 1564 | + | |
| 1565 | + | |
| 1566 | + | |
| 1567 | + | |
| 1568 | + | |
| 1569 | + | |
| 1570 | + | |
| 1571 | + | |
| 1572 | + | |
| 1573 | + | |
| 1574 | + | |
| 1575 | + | |
| 1576 | + | |
| 1577 | + | |
| 1578 | + | |
| 1579 | + | |
| 1580 | + | |
| 1581 | + | |
| 1582 | + | |
| 1583 | + | |
| 1584 | + | |
| 1585 | + | |
| 1586 | + | |
| 1587 | + | |
| 1588 | + | |
| 1589 | + | |
| 1590 | + | |
| 1591 | + | |
| 1592 | + | |
| 1593 | + | |
| 1594 | + | |
| 1595 | + | |
| 1596 | + | |
| 1597 | + | |
| 1598 | + | |
| 1599 | + | |
| 1600 | + | |
| 1601 | + | |
| 1602 | + | |
| 1603 | + | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
1494 | 1607 | | |
1495 | 1608 | | |
1496 | 1609 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
8 | 12 | | |
9 | 13 | | |
10 | 14 | | |
| |||
21 | 25 | | |
22 | 26 | | |
23 | 27 | | |
| 28 | + | |
| 29 | + | |
24 | 30 | | |
25 | 31 | | |
26 | 32 | | |
| |||
507 | 513 | | |
508 | 514 | | |
509 | 515 | | |
| 516 | + | |
510 | 517 | | |
511 | 518 | | |
512 | 519 | | |
| |||
672 | 679 | | |
673 | 680 | | |
674 | 681 | | |
| 682 | + | |
| 683 | + | |
675 | 684 | | |
676 | 685 | | |
677 | 686 | | |
| |||
1419 | 1428 | | |
1420 | 1429 | | |
1421 | 1430 | | |
| 1431 | + | |
1422 | 1432 | | |
1423 | 1433 | | |
1424 | 1434 | | |
| |||
1429 | 1439 | | |
1430 | 1440 | | |
1431 | 1441 | | |
| 1442 | + | |
| 1443 | + | |
1432 | 1444 | | |
1433 | 1445 | | |
1434 | 1446 | | |
| |||
0 commit comments