Skip to content

Commit aa144ca

Browse files
erwangogalak
authored andcommitted
drivers/usb: stm23: Fix deprecated macro declaration
Use of '__DEPRECATED_MACRO' was not compatible with the way macro is used later in this driver. Remove it and keep the warning as vector for deprecation information. Additionally, replace DT_NODE_HAS_PROP with DT_INST_PROP as using the former is not recommended with boolean properties. Signed-off-by: Erwan Gouriou <[email protected]>
1 parent c0fcd35 commit aa144ca

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/usb/device/usb_dc_stm32.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ LOG_MODULE_REGISTER(usb_dc_stm32);
4444
#elif DT_HAS_COMPAT_STATUS_OKAY(st_stm32_usb)
4545
#define DT_DRV_COMPAT st_stm32_usb
4646
#define USB_IRQ_NAME usb
47-
#if DT_INST_NODE_HAS_PROP(0, enable_pin_remap)
48-
#define USB_ENABLE_PIN_REMAP __DEPRECATED_MACRO DT_INST_PROP(0, enable_pin_remap)
47+
#if DT_INST_PROP(0, enable_pin_remap)
48+
#define USB_ENABLE_PIN_REMAP DT_INST_PROP(0, enable_pin_remap)
4949
#warning "Property deprecated in favor of property 'remap-pa11-pa12' from 'st-stm32-pinctrl'"
5050
#endif
5151
#endif

0 commit comments

Comments
 (0)