Skip to content

Commit

Permalink
devicetree: deprecate DT_DMAS_LABEL APIs
Browse files Browse the repository at this point in the history
Mark all variants of the DT_DMAS_LABEL APIs:
* DT_DMAS_LABEL_BY_IDX
* DT_DMAS_LABEL_BY_NAME
* DT_INST_DMAS_LABEL_BY_IDX
* DT_INST_DMAS_LABEL_BY_NAME

As deprecated in favor of utilizing:

* DT_DMAS_CTLR_BY_IDX
* DT_DMAS_CTLR_BY_NAME
* DT_DMAS_CTLR
* DT_INST_DMAS_CTLR_BY_IDX
* DT_INST_DMAS_CTLR_BY_NAME
* DT_INST_DMAS_CTLR

Signed-off-by: Kumar Gala <[email protected]>
  • Loading branch information
galak committed Mar 18, 2021
1 parent 9c02cad commit b813616
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
6 changes: 6 additions & 0 deletions doc/releases/release-notes-2.6.rst
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,12 @@ Deprecated in this release
:c:macro:`DT_INST_IO_CHANNELS_LABEL` were deprecated in favor of utilizing
:c:macro:`DT_IO_CHANNELS_CTLR` and variants.

* :c:macro:`DT_DMAS_LABEL_BY_IDX`,
:c:macro:`DT_DMAS_LABEL_BY_NAME`,
:c:macro:`DT_INST_DMAS_LABEL_BY_IDX`, and
:c:macro:`DT_INST_DMAS_LABEL_BY_NAME` were deprecated in favor of utilizing
:c:macro:`DT_DMAS_CTLR` and variants.

* USB HID specific macros in ``<include/usb/class/usb_hid.h>`` are deprecated
in favor of new common HID macros defined in ``<include/usb/class/hid.h>``.

Expand Down
4 changes: 4 additions & 0 deletions include/devicetree/dma.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ extern "C" {
* @return the label property of the node referenced at index "idx"
*/
#define DT_DMAS_LABEL_BY_IDX(node_id, idx) \
__DEPRECATED_MACRO \
DT_PROP_BY_PHANDLE_IDX(node_id, dmas, idx, label)

/**
Expand All @@ -64,6 +65,7 @@ extern "C" {
* @see DT_DMAS_LABEL_BY_IDX()
*/
#define DT_INST_DMAS_LABEL_BY_IDX(inst, idx) \
__DEPRECATED_MACRO \
DT_DMAS_LABEL_BY_IDX(DT_DRV_INST(inst), idx)

/**
Expand Down Expand Up @@ -99,6 +101,7 @@ extern "C" {
* @return the label property of the node referenced at the named element
*/
#define DT_DMAS_LABEL_BY_NAME(node_id, name) \
__DEPRECATED_MACRO \
DT_PROP(DT_PHANDLE_BY_NAME(node_id, dmas, name), label)

/**
Expand Down Expand Up @@ -178,6 +181,7 @@ extern "C" {
* @see DT_DMAS_LABEL_BY_NAME()
*/
#define DT_INST_DMAS_LABEL_BY_NAME(inst, name) \
__DEPRECATED_MACRO \
DT_DMAS_LABEL_BY_NAME(DT_DRV_INST(inst), name)

/**
Expand Down
4 changes: 4 additions & 0 deletions tests/lib/devicetree/api/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
* - DT_IO_CHANNELS_LABEL_BY_IDX
* - DT_IO_CHANNELS_LABEL_BY_NAME
* - DT_IO_CHANNELS_LABEL
* - DT_DMAS_LABEL_BY_IDX
* - DT_DMAS_LABEL_BY_NAME
* - DT_INST_CLOCKS_LABEL_BY_IDX
* - DT_INST_CLOCKS_LABEL_BY_NAME
* - DT_INST_CLOCKS_LABEL
Expand All @@ -24,6 +26,8 @@
* - DT_INST_IO_CHANNELS_LABEL_BY_IDX
* - DT_INST_IO_CHANNELS_LABEL_BY_NAME
* - DT_INST_IO_CHANNELS_LABEL
* - DT_INST_DMAS_LABEL_BY_IDX
* - DT_INST_DMAS_LABEL_BY_NAME
*/
#define __DEPRECATED_MACRO

Expand Down

0 comments on commit b813616

Please sign in to comment.