diff options
author | Dean Camera <dean@fourwalledcubicle.com> | 2010-06-08 11:14:07 +0000 |
---|---|---|
committer | Dean Camera <dean@fourwalledcubicle.com> | 2010-06-08 11:14:07 +0000 |
commit | 5ce3f0b17bc927513bd980e8710f588564fe1dcc (patch) | |
tree | b3fda0c21445d827cc4ddc04e0ea1b9f4204d3af | |
parent | 96063b9f98c8201623f8c91ec5cbe3bb88aca6c3 (diff) | |
download | lufa-5ce3f0b17bc927513bd980e8710f588564fe1dcc.tar.gz lufa-5ce3f0b17bc927513bd980e8710f588564fe1dcc.tar.bz2 lufa-5ce3f0b17bc927513bd980e8710f588564fe1dcc.zip |
Add missing ATTR_NON_NULL_PTR_ARG and ATTR_ALWAYS_INLINE attributes to class driver functions.
-rw-r--r-- | LUFA/Drivers/USB/Class/Device/Audio.h | 24 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Device/CDC.h | 12 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Device/HID.h | 6 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Device/MIDI.h | 4 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/CDC.h | 9 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/MIDI.h | 4 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/MassStorage.h | 14 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/Printer.h | 8 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/RNDIS.h | 13 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Host/StillImage.h | 14 |
10 files changed, 63 insertions, 45 deletions
diff --git a/LUFA/Drivers/USB/Class/Device/Audio.h b/LUFA/Drivers/USB/Class/Device/Audio.h index 3586c33e8..b76abf663 100644 --- a/LUFA/Drivers/USB/Class/Device/Audio.h +++ b/LUFA/Drivers/USB/Class/Device/Audio.h @@ -135,7 +135,8 @@ * * \param[in,out] AudioInterfaceInfo Pointer to a structure containing an Audio Class configuration and state */ - static inline void Audio_Device_USBTask(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo); + static inline void Audio_Device_USBTask(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) + ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline void Audio_Device_USBTask(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) { (void)AudioInterfaceInfo; @@ -150,7 +151,9 @@ * \param[in,out] AudioInterfaceInfo Pointer to a structure containing an Audio Class configuration and state * * \return Boolean true if the given Audio interface has a sample to be read, false otherwise - */ + */ + static inline bool Audio_Device_IsSampleReceived(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) + ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline bool Audio_Device_IsSampleReceived(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) { if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled)) @@ -171,6 +174,8 @@ * \return Boolean true if the given Audio interface is ready to accept the next sample, false otherwise */ static inline bool Audio_Device_IsReadyForNextSample(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) + ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; + static inline bool Audio_Device_IsReadyForNextSample(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) { if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled)) return false; @@ -188,7 +193,8 @@ * * \return Signed 8-bit audio sample from the audio interface */ - static inline int8_t Audio_Device_ReadSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) ATTR_ALWAYS_INLINE; + static inline int8_t Audio_Device_ReadSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) + ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline int8_t Audio_Device_ReadSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) { int8_t Sample; @@ -212,7 +218,8 @@ * * \return Signed 16-bit audio sample from the audio interface */ - static inline int16_t Audio_Device_ReadSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) ATTR_ALWAYS_INLINE; + static inline int16_t Audio_Device_ReadSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) + ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline int16_t Audio_Device_ReadSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) { int16_t Sample; @@ -236,7 +243,8 @@ * * \return Signed 24-bit audio sample from the audio interface */ - static inline int32_t Audio_Device_ReadSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) ATTR_ALWAYS_INLINE; + static inline int32_t Audio_Device_ReadSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) + ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline int32_t Audio_Device_ReadSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo) { int32_t Sample; @@ -260,7 +268,7 @@ * \param[in] Sample Signed 8-bit audio sample */ static inline void Audio_Device_WriteSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, - const int8_t Sample) ATTR_ALWAYS_INLINE; + const int8_t Sample) ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline void Audio_Device_WriteSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, const int8_t Sample) { @@ -279,7 +287,7 @@ * \param[in] Sample Signed 16-bit audio sample */ static inline void Audio_Device_WriteSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, - const int16_t Sample) ATTR_ALWAYS_INLINE; + const int16_t Sample) ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline void Audio_Device_WriteSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, const int16_t Sample) { @@ -298,7 +306,7 @@ * \param[in] Sample Signed 24-bit audio sample */ static inline void Audio_Device_WriteSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, - const int32_t Sample) ATTR_ALWAYS_INLINE; + const int32_t Sample) ATTR_NON_NULL_PTR_ARG(1) ATTR_ALWAYS_INLINE; static inline void Audio_Device_WriteSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, const int32_t Sample) { diff --git a/LUFA/Drivers/USB/Class/Device/CDC.h b/LUFA/Drivers/USB/Class/Device/CDC.h index 278996f64..23b7b5c40 100644 --- a/LUFA/Drivers/USB/Class/Device/CDC.h +++ b/LUFA/Drivers/USB/Class/Device/CDC.h @@ -292,7 +292,8 @@ * \param[in,out] CDCInterfaceInfo Pointer to a structure containing a CDC Class configuration and state * \param[in,out] Stream Pointer to a FILE structure where the created stream should be placed */ - void CDC_Device_CreateStream(USB_ClassInfo_CDC_Device_t* CDCInterfaceInfo, FILE* Stream); + void CDC_Device_CreateStream(USB_ClassInfo_CDC_Device_t* CDCInterfaceInfo, FILE* Stream) + ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(2); /** Identical to CDC_Device_CreateStream(), except that reads are blocking until the calling stream function terminates * the transfer. While blocking, the USB and CDC service tasks are called repeatedly to maintain USB communications. @@ -300,15 +301,16 @@ * \param[in,out] CDCInterfaceInfo Pointer to a structure containing a CDC Class configuration and state * \param[in,out] Stream Pointer to a FILE structure where the created stream should be placed */ - void CDC_Device_CreateBlockingStream(USB_ClassInfo_CDC_Device_t* CDCInterfaceInfo, FILE* Stream); + void CDC_Device_CreateBlockingStream(USB_ClassInfo_CDC_Device_t* CDCInterfaceInfo, FILE* Stream) + ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(2); /* Private Interface - For use in library only: */ #if !defined(__DOXYGEN__) /* Function Prototypes: */ #if defined(__INCLUDE_FROM_CDC_CLASS_DEVICE_C) - static int CDC_Device_putchar(char c, FILE* Stream); - static int CDC_Device_getchar(FILE* Stream); - static int CDC_Device_getchar_Blocking(FILE* Stream); + static int CDC_Device_putchar(char c, FILE* Stream) ATTR_NON_NULL_PTR_ARG(2); + static int CDC_Device_getchar(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1); + static int CDC_Device_getchar_Blocking(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1); void CDC_Device_Event_Stub(void); void EVENT_CDC_Device_LineEncodingChanged(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo) diff --git a/LUFA/Drivers/USB/Class/Device/HID.h b/LUFA/Drivers/USB/Class/Device/HID.h index b3b67a9a4..d5194d12c 100644 --- a/LUFA/Drivers/USB/Class/Device/HID.h +++ b/LUFA/Drivers/USB/Class/Device/HID.h @@ -179,8 +179,8 @@ * \param[in] ReportSize Size in bytes of the received report from the host. */ void CALLBACK_HID_Device_ProcessHIDReport(USB_ClassInfo_HID_Device_t* const HIDInterfaceInfo, const uint8_t ReportID, - const uint8_t ReportType, const void* ReportData, const uint16_t ReportSize) ATTR_NON_NULL_PTR_ARG(1) - ATTR_NON_NULL_PTR_ARG(4); + const uint8_t ReportType, const void* ReportData, const uint16_t ReportSize) + ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(4); /* Inline Functions: */ /** Indicates that a millisecond of idle time has elapsed on the given HID interface, and the interface's idle count should be @@ -190,7 +190,7 @@ * * \param[in,out] HIDInterfaceInfo Pointer to a structure containing a HID Class configuration and state */ - static inline void HID_Device_MillisecondElapsed(USB_ClassInfo_HID_Device_t* HIDInterfaceInfo); + static inline void HID_Device_MillisecondElapsed(USB_ClassInfo_HID_Device_t* HIDInterfaceInfo) ATTR_ALWAYS_INLINE ATTR_NON_NULL_PTR_ARG(1); static inline void HID_Device_MillisecondElapsed(USB_ClassInfo_HID_Device_t* HIDInterfaceInfo) { if (HIDInterfaceInfo->State.IdleMSRemaining) diff --git a/LUFA/Drivers/USB/Class/Device/MIDI.h b/LUFA/Drivers/USB/Class/Device/MIDI.h index 45791f1a8..d9b67e275 100644 --- a/LUFA/Drivers/USB/Class/Device/MIDI.h +++ b/LUFA/Drivers/USB/Class/Device/MIDI.h @@ -135,7 +135,7 @@ * * \return A value from the \ref Endpoint_WaitUntilReady_ErrorCodes_t enum */ - uint8_t MIDI_Device_Flush(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo); + uint8_t MIDI_Device_Flush(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); /** Receives a MIDI event packet from the host. Events are unpacked from the endpoint, thus if the endpoint bank contains * multiple MIDI events from the host in the one packet, multiple calls to this function will return each individual event. @@ -157,7 +157,7 @@ * * \param[in,out] MIDIInterfaceInfo Pointer to a structure containing a MIDI Class configuration and state */ - static inline void MIDI_Device_USBTask(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo); + static inline void MIDI_Device_USBTask(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); static inline void MIDI_Device_USBTask(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo) { (void)MIDIInterfaceInfo; diff --git a/LUFA/Drivers/USB/Class/Host/CDC.h b/LUFA/Drivers/USB/Class/Host/CDC.h index 562d081aa..0f8807ed2 100644 --- a/LUFA/Drivers/USB/Class/Host/CDC.h +++ b/LUFA/Drivers/USB/Class/Host/CDC.h @@ -313,16 +313,17 @@ /* Function Prototypes: */ #if defined(__INCLUDE_FROM_CDC_CLASS_HOST_C) - static int CDC_Host_putchar(char c, FILE* Stream); - static int CDC_Host_getchar(FILE* Stream); - static int CDC_Host_getchar_Blocking(FILE* Stream); + static int CDC_Host_putchar(char c, FILE* Stream) ATTR_NON_NULL_PTR_ARG(2); + static int CDC_Host_getchar(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1); + static int CDC_Host_getchar_Blocking(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1); void CDC_Host_Event_Stub(void); void EVENT_CDC_Host_ControLineStateChanged(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo) ATTR_WEAK ATTR_NON_NULL_PTR_ARG(1) ATTR_ALIAS(CDC_Host_Event_Stub); + static uint8_t DCOMP_CDC_Host_NextCDCControlInterface(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); static uint8_t DCOMP_CDC_Host_NextCDCDataInterface(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); - static uint8_t DCOMP_CDC_Host_NextCDCInterfaceEndpoint(void* const CurrentDescriptor); + static uint8_t DCOMP_CDC_Host_NextCDCInterfaceEndpoint(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); #endif #endif diff --git a/LUFA/Drivers/USB/Class/Host/MIDI.h b/LUFA/Drivers/USB/Class/Host/MIDI.h index f1693af99..f7898709f 100644 --- a/LUFA/Drivers/USB/Class/Host/MIDI.h +++ b/LUFA/Drivers/USB/Class/Host/MIDI.h @@ -150,7 +150,7 @@ * * \return A value from the \ref Pipe_WaitUntilReady_ErrorCodes_t enum */ - uint8_t MIDI_Host_Flush(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceInfo); + uint8_t MIDI_Host_Flush(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); /** Receives a MIDI event packet from the device. * @@ -171,7 +171,7 @@ * * \param[in,out] MIDIInterfaceInfo Pointer to a structure containing an MIDI Class host configuration and state */ - static inline void MIDI_Host_USBTask(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceInfo); + static inline void MIDI_Host_USBTask(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); static inline void MIDI_Host_USBTask(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceInfo) { (void)MIDIInterfaceInfo; diff --git a/LUFA/Drivers/USB/Class/Host/MassStorage.h b/LUFA/Drivers/USB/Class/Host/MassStorage.h index 912ba5811..6c1f7f67f 100644 --- a/LUFA/Drivers/USB/Class/Host/MassStorage.h +++ b/LUFA/Drivers/USB/Class/Host/MassStorage.h @@ -315,17 +315,19 @@ /* Function Prototypes: */ #if defined(__INCLUDE_FROM_MS_CLASS_HOST_C) - static uint8_t DCOMP_MS_NextMSInterface(void* const CurrentDescriptor); - static uint8_t DCOMP_MS_NextMSInterfaceEndpoint(void* const CurrentDescriptor); + static uint8_t DCOMP_MS_NextMSInterface(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); + static uint8_t DCOMP_MS_NextMSInterfaceEndpoint(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); static uint8_t MS_Host_SendCommand(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo, MS_CommandBlockWrapper_t* const SCSICommandBlock, - const void* const BufferPtr); - static uint8_t MS_Host_WaitForDataReceived(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo); + const void* const BufferPtr) ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(2); + static uint8_t MS_Host_WaitForDataReceived(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); static uint8_t MS_Host_SendReceiveData(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo, - MS_CommandBlockWrapper_t* const SCSICommandBlock, void* BufferPtr); + MS_CommandBlockWrapper_t* const SCSICommandBlock, void* BufferPtr) + ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(2); static uint8_t MS_Host_GetReturnedStatus(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo, - MS_CommandStatusWrapper_t* const SCSICommandStatus); + MS_CommandStatusWrapper_t* const SCSICommandStatus) + ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(2); #endif #endif diff --git a/LUFA/Drivers/USB/Class/Host/Printer.h b/LUFA/Drivers/USB/Class/Host/Printer.h index 7cd7a1733..78b3f26b0 100644 --- a/LUFA/Drivers/USB/Class/Host/Printer.h +++ b/LUFA/Drivers/USB/Class/Host/Printer.h @@ -187,7 +187,7 @@ * \return A value from the \ref Pipe_Stream_RW_ErrorCodes_t enum */ uint8_t PRNT_Host_GetDeviceID(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo, char* DeviceIDString, - uint16_t BufferSize) ATTR_NON_NULL_PTR_ARG(1); + uint16_t BufferSize) ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(2); /* Inline Functions: */ /** General management task for a given Printer host class interface, required for the correct operation of @@ -196,7 +196,7 @@ * * \param[in,out] PRNTInterfaceInfo Pointer to a structure containing a Printer Class host configuration and state */ - static inline void PRNT_Host_USBTask(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo); + static inline void PRNT_Host_USBTask(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); static inline void PRNT_Host_USBTask(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo) { (void)PRNTInterfaceInfo; @@ -218,8 +218,8 @@ /* Function Prototypes: */ #if defined(__INCLUDE_FROM_PRINTER_CLASS_HOST_C) - static uint8_t DCOMP_PRNT_NextPRNTInterface(void* const CurrentDescriptor); - static uint8_t DCOMP_PRNT_NextPRNTInterfaceEndpoint(void* const CurrentDescriptor); + static uint8_t DCOMP_PRNT_NextPRNTInterface(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); + static uint8_t DCOMP_PRNT_NextPRNTInterfaceEndpoint(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); #endif #endif diff --git a/LUFA/Drivers/USB/Class/Host/RNDIS.h b/LUFA/Drivers/USB/Class/Host/RNDIS.h index bf4ea7611..111d60b5c 100644 --- a/LUFA/Drivers/USB/Class/Host/RNDIS.h +++ b/LUFA/Drivers/USB/Class/Host/RNDIS.h @@ -202,8 +202,7 @@ * * \return Boolean true if a packet is waiting to be read in by the host, false otherwise */ - - bool RNDIS_Host_IsPacketReceived(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo); + bool RNDIS_Host_IsPacketReceived(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); /** Retrieves the next pending packet from the device, discarding the remainder of the RNDIS packet header to leave * only the packet contents for processing by the host in the nominated buffer. @@ -240,7 +239,7 @@ * * \param[in,out] RNDISInterfaceInfo Pointer to a structure containing an RNDIS Class host configuration and state */ - static inline void RNDIS_Host_USBTask(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo); + static inline void RNDIS_Host_USBTask(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); static inline void RNDIS_Host_USBTask(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo) { (void)RNDISInterfaceInfo; @@ -263,13 +262,15 @@ /* Function Prototypes: */ #if defined(__INCLUDE_FROM_RNDIS_CLASS_HOST_C) static uint8_t RNDIS_SendEncapsulatedCommand(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo, - void* Buffer, uint16_t Length) ATTR_NON_NULL_PTR_ARG(1); + void* Buffer, uint16_t Length) ATTR_NON_NULL_PTR_ARG(1) + ATTR_NON_NULL_PTR_ARG(2); static uint8_t RNDIS_GetEncapsulatedResponse(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo, - void* Buffer, uint16_t Length) ATTR_NON_NULL_PTR_ARG(1); + void* Buffer, uint16_t Length) ATTR_NON_NULL_PTR_ARG(1) + ATTR_NON_NULL_PTR_ARG(2); static uint8_t DCOMP_RNDIS_Host_NextRNDISControlInterface(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); static uint8_t DCOMP_RNDIS_Host_NextRNDISDataInterface(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); - static uint8_t DCOMP_RNDIS_Host_NextRNDISInterfaceEndpoint(void* const CurrentDescriptor); + static uint8_t DCOMP_RNDIS_Host_NextRNDISInterfaceEndpoint(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1); #endif #endif diff --git a/LUFA/Drivers/USB/Class/Host/StillImage.h b/LUFA/Drivers/USB/Class/Host/StillImage.h index f3b0b0639..1feddb882 100644 --- a/LUFA/Drivers/USB/Class/Host/StillImage.h +++ b/LUFA/Drivers/USB/Class/Host/StillImage.h @@ -120,8 +120,8 @@ SI_ENUMERROR_NoError = 0, /**< Configuration Descriptor was processed successfully */ SI_ENUMERROR_InvalidConfigDescriptor = 1, /**< The device returned an invalid Configuration Descriptor */ SI_ENUMERROR_NoSIInterfaceFound = 2, /**< A compatible Still Image interface was not found in the device's - * Configuration Descriptor - */ + * Configuration Descriptor + */ SI_ENUMERROR_EndpointsNotFound = 3, /**< Compatible Still Image data endpoints were not found in the * device's Still Image interface */ @@ -180,7 +180,9 @@ * * \return A value from the \ref Pipe_Stream_RW_ErrorCodes_t enum */ - uint8_t SImage_Host_SendBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo, SI_PIMA_Container_t* const PIMAHeader); + uint8_t SImage_Host_SendBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo, + SI_PIMA_Container_t* const PIMAHeader) ATTR_NON_NULL_PTR_ARG(1) + ATTR_NON_NULL_PTR_ARG(2); /** Receives a raw PIMA block header to the device. This can be used to receive arbitrary PIMA blocks from the device with * or without parameters. @@ -193,7 +195,9 @@ * * \return A value from the \ref Pipe_Stream_RW_ErrorCodes_t enum */ - uint8_t SImage_Host_ReceiveBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo, SI_PIMA_Container_t* const PIMAHeader); + uint8_t SImage_Host_ReceiveBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo, + SI_PIMA_Container_t* const PIMAHeader) ATTR_NON_NULL_PTR_ARG(1) + ATTR_NON_NULL_PTR_ARG(2); /** Sends a given PIMA command to the attached device, filling out the PIMA command header's Transaction ID automatically. * @@ -287,7 +291,7 @@ * * \param[in,out] SIInterfaceInfo Pointer to a structure containing a Still Image Class host configuration and state */ - static inline void SImage_Host_USBTask(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo); + static inline void SImage_Host_USBTask(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1); static inline void SImage_Host_USBTask(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo) { (void)SIInterfaceInfo; |