From 3d4225f210c5b9545a3b4433c983d3a4ffa743a7 Mon Sep 17 00:00:00 2001 From: Vegard Storheil Eriksen Date: Thu, 16 Sep 2021 20:25:24 +0200 Subject: rcc: Fix enable register access for devices with multiple registers for the same bus. --- rcc/rcc_enums.h.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'rcc') diff --git a/rcc/rcc_enums.h.j2 b/rcc/rcc_enums.h.j2 index 1b0abd0..97e85b9 100644 --- a/rcc/rcc_enums.h.j2 +++ b/rcc/rcc_enums.h.j2 @@ -12,7 +12,7 @@ namespace rcc { template void enable(const T& rcc, {{ bus }}_dev dev) { - rcc->{{ bus }}ENR |= dev; + rcc->{{ bus.split('_')[0] }}ENR{{ bus.split('_')[1] if '_' in bus else '' }} |= dev; } {% endfor %} -- cgit v1.2.3