usb: provide typedefs for all the function callbacks.

This makes it easier to read for most people, and makes it substantially
easier to review changes in the function signatures themselves at a
later date.
This commit is contained in:
Kuldeep Singh Dhaka
2015-05-27 03:42:09 +05:30
committed by Karl Palsson
parent b1e495f51a
commit 4b892724cf
5 changed files with 23 additions and 22 deletions

View File

@@ -40,8 +40,7 @@ LGPL License Terms @ref lgpl_license
#include "usb_private.h"
int usbd_register_set_config_callback(usbd_device *usbd_dev,
void (*callback)(usbd_device *usbd_dev,
uint16_t wValue))
usbd_set_config_callback callback)
{
int i;
@@ -57,8 +56,7 @@ int usbd_register_set_config_callback(usbd_device *usbd_dev,
}
void usbd_register_set_altsetting_callback(usbd_device *usbd_dev,
void (*callback)(usbd_device *usbd_dev,
uint16_t wIndex, uint16_t wValue))
usbd_set_altsetting_callback callback)
{
usbd_dev->user_callback_set_altsetting = callback;
}