aboutsummaryrefslogtreecommitdiffstats
path: root/Demos/Device/ClassDriver/MassStorage/Lib
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2009-06-28 13:39:08 +0000
committerDean Camera <dean@fourwalledcubicle.com>2009-06-28 13:39:08 +0000
commitf1076ac4d6e56bff7fb6d2126746af1108211370 (patch)
tree9a5f31cc5ff9c648d7ce63f1d9e8afab763d2801 /Demos/Device/ClassDriver/MassStorage/Lib
parent3cbdcd36868693cfc1863231a1ec64507ce3d29f (diff)
downloadlufa-f1076ac4d6e56bff7fb6d2126746af1108211370.tar.gz
lufa-f1076ac4d6e56bff7fb6d2126746af1108211370.tar.bz2
lufa-f1076ac4d6e56bff7fb6d2126746af1108211370.zip
Added const modifiers to device mode class drivers.
Added parameter directions to function parameter documentation. Added new experimental FAST_STREAM_FUNCTIONS compile time option to speed up stream transfers at the expense of a higher FLASH consumption (needs testing to verify improved throughput).
Diffstat (limited to 'Demos/Device/ClassDriver/MassStorage/Lib')
-rw-r--r--Demos/Device/ClassDriver/MassStorage/Lib/DataflashManager.c24
-rw-r--r--Demos/Device/ClassDriver/MassStorage/Lib/SCSI.c14
-rw-r--r--Demos/Device/ClassDriver/MassStorage/Lib/SCSI.h6
3 files changed, 22 insertions, 22 deletions
diff --git a/Demos/Device/ClassDriver/MassStorage/Lib/DataflashManager.c b/Demos/Device/ClassDriver/MassStorage/Lib/DataflashManager.c
index 5b5a2bd90..326f66024 100644
--- a/Demos/Device/ClassDriver/MassStorage/Lib/DataflashManager.c
+++ b/Demos/Device/ClassDriver/MassStorage/Lib/DataflashManager.c
@@ -43,9 +43,9 @@
* the pre-selected data OUT endpoint. This routine reads in OS sized blocks from the endpoint and writes
* them to the dataflash in Dataflash page sized blocks.
*
- * \param MSInterfaceInfo Pointer to a Mass Storage class state structure for the Mass Storage interface being used
- * \param BlockAddress Data block starting address for the write sequence
- * \param TotalBlocks Number of blocks of data to write
+ * \param[in] MSInterfaceInfo Pointer to a Mass Storage class state structure for the Mass Storage interface being used
+ * \param[in] BlockAddress Data block starting address for the write sequence
+ * \param[in] TotalBlocks Number of blocks of data to write
*/
void DataflashManager_WriteBlocks(USB_ClassInfo_MS_Device_t* MSInterfaceInfo, const uint32_t BlockAddress, uint16_t TotalBlocks)
{
@@ -169,9 +169,9 @@ void DataflashManager_WriteBlocks(USB_ClassInfo_MS_Device_t* MSInterfaceInfo, co
* the pre-selected data IN endpoint. This routine reads in Dataflash page sized blocks from the Dataflash
* and writes them in OS sized blocks to the endpoint.
*
- * \param MSInterfaceInfo Pointer to a Mass Storage class state structure for the Mass Storage interface being used
- * \param BlockAddress Data block starting address for the read sequence
- * \param TotalBlocks Number of blocks of data to read
+ * \param[in] MSInterfaceInfo Pointer to a Mass Storage class state structure for the Mass Storage interface being used
+ * \param[in] BlockAddress Data block starting address for the read sequence
+ * \param[in] TotalBlocks Number of blocks of data to read
*/
void DataflashManager_ReadBlocks(USB_ClassInfo_MS_Device_t* MSInterfaceInfo, const uint32_t BlockAddress, uint16_t TotalBlocks)
{
@@ -273,9 +273,9 @@ void DataflashManager_ReadBlocks(USB_ClassInfo_MS_Device_t* MSInterfaceInfo, con
* dataflash in Dataflash page sized blocks. This can be linked to FAT libraries to write files to the
* dataflash.
*
- * \param BlockAddress Data block starting address for the write sequence
- * \param TotalBlocks Number of blocks of data to write
- * \param BufferPtr Pointer to the data source RAM buffer
+ * \param[in] BlockAddress Data block starting address for the write sequence
+ * \param[in] TotalBlocks Number of blocks of data to write
+ * \param[in] BufferPtr Pointer to the data source RAM buffer
*/
void DataflashManager_WriteBlocks_RAM(const uint32_t BlockAddress, uint16_t TotalBlocks, uint8_t* BufferPtr)
{
@@ -365,9 +365,9 @@ void DataflashManager_WriteBlocks_RAM(const uint32_t BlockAddress, uint16_t Tota
* and writes them in OS sized blocks to the given buffer. This can be linked to FAT libraries to read
* the files stored on the dataflash.
*
- * \param BlockAddress Data block starting address for the read sequence
- * \param TotalBlocks Number of blocks of data to read
- * \param BufferPtr Pointer to the data destination RAM buffer
+ * \param[in] BlockAddress Data block starting address for the read sequence
+ * \param[in] TotalBlocks Number of blocks of data to read
+ * \param[out] BufferPtr Pointer to the data destination RAM buffer
*/
void DataflashManager_ReadBlocks_RAM(const uint32_t BlockAddress, uint16_t TotalBlocks, uint8_t* BufferPtr)
{
diff --git a/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.c b/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.c
index 4e6c05013..08f11b7d6 100644
--- a/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.c
+++ b/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.c
@@ -84,7 +84,7 @@ SCSI_Request_Sense_Response_t SenseData =
* to the appropriate SCSI command handling routine if the issued command is supported by the device, else it returns
* a command failure due to a ILLEGAL REQUEST.
*
- * \param MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
+ * \param[in] MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
*/
bool SCSI_DecodeSCSICommand(USB_ClassInfo_MS_Device_t* MSInterfaceInfo)
{
@@ -142,7 +142,7 @@ bool SCSI_DecodeSCSICommand(USB_ClassInfo_MS_Device_t* MSInterfaceInfo)
/** Command processing for an issued SCSI INQUIRY command. This command returns information about the device's features
* and capabilities to the host.
*
- * \param MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
+ * \param[in] MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
*
* \return Boolean true if the command completed successfully, false otherwise.
*/
@@ -184,7 +184,7 @@ static bool SCSI_Command_Inquiry(USB_ClassInfo_MS_Device_t* MSInterfaceInfo)
/** Command processing for an issued SCSI REQUEST SENSE command. This command returns information about the last issued command,
* including the error code and additional error information so that the host can determine why a command failed to complete.
*
- * \param MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
+ * \param[in] MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
*
* \return Boolean true if the command completed successfully, false otherwise.
*/
@@ -208,7 +208,7 @@ static bool SCSI_Command_Request_Sense(USB_ClassInfo_MS_Device_t* MSInterfaceInf
/** Command processing for an issued SCSI READ CAPACITY (10) command. This command returns information about the device's capacity
* on the selected Logical Unit (drive), as a number of OS-sized blocks.
*
- * \param MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
+ * \param[in] MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
*
* \return Boolean true if the command completed successfully, false otherwise.
*/
@@ -231,7 +231,7 @@ static bool SCSI_Command_Read_Capacity_10(USB_ClassInfo_MS_Device_t* MSInterface
* board, and indicates if they are present and functioning correctly. Only the Self-Test portion of the diagnostic command is
* supported.
*
- * \param MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
+ * \param[in] MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
*
* \return Boolean true if the command completed successfully, false otherwise.
*/
@@ -296,8 +296,8 @@ static bool SCSI_Command_Send_Diagnostic(USB_ClassInfo_MS_Device_t* MSInterfaceI
* and total number of blocks to process, then calls the appropriate low-level dataflash routine to handle the actual
* reading and writing of the data.
*
- * \param MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
- * \param IsDataRead Indicates if the command is a READ (10) command or WRITE (10) command (DATA_READ or DATA_WRITE)
+ * \param[in] MSInterfaceInfo Pointer to the Mass Storage class interface structure that the command is associated with
+ * \param[in] IsDataRead Indicates if the command is a READ (10) command or WRITE (10) command (DATA_READ or DATA_WRITE)
*
* \return Boolean true if the command completed successfully, false otherwise.
*/
diff --git a/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.h b/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.h
index bf61d8edc..052f908cd 100644
--- a/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.h
+++ b/Demos/Device/ClassDriver/MassStorage/Lib/SCSI.h
@@ -53,9 +53,9 @@
* is for convenience, as it allows for all three sense values (returned upon request to the host to give information about
* the last command failure) in a quick and easy manner.
*
- * \param key New SCSI sense key to set the sense code to
- * \param acode New SCSI additional sense key to set the additional sense code to
- * \param aqual New SCSI additional sense key qualifier to set the additional sense qualifier code to
+ * \param[in] key New SCSI sense key to set the sense code to
+ * \param[in] acode New SCSI additional sense key to set the additional sense code to
+ * \param[in] aqual New SCSI additional sense key qualifier to set the additional sense qualifier code to
*/
#define SCSI_SET_SENSE(key, acode, aqual) MACROS{ SenseData.SenseKey = key; \
SenseData.AdditionalSenseCode = acode; \