diff options
author | Dean Camera <[email protected]> | 2010-04-15 11:04:24 +0000 |
---|---|---|
committer | Dean Camera <[email protected]> | 2010-04-15 11:04:24 +0000 |
commit | 3eb81df998349e90c3d973e6301f19382c5b2e84 (patch) | |
tree | 400cfc27dfebf45ebcb0e66b453aaafab908d442 /LUFA/Drivers | |
parent | 5e14c194c9a2f5cb52a43f7efeacb795a38ced74 (diff) | |
download | qmk_firmware-3eb81df998349e90c3d973e6301f19382c5b2e84.tar.gz qmk_firmware-3eb81df998349e90c3d973e6301f19382c5b2e84.zip |
Rename FunctionAttributes.h to Attributes.h, as some attributes are applicable to variables also. Add new ATTR_NOINIT attribute for global variables.
Add the beginnings of a SDP implentation to the incomplete BluetoothHost demo.
Add const attribute to the Mass Storage Host driver functions where it was applicable, but missing.
Diffstat (limited to 'LUFA/Drivers')
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/MassStorage.c | 6 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/MassStorage.h | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/LUFA/Drivers/USB/Class/Host/MassStorage.c b/LUFA/Drivers/USB/Class/Host/MassStorage.c index 1b67ba2c37..4ec0b244f5 100644 --- a/LUFA/Drivers/USB/Class/Host/MassStorage.c +++ b/LUFA/Drivers/USB/Class/Host/MassStorage.c @@ -130,7 +130,7 @@ static uint8_t DComp_NextMSInterfaceEndpoint(void* const CurrentDescriptor) }
static uint8_t MS_Host_SendCommand(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo, MS_CommandBlockWrapper_t* const SCSICommandBlock,
- void* BufferPtr)
+ const void* const BufferPtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -152,7 +152,7 @@ static uint8_t MS_Host_SendCommand(USB_ClassInfo_MS_Host_t* const MSInterfaceInf Pipe_Freeze();
if ((BufferPtr != NULL) &&
- ((ErrorCode = MS_Host_SendReceiveData(MSInterfaceInfo, SCSICommandBlock, BufferPtr)) != PIPE_RWSTREAM_NoError))
+ ((ErrorCode = MS_Host_SendReceiveData(MSInterfaceInfo, SCSICommandBlock, (void*)BufferPtr)) != PIPE_RWSTREAM_NoError))
{
Pipe_Freeze();
return ErrorCode;
@@ -557,7 +557,7 @@ uint8_t MS_Host_ReadDeviceBlocks(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo, }
uint8_t MS_Host_WriteDeviceBlocks(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo, const uint8_t LUNIndex, const uint32_t BlockAddress,
- const uint8_t Blocks, const uint16_t BlockSize, void* BlockBuffer)
+ const uint8_t Blocks, const uint16_t BlockSize, const void* BlockBuffer)
{
if ((USB_HostState != HOST_STATE_Configured) || !(MSInterfaceInfo->State.IsActive))
return HOST_SENDCONTROL_DeviceDisconnected;
diff --git a/LUFA/Drivers/USB/Class/Host/MassStorage.h b/LUFA/Drivers/USB/Class/Host/MassStorage.h index 3dbf64940c..d2ab970094 100644 --- a/LUFA/Drivers/USB/Class/Host/MassStorage.h +++ b/LUFA/Drivers/USB/Class/Host/MassStorage.h @@ -277,7 +277,7 @@ */
uint8_t MS_Host_WriteDeviceBlocks(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo, const uint8_t LUNIndex,
const uint32_t BlockAddress, const uint8_t Blocks, const uint16_t BlockSize,
- void* BlockBuffer) ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(6);
+ const void* BlockBuffer) ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(6);
/* Inline Functions: */
/** General management task for a given Mass Storage host class interface, required for the correct operation of
@@ -320,7 +320,7 @@ static uint8_t MS_Host_SendCommand(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo,
MS_CommandBlockWrapper_t* const SCSICommandBlock,
- void* BufferPtr);
+ const void* const BufferPtr);
static uint8_t MS_Host_WaitForDataReceived(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo);
static uint8_t MS_Host_SendReceiveData(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo,
MS_CommandBlockWrapper_t* const SCSICommandBlock, void* BufferPtr);
|