Commit 5ce3f0b1 authored by Dean Camera's avatar Dean Camera
Browse files

Add missing ATTR_NON_NULL_PTR_ARG and ATTR_ALWAYS_INLINE attributes to class driver functions.

parent 96063b9f
...@@ -135,7 +135,8 @@ ...@@ -135,7 +135,8 @@
* *
* \param[in,out] AudioInterfaceInfo Pointer to a structure containing an Audio Class configuration and state * \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) static inline void Audio_Device_USBTask(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
{ {
(void)AudioInterfaceInfo; (void)AudioInterfaceInfo;
...@@ -151,6 +152,8 @@ ...@@ -151,6 +152,8 @@
* *
* \return Boolean true if the given Audio interface has a sample to be read, false otherwise * \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) static inline bool Audio_Device_IsSampleReceived(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
{ {
if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled)) if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled))
...@@ -170,6 +173,8 @@ ...@@ -170,6 +173,8 @@
* *
* \return Boolean true if the given Audio interface is ready to accept the next sample, false otherwise * \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) static inline bool Audio_Device_IsReadyForNextSample(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
{ {
if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled)) if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled))
...@@ -188,7 +193,8 @@ ...@@ -188,7 +193,8 @@
* *
* \return Signed 8-bit audio sample from the audio interface * \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) static inline int8_t Audio_Device_ReadSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
{ {
int8_t Sample; int8_t Sample;
...@@ -212,7 +218,8 @@ ...@@ -212,7 +218,8 @@
* *
* \return Signed 16-bit audio sample from the audio interface * \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) static inline int16_t Audio_Device_ReadSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
{ {
int16_t Sample; int16_t Sample;
...@@ -236,7 +243,8 @@ ...@@ -236,7 +243,8 @@
* *
* \return Signed 24-bit audio sample from the audio interface * \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) static inline int32_t Audio_Device_ReadSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
{ {
int32_t Sample; int32_t Sample;
...@@ -260,7 +268,7 @@ ...@@ -260,7 +268,7 @@
* \param[in] Sample Signed 8-bit audio sample * \param[in] Sample Signed 8-bit audio sample
*/ */
static inline void Audio_Device_WriteSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, 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, static inline void Audio_Device_WriteSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo,
const int8_t Sample) const int8_t Sample)
{ {
...@@ -279,7 +287,7 @@ ...@@ -279,7 +287,7 @@
* \param[in] Sample Signed 16-bit audio sample * \param[in] Sample Signed 16-bit audio sample
*/ */
static inline void Audio_Device_WriteSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, 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, static inline void Audio_Device_WriteSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo,
const int16_t Sample) const int16_t Sample)
{ {
...@@ -298,7 +306,7 @@ ...@@ -298,7 +306,7 @@
* \param[in] Sample Signed 24-bit audio sample * \param[in] Sample Signed 24-bit audio sample
*/ */
static inline void Audio_Device_WriteSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, 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, static inline void Audio_Device_WriteSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo,
const int32_t Sample) const int32_t Sample)
{ {
......
...@@ -292,7 +292,8 @@ ...@@ -292,7 +292,8 @@
* \param[in,out] CDCInterfaceInfo Pointer to a structure containing a CDC Class configuration and state * \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 * \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 /** 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. * the transfer. While blocking, the USB and CDC service tasks are called repeatedly to maintain USB communications.
...@@ -300,15 +301,16 @@ ...@@ -300,15 +301,16 @@
* \param[in,out] CDCInterfaceInfo Pointer to a structure containing a CDC Class configuration and state * \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 * \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: */ /* Private Interface - For use in library only: */
#if !defined(__DOXYGEN__) #if !defined(__DOXYGEN__)
/* Function Prototypes: */ /* Function Prototypes: */
#if defined(__INCLUDE_FROM_CDC_CLASS_DEVICE_C) #if defined(__INCLUDE_FROM_CDC_CLASS_DEVICE_C)
static int CDC_Device_putchar(char c, FILE* Stream); static int CDC_Device_putchar(char c, FILE* Stream) ATTR_NON_NULL_PTR_ARG(2);
static int CDC_Device_getchar(FILE* Stream); static int CDC_Device_getchar(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1);
static int CDC_Device_getchar_Blocking(FILE* Stream); static int CDC_Device_getchar_Blocking(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1);
void CDC_Device_Event_Stub(void); void CDC_Device_Event_Stub(void);
void EVENT_CDC_Device_LineEncodingChanged(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo) void EVENT_CDC_Device_LineEncodingChanged(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo)
......
...@@ -179,8 +179,8 @@ ...@@ -179,8 +179,8 @@
* \param[in] ReportSize Size in bytes of the received report from the host. * \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, 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) const uint8_t ReportType, const void* ReportData, const uint16_t ReportSize)
ATTR_NON_NULL_PTR_ARG(4); ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(4);
/* Inline Functions: */ /* Inline Functions: */
/** Indicates that a millisecond of idle time has elapsed on the given HID interface, and the interface's idle count should be /** 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 @@ ...@@ -190,7 +190,7 @@
* *
* \param[in,out] HIDInterfaceInfo Pointer to a structure containing a HID Class configuration and state * \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) static inline void HID_Device_MillisecondElapsed(USB_ClassInfo_HID_Device_t* HIDInterfaceInfo)
{ {
if (HIDInterfaceInfo->State.IdleMSRemaining) if (HIDInterfaceInfo->State.IdleMSRemaining)
......
...@@ -135,7 +135,7 @@ ...@@ -135,7 +135,7 @@
* *
* \return A value from the \ref Endpoint_WaitUntilReady_ErrorCodes_t enum * \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 /** 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. * multiple MIDI events from the host in the one packet, multiple calls to this function will return each individual event.
...@@ -157,7 +157,7 @@ ...@@ -157,7 +157,7 @@
* *
* \param[in,out] MIDIInterfaceInfo Pointer to a structure containing a MIDI Class configuration and state * \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) static inline void MIDI_Device_USBTask(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo)
{ {
(void)MIDIInterfaceInfo; (void)MIDIInterfaceInfo;
......
...@@ -313,16 +313,17 @@ ...@@ -313,16 +313,17 @@
/* Function Prototypes: */ /* Function Prototypes: */
#if defined(__INCLUDE_FROM_CDC_CLASS_HOST_C) #if defined(__INCLUDE_FROM_CDC_CLASS_HOST_C)
static int CDC_Host_putchar(char c, FILE* Stream); static int CDC_Host_putchar(char c, FILE* Stream) ATTR_NON_NULL_PTR_ARG(2);
static int CDC_Host_getchar(FILE* Stream); static int CDC_Host_getchar(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1);
static int CDC_Host_getchar_Blocking(FILE* Stream); static int CDC_Host_getchar_Blocking(FILE* Stream) ATTR_NON_NULL_PTR_ARG(1);
void CDC_Host_Event_Stub(void); void CDC_Host_Event_Stub(void);
void EVENT_CDC_Host_ControLineStateChanged(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo) 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); 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_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_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
#endif #endif
......
...@@ -150,7 +150,7 @@ ...@@ -150,7 +150,7 @@
* *
* \return A value from the \ref Pipe_WaitUntilReady_ErrorCodes_t enum * \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. /** Receives a MIDI event packet from the device.
* *
...@@ -171,7 +171,7 @@ ...@@ -171,7 +171,7 @@
* *
* \param[in,out] MIDIInterfaceInfo Pointer to a structure containing an MIDI Class host configuration and state * \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) static inline void MIDI_Host_USBTask(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceInfo)
{ {
(void)MIDIInterfaceInfo; (void)MIDIInterfaceInfo;
......
...@@ -315,17 +315,19 @@ ...@@ -315,17 +315,19 @@
/* Function Prototypes: */ /* Function Prototypes: */
#if defined(__INCLUDE_FROM_MS_CLASS_HOST_C) #if defined(__INCLUDE_FROM_MS_CLASS_HOST_C)
static uint8_t DCOMP_MS_NextMSInterface(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); 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, static uint8_t MS_Host_SendCommand(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo,
MS_CommandBlockWrapper_t* const SCSICommandBlock, MS_CommandBlockWrapper_t* const SCSICommandBlock,
const void* const BufferPtr); 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); 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, 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, 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
#endif #endif
......
...@@ -187,7 +187,7 @@ ...@@ -187,7 +187,7 @@
* \return A value from the \ref Pipe_Stream_RW_ErrorCodes_t enum * \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, 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: */ /* Inline Functions: */
/** General management task for a given Printer host class interface, required for the correct operation of /** General management task for a given Printer host class interface, required for the correct operation of
...@@ -196,7 +196,7 @@ ...@@ -196,7 +196,7 @@
* *
* \param[in,out] PRNTInterfaceInfo Pointer to a structure containing a Printer Class host configuration and state * \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) static inline void PRNT_Host_USBTask(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo)
{ {
(void)PRNTInterfaceInfo; (void)PRNTInterfaceInfo;
...@@ -218,8 +218,8 @@ ...@@ -218,8 +218,8 @@
/* Function Prototypes: */ /* Function Prototypes: */
#if defined(__INCLUDE_FROM_PRINTER_CLASS_HOST_C) #if defined(__INCLUDE_FROM_PRINTER_CLASS_HOST_C)
static uint8_t DCOMP_PRNT_NextPRNTInterface(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); static uint8_t DCOMP_PRNT_NextPRNTInterfaceEndpoint(void* const CurrentDescriptor) ATTR_NON_NULL_PTR_ARG(1);
#endif #endif
#endif #endif
......
...@@ -202,8 +202,7 @@ ...@@ -202,8 +202,7 @@
* *
* \return Boolean true if a packet is waiting to be read in by the host, false otherwise * \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) ATTR_NON_NULL_PTR_ARG(1);
bool RNDIS_Host_IsPacketReceived(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo);
/** Retrieves the next pending packet from the device, discarding the remainder of the RNDIS packet header to leave /** 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. * only the packet contents for processing by the host in the nominated buffer.
...@@ -240,7 +239,7 @@ ...@@ -240,7 +239,7 @@
* *
* \param[in,out] RNDISInterfaceInfo Pointer to a structure containing an RNDIS Class host configuration and state * \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) static inline void RNDIS_Host_USBTask(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo)
{ {
(void)RNDISInterfaceInfo; (void)RNDISInterfaceInfo;
...@@ -263,13 +262,15 @@ ...@@ -263,13 +262,15 @@
/* Function Prototypes: */ /* Function Prototypes: */
#if defined(__INCLUDE_FROM_RNDIS_CLASS_HOST_C) #if defined(__INCLUDE_FROM_RNDIS_CLASS_HOST_C)
static uint8_t RNDIS_SendEncapsulatedCommand(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceInfo, 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, 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_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_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
#endif #endif
......
...@@ -180,7 +180,9 @@ ...@@ -180,7 +180,9 @@
* *
* \return A value from the \ref Pipe_Stream_RW_ErrorCodes_t enum * \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 /** 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. * or without parameters.
...@@ -193,7 +195,9 @@ ...@@ -193,7 +195,9 @@
* *
* \return A value from the \ref Pipe_Stream_RW_ErrorCodes_t enum * \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. /** Sends a given PIMA command to the attached device, filling out the PIMA command header's Transaction ID automatically.
* *
...@@ -287,7 +291,7 @@ ...@@ -287,7 +291,7 @@
* *
* \param[in,out] SIInterfaceInfo Pointer to a structure containing a Still Image Class host configuration and state * \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) static inline void SImage_Host_USBTask(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo)
{ {
(void)SIInterfaceInfo; (void)SIInterfaceInfo;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment