Class SDRAMDeAlloc
java.lang.Object
uk.ac.manchester.spinnaker.messages.sdp.SpinnakerRequest
uk.ac.manchester.spinnaker.messages.scp.SCPRequest<SDRAMDeAlloc.Response>
uk.ac.manchester.spinnaker.messages.scp.SDRAMDeAlloc
- All Implemented Interfaces:
SerializableMessage
public class SDRAMDeAlloc extends SCPRequest<SDRAMDeAlloc.Response>
A request to free space in the SDRAM. The response payload is the number
of blocks that were deallocated.
Calls cmd_alloc()
(and hence sark_xfree()
or
sark_xfree_id()
) in scamp-cmd.c
.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected class
SDRAMDeAlloc.Response
An SCP response to a request to deallocate SDRAM. -
Field Summary
Fields inherited from class uk.ac.manchester.spinnaker.messages.scp.SCPRequest
argument1, argument2, argument3, BOOT_CHIP, BOOT_MONITOR_CORE, data, NO_DATA, scpRequestHeader
-
Constructor Summary
Constructors Constructor Description SDRAMDeAlloc(HasChipLocation chip, MemoryLocation baseAddress)
Free a block of memory of known size.SDRAMDeAlloc(HasChipLocation chip, AppID appID)
Free the memory associated with a given application ID. -
Method Summary
Modifier and Type Method Description SDRAMDeAlloc.Response
getSCPResponse(ByteBuffer buffer)
Parse the response to this message.Methods inherited from class uk.ac.manchester.spinnaker.messages.sdp.SpinnakerRequest
getMessageData
-
Constructor Details
-
SDRAMDeAlloc
Free the memory associated with a given application ID.- Parameters:
chip
- The chip to deallocate on.appID
- The ID of the application.
-
SDRAMDeAlloc
Free a block of memory of known size.- Parameters:
chip
- The chip to deallocate on.baseAddress
- The start address in SDRAM of the block that needs to be deallocated.
-
-
Method Details
-
getSCPResponse
public SDRAMDeAlloc.Response getSCPResponse(ByteBuffer buffer) throws UnexpectedResponseCodeException, MemoryAllocationFailedExceptionDescription copied from class:SCPRequest
Parse the response to this message.- Specified by:
getSCPResponse
in classSCPRequest<SDRAMDeAlloc.Response>
- Parameters:
buffer
- The buffer to parse.- Returns:
- The message response.
- Throws:
UnexpectedResponseCodeException
MemoryAllocationFailedException
-