Skip to content

Commit 11c7ff1

Browse files
committed
xen/grant-table: Force to use v1 of grants.
We have the framework to use v2, but there are no backends that actually use it. The end result is that on PV we use v2 grants and on PVHVM v1. The v1 has a capacity of 512 grants per page while the v2 has 256 grants per page. This means we lose about 50% capacity - and if we want more than 16 VIFs (each VIF takes 512 grants), then we are hitting the max per guest of 32. Oracle-bug: 16039922 CC: annie.li@oracle.com CC: msw@amazon.com Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Reviewed-by: David Vrabel <david.vrabel@citrix.com>
1 parent 4e903a2 commit 11c7ff1

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

‎drivers/xen/grant-table.c‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1184,10 +1184,8 @@ static void gnttab_request_version(void)
11841184
int rc;
11851185
struct gnttab_set_version gsv;
11861186

1187-
if (xen_feature(XENFEAT_auto_translated_physmap))
1188-
gsv.version = 1;
1189-
else
1190-
gsv.version = 2;
1187+
gsv.version = 1;
1188+
11911189
rc = HYPERVISOR_grant_table_op(GNTTABOP_set_version, &gsv, 1);
11921190
if (rc == 0 && gsv.version == 2) {
11931191
grant_table_version = 2;

0 commit comments

Comments
 (0)