Skip to content

Commit 91b06e8

Browse files
author
fpr
committed
Remove some unused parameter warnings
Signed-off-by: fpr <[email protected]>
1 parent b2b0e7a commit 91b06e8

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

cores/arduino/stm32/usbd_hid_composite.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,7 @@ __ALIGN_BEGIN static uint8_t HID_KEYBOARD_ReportDesc[HID_KEYBOARD_REPORT_DESC_SI
369369
static uint8_t USBD_HID_Init (USBD_HandleTypeDef *pdev,
370370
uint8_t cfgidx)
371371
{
372+
UNUSED(cfgidx);
372373
uint8_t ret = 0;
373374

374375
/* Open EP IN */
@@ -407,6 +408,7 @@ static uint8_t USBD_HID_Init (USBD_HandleTypeDef *pdev,
407408
static uint8_t USBD_HID_DeInit (USBD_HandleTypeDef *pdev,
408409
uint8_t cfgidx)
409410
{
411+
UNUSED(cfgidx);
410412
/* Close HID EPs */
411413
USBD_LL_CloseEP(pdev,
412414
HID_MOUSE_EPIN_ADDR);

variants/DISCO_L475VG_IOT/usb/usbd_conf.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,8 @@ void HAL_PCD_MspInit(PCD_HandleTypeDef *hpcd)
133133
*/
134134
void HAL_PCD_MspDeInit(PCD_HandleTypeDef *hpcd)
135135
{
136+
UNUSED(hpcd);
137+
136138
/* Disable USB FS Clock */
137139
__HAL_RCC_USB_OTG_FS_CLK_DISABLE();
138140
__HAL_RCC_SYSCFG_CLK_DISABLE();

variants/DISCO_L475VG_IOT/usb/usbd_desc.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ __ALIGN_BEGIN static uint8_t USBD_LangIDDesc[USB_LEN_LANGID_STR_DESC] __ALIGN_EN
134134
HIBYTE(USBD_LANGID_STRING),
135135
};
136136

137-
uint8_t USBD_StringSerial[USB_SIZ_STRING_SERIAL] =
137+
static uint8_t USBD_StringSerial[USB_SIZ_STRING_SERIAL] =
138138
{
139139
USB_SIZ_STRING_SERIAL,
140140
USB_DESC_TYPE_STRING,
@@ -158,6 +158,7 @@ static void Get_SerialNum(void);
158158
*/
159159
uint8_t *USBD_HID_DeviceDescriptor(USBD_SpeedTypeDef speed, uint16_t *length)
160160
{
161+
UNUSED(speed);
161162
*length = sizeof(USBD_DeviceDesc);
162163
return (uint8_t*)USBD_DeviceDesc;
163164
}
@@ -170,6 +171,7 @@ uint8_t *USBD_HID_DeviceDescriptor(USBD_SpeedTypeDef speed, uint16_t *length)
170171
*/
171172
uint8_t *USBD_HID_LangIDStrDescriptor(USBD_SpeedTypeDef speed, uint16_t *length)
172173
{
174+
UNUSED(speed);
173175
*length = sizeof(USBD_LangIDDesc);
174176
return (uint8_t*)USBD_LangIDDesc;
175177
}
@@ -201,6 +203,7 @@ uint8_t *USBD_HID_ProductStrDescriptor(USBD_SpeedTypeDef speed, uint16_t *length
201203
*/
202204
uint8_t *USBD_HID_ManufacturerStrDescriptor(USBD_SpeedTypeDef speed, uint16_t *length)
203205
{
206+
UNUSED(speed);
204207
USBD_GetString((uint8_t *)USBD_MANUFACTURER_STRING, USBD_StrDesc, length);
205208
return USBD_StrDesc;
206209
}
@@ -213,6 +216,7 @@ uint8_t *USBD_HID_ManufacturerStrDescriptor(USBD_SpeedTypeDef speed, uint16_t *l
213216
*/
214217
uint8_t *USBD_HID_SerialStrDescriptor(USBD_SpeedTypeDef speed, uint16_t *length)
215218
{
219+
UNUSED(speed);
216220
*length = USB_SIZ_STRING_SERIAL;
217221

218222
/* Update the serial number string descriptor with the data from the unique ID*/
@@ -282,7 +286,7 @@ static void Get_SerialNum(void)
282286
}
283287

284288
/**
285-
* @brief Convert Hex 32Bits value into char
289+
* @brief Convert Hex 32Bits value into char
286290
* @param value: value to convert
287291
* @param pbuf: pointer to the buffer
288292
* @param len: buffer length

0 commit comments

Comments
 (0)