target/adi_v5_xxx: use ADIV5_DP_SELECT_APBANK

and DP_SELECT_DPBANK.
Use the defined symbols instead of magic numbers.

Change-Id: I19c86b183e57e42b96f76eed180c0492cd67bee1
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7539
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
This commit is contained in:
Tomas Vanek
2023-03-14 14:31:30 +01:00
committed by Antonio Borneo
parent f49bf1adb4
commit 5fd4f2954d
2 changed files with 3 additions and 3 deletions

View File

@@ -523,7 +523,7 @@ static int swd_queue_ap_bankselect(struct adiv5_ap *ap, unsigned reg)
}
/* ADIv5 */
sel = (ap->ap_num << 24) | (reg & 0x000000F0);
sel = (ap->ap_num << 24) | (reg & ADIV5_DP_SELECT_APBANK);
if (dap->select != DP_SELECT_INVALID)
sel |= dap->select & DP_SELECT_DPBANK;