/** @file
The driver binding for UEFI PXEBC protocol.
Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
#include "PxeBcImpl.h"
0xa,
NULL,
};
/**
This is the declaration of an EFI image entry point. This entry point is
the same for UEFI Applications, UEFI OS Loaders, and UEFI Drivers including
both device drivers and bus drivers.
@param ImageHandle The firmware allocated handle for the UEFI image.
@param SystemTable A pointer to the EFI System Table.
@retval EFI_SUCCESS The operation completed successfully.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
**/
)
{
);
}
/**
Test to see if this driver supports ControllerHandle. This service
is called by the EFI boot service ConnectController(). In
order to make drivers as small as possible, there are a few calling
restrictions for this service. ConnectController() must
follow these calling restrictions. If any other agent wishes to call
Supported() it must also follow these calling restrictions.
PxeBc requires DHCP4 and MTFTP4 protocols.
@param This Protocol instance pointer.
@param ControllerHandle Handle of device to test
@param RemainingDevicePath Optional parameter use to pick a specific child
device to start.
@retval EFI_SUCCESS This driver supports this device
@retval EFI_ALREADY_STARTED This driver is already running on this device
@retval other This driver does not support this device
**/
)
{
);
return EFI_ALREADY_STARTED;
}
NULL,
);
NULL,
);
}
return Status;
}
/**
Start this driver on ControllerHandle. This service is called by the
EFI boot service ConnectController(). In order to make
drivers as small as possible, there are a few calling restrictions for
this service. ConnectController() must follow these
calling restrictions. If any other agent wishes to call Start() it
must also follow these calling restrictions.
@param This Protocol instance pointer.
@param ControllerHandle Handle of device to bind driver to
@param RemainingDevicePath Optional parameter use to pick a specific child
device to start.
@retval EFI_SUCCESS This driver is added to ControllerHandle
@retval EFI_ALREADY_STARTED This driver is already running on ControllerHandle
@retval other This driver does not support this device
**/
)
{
return EFI_OUT_OF_RESOURCES;
}
}
//
// Get the NII interface if it exists.
//
);
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
//
// Get max packet size from Ip4 to calculate block size for Tftp later.
//
goto ON_ERROR;
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
//
// The UDP instance for EfiPxeBcUdpRead
//
);
goto ON_ERROR;
}
//
// The UDP instance for EfiPxeBcUdpWrite
//
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
);
goto ON_ERROR;
}
return EFI_SUCCESS;
gBS->CloseProtocol (
);
);
}
gBS->CloseProtocol (
);
);
}
gBS->CloseProtocol (
);
);
}
gBS->CloseProtocol (
);
);
}
gBS->CloseProtocol (
);
);
}
gBS->CloseProtocol (
);
);
}
return Status;
}
/**
Stop this driver on ControllerHandle. This service is called by the
EFI boot service DisconnectController(). In order to
make drivers as small as possible, there are a few calling
restrictions for this service. DisconnectController()
must follow these calling restrictions. If any other agent wishes
to call Stop() it must also follow these calling restrictions.
@param This Protocol instance pointer.
@param ControllerHandle Handle of device to stop driver on
@param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of
children is zero stop the entire bus driver.
@param ChildHandleBuffer List of Child Handles to Stop.
@retval EFI_SUCCESS This driver is removed ControllerHandle
@retval other This driver was not removed from this device
**/
)
{
return EFI_DEVICE_ERROR;
}
}
}
}
}
);
return Status;
}
//
// Stop functionality of PXE Base Code protocol
//
return Status;
}
);
gBS->CloseProtocol (
);
);
gBS->CloseProtocol (
);
);
gBS->CloseProtocol (
);
);
gBS->CloseProtocol (
);
);
gBS->CloseProtocol (
);
);
gBS->CloseProtocol (
);
);
}
return Status;
}