TianoCore EDK2 master
|
#include <Library/PrintLib.h>
#include "XenBus.h"
#include "GrantTable.h"
#include "XenStore.h"
#include "EventChannel.h"
#include <IndustryStandard/Xen/io/xenbus.h>
Go to the source code of this file.
Functions | |
STATIC XENBUS_PRIVATE_DATA * | XenBusDeviceInitialized (IN XENBUS_DEVICE *Dev, IN CONST CHAR8 *Node) |
STATIC XenbusState | XenBusReadDriverState (IN CONST CHAR8 *Path) |
STATIC EFI_STATUS | XenBusAddDevice (XENBUS_DEVICE *Dev, CONST CHAR8 *Type, CONST CHAR8 *Id) |
STATIC VOID | XenBusEnumerateDeviceType (XENBUS_DEVICE *Dev, CONST CHAR8 *Type) |
XENSTORE_STATUS | XenBusEnumerateBus (XENBUS_DEVICE *Dev) |
STATIC XENSTORE_STATUS EFIAPI | XenBusSetState (IN XENBUS_PROTOCOL *This, IN CONST XENSTORE_TRANSACTION *Transaction, IN enum xenbus_state NewState) |
Variables | |
STATIC XENBUS_PRIVATE_DATA | gXenBusPrivateData |
STATIC XENBUS_DEVICE_PATH | gXenBusDevicePathTemplate |
XenBus Bus driver implementation.
This file implement the necessary to discover and enumerate Xen PV devices through XenStore.
Copyright (C) 2010 Spectra Logic Corporation Copyright (C) 2008 Doug Rabson Copyright (C) 2005 Rusty Russell, IBM Corporation Copyright (C) 2005 Mike Wray, Hewlett-Packard Copyright (C) 2005 XenSource Ltd Copyright (C) 2014, Citrix Ltd.
This file may be distributed separately from the Linux kernel, or incorporated into other software packages, subject to the following license:
SPDX-License-Identifier: MIT
Definition in file XenBus.c.
STATIC EFI_STATUS XenBusAddDevice | ( | XENBUS_DEVICE * | Dev, |
CONST CHAR8 * | Type, | ||
CONST CHAR8 * | Id | ||
) |
STATIC XENBUS_PRIVATE_DATA * XenBusDeviceInitialized | ( | IN XENBUS_DEVICE * | Dev, |
IN CONST CHAR8 * | Node | ||
) |
Search our internal record of configured devices (not the XenStore) to determine if the XenBus device indicated by Node is known to the system.
Dev | The XENBUS_DEVICE instance to search for device children. |
Node | The XenStore node path for the device to find. |
XENSTORE_STATUS XenBusEnumerateBus | ( | XENBUS_DEVICE * | Dev | ) |
Enumerate the devices on a XenBus bus and install a XenBus Protocol instance.
Caller should ensure that it is the only one to call this function. This function cannot be called concurrently.
Dev | A XENBUS_DEVICE instance. |
STATIC VOID XenBusEnumerateDeviceType | ( | XENBUS_DEVICE * | Dev, |
CONST CHAR8 * | Type | ||
) |
Enumerate all devices of the given type on this bus.
Dev | A XENBUS_DEVICE instance. |
Type | String indicating the device sub-tree (e.g. "vfb", "vif") to enumerate. |
Devices that are found are been initialize via XenBusAddDevice (). XenBusAddDevice () ignores duplicate detects and ignores duplicate devices, so it can be called unconditionally for any device found in the XenStore.
STATIC XENSTORE_STATUS EFIAPI XenBusSetState | ( | IN XENBUS_PROTOCOL * | This, |
IN CONST XENSTORE_TRANSACTION * | Transaction, | ||
IN enum xenbus_state | NewState | ||
) |
STATIC XENBUS_DEVICE_PATH gXenBusDevicePathTemplate |
STATIC XENBUS_PRIVATE_DATA gXenBusPrivateData |