[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [win-pv-devel] [PATCH 1/7] Make interface exposure explicit
Add pass-through query for XenBus's Cache interface and account for interface versions when determining the revision(s). Do not pass through any other queries, as the revision is not accounted for. Signed-off-by: Owen Smith <owen.smith@xxxxxxxxxx> --- src/xenvif/pdo.c | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/src/xenvif/pdo.c b/src/xenvif/pdo.c index c07c66e..90c08e9 100644 --- a/src/xenvif/pdo.c +++ b/src/xenvif/pdo.c @@ -547,7 +547,7 @@ __PdoSetRevisions( IN PXENVIF_PDO Pdo ) { - ULONG Vif; + ULONG Cache; ULONG Revision; NTSTATUS status; @@ -559,15 +559,20 @@ __PdoSetRevisions( // even when a particular combination of interface versions becomes // unsupported. (See README.md for API versioning policy). - for (Vif = 1; Vif <= XENVIF_VIF_INTERFACE_VERSION_MAX; Vif++) { - Revision++; + for (Cache = 1; Cache <= XENBUS_CACHE_INTERFACE_VERSION_MAX; Cache++) { + ULONG Vif; - if (Vif >= XENVIF_VIF_INTERFACE_VERSION_MIN) { - status = __PdoAddRevision(Pdo, Revision); - if (!NT_SUCCESS(status)) - goto fail1; + for (Vif = 1; Vif <= XENVIF_VIF_INTERFACE_VERSION_MAX; Vif++) { + Revision++; + + if (Vif >= XENVIF_VIF_INTERFACE_VERSION_MIN && + Cache >= XENBUS_CACHE_INTERFACE_VERSION_MIN) { + status = __PdoAddRevision(Pdo, Revision); + if (!NT_SUCCESS(status)) + goto fail1; + } } - } + } ASSERT(Pdo->Count > 0); return STATUS_SUCCESS; @@ -1543,6 +1548,7 @@ struct _INTERFACE_ENTRY { struct _INTERFACE_ENTRY PdoInterfaceTable[] = { { &GUID_BUS_INTERFACE_STANDARD, "BUS_INTERFACE", PdoQueryBusInterface }, { &GUID_XENVIF_VIF_INTERFACE, "VIF_INTERFACE", PdoQueryVifInterface }, + { &GUID_XENBUS_CACHE_INTERFACE, "CACHE_INTERFACE", __PdoDelegateIrp }, { NULL, NULL, NULL } }; @@ -1578,8 +1584,6 @@ PdoQueryInterface( } } - status = __PdoDelegateIrp(Pdo, Irp); - done: Irp->IoStatus.Status = status; IoCompleteRequest(Irp, IO_NO_INCREMENT); -- 1.9.4.msysgit.1 _______________________________________________ win-pv-devel mailing list win-pv-devel@xxxxxxxxxxxxxxxxxxxx http://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |