Fix warnings from 6ed0087
Forgot to (void) an unused parameter when priorityless. usb-drv-rl27xx.c was using a compound init to initialize a semaphore but the structure changed so that it is no longer correct. Use designated initializers to avoid having to complete all fields. Forgot to break compatibility on all plugins and codecs since the kernel objects are now different. Take care of that too and do the sort thing. Change-Id: Ie2ab8da152d40be0c69dc573ced8d697d94b0674
This commit is contained in:
parent
6ed00870ab
commit
528715a672
|
@ -697,6 +697,7 @@ static const struct plugin_api rockbox_api = {
|
|||
#endif
|
||||
plugin_get_buffer,
|
||||
plugin_get_audio_buffer, /* defined in plugin.c */
|
||||
plugin_release_audio_buffer, /* defined in plugin.c */
|
||||
plugin_tsr, /* defined in plugin.c */
|
||||
plugin_get_current_filename,
|
||||
#if defined(DEBUG) || defined(SIMULATOR)
|
||||
|
@ -804,7 +805,6 @@ static const struct plugin_api rockbox_api = {
|
|||
|
||||
/* new stuff at the end, sort into place next time
|
||||
the API gets incompatible */
|
||||
plugin_release_audio_buffer, /* defined in plugin.c */
|
||||
};
|
||||
|
||||
static int plugin_buffer_handle;
|
||||
|
|
|
@ -160,12 +160,12 @@ void* plugin_get_buffer(size_t *buffer_size);
|
|||
#define PLUGIN_MAGIC 0x526F634B /* RocK */
|
||||
|
||||
/* increase this every time the api struct changes */
|
||||
#define PLUGIN_API_VERSION 230
|
||||
#define PLUGIN_API_VERSION 231
|
||||
|
||||
/* update this to latest version if a change to the api struct breaks
|
||||
backwards compatibility (and please take the opportunity to sort in any
|
||||
new function which are "waiting" at the end of the function table) */
|
||||
#define PLUGIN_MIN_API_VERSION 230
|
||||
#define PLUGIN_MIN_API_VERSION 231
|
||||
|
||||
/* plugin return codes */
|
||||
/* internal returns start at 0x100 to make exit(1..255) work */
|
||||
|
@ -843,6 +843,7 @@ struct plugin_api {
|
|||
#endif
|
||||
void* (*plugin_get_buffer)(size_t *buffer_size);
|
||||
void* (*plugin_get_audio_buffer)(size_t *buffer_size);
|
||||
void (*plugin_release_audio_buffer)(void);
|
||||
void (*plugin_tsr)(bool (*exit_callback)(bool reenter));
|
||||
char* (*plugin_get_current_filename)(void);
|
||||
#if defined(DEBUG) || defined(SIMULATOR)
|
||||
|
@ -976,7 +977,6 @@ struct plugin_api {
|
|||
|
||||
/* new stuff at the end, sort into place next time
|
||||
the API gets incompatible */
|
||||
void (*plugin_release_audio_buffer)(void);
|
||||
};
|
||||
|
||||
/* plugin header */
|
||||
|
|
|
@ -289,6 +289,7 @@ should_switch_tasks(struct thread_entry *thread)
|
|||
return THREAD_OK | THREAD_SWITCH;
|
||||
#else
|
||||
return THREAD_OK;
|
||||
(void)thread;
|
||||
#endif /* HAVE_PRIORITY_SCHEDULING */
|
||||
}
|
||||
|
||||
|
|
|
@ -79,28 +79,32 @@ struct endpoint_t {
|
|||
struct semaphore complete; /* semaphore for blocking transfers */
|
||||
};
|
||||
|
||||
#define EP_INIT(_type, _dir, _alloced, _buf, _len, _cnt, _block) \
|
||||
{ .type = (_type), .dir = (_dir), .allocated = (_alloced), .buf = (_buf), \
|
||||
.len = (_len), .cnt = (_cnt), .block = (_block) }
|
||||
|
||||
static struct endpoint_t ctrlep[2] = {
|
||||
{USB_ENDPOINT_XFER_CONTROL, DIR_OUT, true, NULL, 0, 0, true, {0, 0, 0}},
|
||||
{USB_ENDPOINT_XFER_CONTROL, DIR_IN, true, NULL, 0, 0, true, {0, 0, 0}}
|
||||
EP_INIT(USB_ENDPOINT_XFER_CONTROL, DIR_OUT, true, NULL, 0, 0, true),
|
||||
EP_INIT(USB_ENDPOINT_XFER_CONTROL, DIR_IN, true, NULL, 0, 0, true),
|
||||
};
|
||||
|
||||
static struct endpoint_t endpoints[16] = {
|
||||
{USB_ENDPOINT_XFER_CONTROL, 3, true, NULL, 0, 0, true, {0, 0, 0}}, /* stub */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false, {0, 0, 0}}, /* BOUT1 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* BIN2 */
|
||||
{USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* IIN3 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false, {0, 0, 0}}, /* BOUT4 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* BIN5 */
|
||||
{USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* IIN6 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false, {0, 0, 0}}, /* BOUT7 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* BIN8 */
|
||||
{USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* IIN9 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false, {0, 0, 0}}, /* BOUT10 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* BIN11 */
|
||||
{USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* IIN12 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false, {0, 0, 0}}, /* BOUT13 */
|
||||
{USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* BIN14 */
|
||||
{USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false, {0, 0, 0}}, /* IIN15 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_CONTROL, 3, true, NULL, 0, 0, true ), /* stub */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false ), /* BOUT1 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false ), /* BIN2 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false ), /* IIN3 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false ), /* BOUT4 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false ), /* BIN5 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false ), /* IIN6 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false ), /* BOUT7 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false ), /* BIN8 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false ), /* IIN9 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false ), /* BOUT10 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false ), /* BIN11 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false ), /* IIN12 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_OUT, false, NULL, 0, 0, false ), /* BOUT13 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_BULK, DIR_IN, false, NULL, 0, 0, false ), /* BIN14 */
|
||||
EP_INIT(USB_ENDPOINT_XFER_INT, DIR_IN, false, NULL, 0, 0, false ), /* IIN15 */
|
||||
};
|
||||
|
||||
static void setup_received(void)
|
||||
|
|
|
@ -72,12 +72,12 @@
|
|||
#define CODEC_ENC_MAGIC 0x52454E43 /* RENC */
|
||||
|
||||
/* increase this every time the api struct changes */
|
||||
#define CODEC_API_VERSION 46
|
||||
#define CODEC_API_VERSION 47
|
||||
|
||||
/* update this to latest version if a change to the api struct breaks
|
||||
backwards compatibility (and please take the opportunity to sort in any
|
||||
new function which are "waiting" at the end of the function table) */
|
||||
#define CODEC_MIN_API_VERSION 46
|
||||
#define CODEC_MIN_API_VERSION 47
|
||||
|
||||
/* reasons for calling codec main entrypoint */
|
||||
enum codec_entry_call_reason {
|
||||
|
|
Loading…
Reference in New Issue