diff options
| author | Dean <Dean@d5102386-fcda-11dd-9fdb-3debd5008f28> | 2010-07-19 14:00:44 +0000 |
|---|---|---|
| committer | Dean <Dean@d5102386-fcda-11dd-9fdb-3debd5008f28> | 2010-07-19 14:00:44 +0000 |
| commit | 09c2f28a83de2ae1fef0f6066a6dd976fc13e834 (patch) | |
| tree | 9ad7cfb13b684d5cdd0ed90703159b015f119734 /Projects/Webserver/Lib/SCSI.c | |
| parent | 7173a1463a48a4b1335f7281fd3609cd94692333 (diff) | |
Update makefiles to use the latest WinAVR/Atmel toolchain makefile template.
Add new module source variables to the library core makefile, so that module sources can be added to a project's makefile on a per-module rather than per-file basis.
git-svn-id: http://lufa-lib.googlecode.com/svn/trunk@1394 d5102386-fcda-11dd-9fdb-3debd5008f28
Diffstat (limited to 'Projects/Webserver/Lib/SCSI.c')
| -rw-r--r-- | Projects/Webserver/Lib/SCSI.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/Projects/Webserver/Lib/SCSI.c b/Projects/Webserver/Lib/SCSI.c index 7bb66d3b..cdc37c93 100644 --- a/Projects/Webserver/Lib/SCSI.c +++ b/Projects/Webserver/Lib/SCSI.c @@ -249,14 +249,8 @@ static void SCSI_Command_Send_Diagnostic(USB_ClassInfo_MS_Device_t* const MSInte */ static void SCSI_Command_ReadWrite_10(USB_ClassInfo_MS_Device_t* const MSInterfaceInfo, const bool IsDataRead) { - uint32_t BlockAddress; - uint16_t TotalBlocks; - - /* Load in the 32-bit block address (SCSI uses big-endian, so have to reverse the byte order) */ - BlockAddress = SwapEndian_32(*(uint32_t*)&MSInterfaceInfo->State.CommandBlock.SCSICommandData[2]); - - /* Load in the 16-bit total blocks (SCSI uses big-endian, so have to reverse the byte order) */ - TotalBlocks = SwapEndian_16(*(uint16_t*)&MSInterfaceInfo->State.CommandBlock.SCSICommandData[7]); + uint32_t BlockAddress = SwapEndian_32(*(uint32_t*)&MSInterfaceInfo->State.CommandBlock.SCSICommandData[2]); + uint16_t TotalBlocks = SwapEndian_16(*(uint16_t*)&MSInterfaceInfo->State.CommandBlock.SCSICommandData[7]); /* Check if the block address is outside the maximum allowable value for the LUN */ if (BlockAddress >= VIRTUAL_MEMORY_BLOCKS) |
