controller.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 9 +
1 file changed, 9 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..7de58e4a1f 100644
--- a/arch/arm/dts/sama5d2.dtsi
+++ b/arch/arm/dts/sama5d2.dtsi
@@ -3,6
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 16
1 file changed, 16 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 7de58e4a1f..058009adca 100644
--- a/arch/arm/dts
Enable CONFIG_ATMEL_TCB_TIMER and disable CONFIG_ATMEL_PIT_TIMER.
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Reviewed-by: Claudiu Beznea
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 2 +-
configs
timers specified in device-tree
- Add "syscon" compatible to tcb node
Changes in v2:
- Reworked driver to use existing Linux bindings
Clément Léger (5):
timer: atmel_tcb_timer: add atmel_tcb driver
ARM: dts: at91: sama5d2: add AIC node
ARM: dts: at91: sama5d2: add TCB node
ARM: dts: at
udiu Beznea
Signed-off-by: Clément Léger
---
MAINTAINERS | 1 +
arch/arm/mach-at91/armv7/Makefile | 2 +
drivers/timer/Kconfig | 8 ++
drivers/timer/Makefile| 1 +
drivers/timer/atmel_tcb_timer.c | 161 ++
5 files cha
Le Thu, 31 Mar 2022 05:59:02 +,
a écrit :
> On 3/30/22 6:49 PM, Clément Léger wrote:
> > Le Tue, 22 Mar 2022 13:35:08 +0100,
> > Clément Léger a écrit :
> >
> >> Le Tue, 22 Mar 2022 11:18:39 +,
> >> a écrit :
> >>
> >
> &
Le Tue, 22 Mar 2022 13:35:08 +0100,
Clément Léger a écrit :
> Le Tue, 22 Mar 2022 11:18:39 +,
> a écrit :
>
[...]
> >
> > Could not initialize timer (err -22)
> >
> > ...
> >
> >
> >
> > Could you investigate this please ?
&
Le Tue, 22 Mar 2022 11:18:39 +,
a écrit :
> On 3/11/22 11:35 AM, Clément Léger wrote:
> > Enable CONFIG_ATMEL_TCB_TIMER and disable CONFIG_ATMEL_PIT_TIMER.
> > This will allow using the TCB timer instead of the PIT one when running
> > under OP-TEE.
>
> Hello Cl
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 16
1 file changed, 16 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 7de58e4a1f..058009adca 100644
--- a/arch/arm/dts
Enable CONFIG_ATMEL_TCB_TIMER and disable CONFIG_ATMEL_PIT_TIMER.
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Reviewed-by: Claudiu Beznea
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 2 +-
configs
udiu Beznea
Signed-off-by: Clément Léger
---
MAINTAINERS | 1 +
arch/arm/mach-at91/armv7/Makefile | 2 +
drivers/timer/Kconfig | 8 ++
drivers/timer/Makefile| 1 +
drivers/timer/atmel_tcb_timer.c | 154 ++
5 files cha
controller.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 9 +
1 file changed, 9 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..7de58e4a1f 100644
--- a/arch/arm/dts/sama5d2.dtsi
+++ b/arch/arm/dts/sama5d2.dtsi
@@ -3,6
e
Changes in v2:
- Reworked driver to use existing Linux bindings
Clément Léger (4):
timer: atmel_tcb_timer: add atmel_tcb driver
ARM: dts: at91: sama5d2: add AIC node
ARM: dts: at91: sama5d2: add TCB node
configs: sama5d2: enable option CONFIG_ATMEL_TCB_TIM
Le Wed, 9 Mar 2022 09:45:01 +,
a écrit :
> On 3/9/22 11:22 AM, Clément Léger wrote:
> > When using interrupts property, a global interrupt controller needs to
> > be added to avoid warnings when compiling device-tree:
> >
> > arch/arm/dts/at91-sa
*
+ * Copyright (C) 2022 Microchip Corporation
+ *
+ * Author: Clément Léger
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+#define TCB_CHAN(chan) ((chan) * 0x40)
+
+#define TCB_CCR(chan) (0x0 + TCB_CHAN(chan))
+#define TCB_CCR_CLKEN 0x1
Enable CONFIG_ATMEL_TCB_TIMER and disable CONFIG_ATMEL_PIT_TIMER.
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 2 +-
configs/sama5d2_ptc_ek_mmc_defconfig | 2
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 16
1 file changed, 16 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 1904f16eb6..ffbb171644 100644
--- a/arch/arm/dts
controller.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 10 ++
1 file changed, 10 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..1904f16eb6 100644
--- a/arch/arm/dts/sama5d2.dtsi
+++ b/arch/arm/dts/sama5d2.dtsi
@@ -3,6
property to tcb node
Changes in v3:
- Remove useless defines
- Add printf in case of unsupported timers specified in device-tree
- Add "syscon" compatible to tcb node
Changes in v2:
- Reworked driver to use existing Linux bindings
Clément Léger (4):
timer: atmel_tcb_timer: add atmel_
nabled + tick-timer DT entry. With this,
> having 2 timers enabled in config might not lead to using TCB all the time
> as it might be expected.
Hi Claudiu,
Hum indeed. Should I remove this commit and let the user select the TCB
when needed ?
Thanks,
>
> Thank you,
> Cla
Le Mon, 7 Mar 2022 10:57:02 +,
a écrit :
> On 04.03.2022 13:05, Clément Léger wrote:
> > EXTERNAL EMAIL: Do not click links or open attachments unless you know the
> > content is safe
> >
> > Add a driver for the timer counter block that can be found on sama5
Le Fri, 4 Mar 2022 14:31:08 +,
a écrit :
> On 3/4/22 1:05 PM, Clément Léger wrote:
> > Add the device-tree node to describe the TCB timer.
> >
> > Signed-off-by: Clément Léger
> > ---
> > arch/arm/dts/sama5d2.dtsi | 17 +
&g
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 17 +
1 file changed, 17 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index dee68dc022..9360c0008c 100644
--- a/arch/arm/dts
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 1 +
configs/sama5d2_ptc_ek_mmc_defconfig | 1 +
configs/sama5d2_ptc_ek_nandflash_defconfig | 1 +
configs
controller.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 10 ++
1 file changed, 10 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..dee68dc022 100644
--- a/arch/arm/dts/sama5d2.dtsi
+++ b/arch/arm/dts/sama5d2.dtsi
@@ -3,6
/timer/atmel_tcb_timer.c
@@ -0,0 +1,155 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2022 Microchip Corporation
+ *
+ * Author: Clément Léger
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+#define TCB_CHAN(chan) ((chan) * 0x40)
+
+#define TCB
o tcb node
Changes in v2:
- Reworked driver to use existing Linux bindings
Clément Léger (4):
timer: atmel_tcb_timer: add atmel_tcb driver
ARM: dts: at91: sama5d2: add AIC node
ARM: dts: at91: sama5d2: add TCB node
configs: sama5d2: enable option CONFIG_ATMEL_TCB_TIMER
M
Le Fri, 4 Mar 2022 10:46:45 +0100,
Clément Léger a écrit :
> Le Fri, 4 Mar 2022 10:45:21 +0100,
> Clément Léger a écrit :
>
> > Add the device-tree node to describe the TCB timer.
> >
> > Signed-off-by: Clément Léger
> > ---
> > arch/arm/dts/sama5d2
Le Fri, 4 Mar 2022 10:45:21 +0100,
Clément Léger a écrit :
> Add the device-tree node to describe the TCB timer.
>
> Signed-off-by: Clément Léger
> ---
> arch/arm/dts/sama5d2.dtsi | 16
> 1 file changed, 16 insertions(+)
>
> diff --git a/arch/arm/dts
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 16
1 file changed, 16 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..54f3dd4c62 100644
--- a/arch/arm/dts
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 1 +
configs/sama5d2_ptc_ek_mmc_defconfig | 1 +
configs/sama5d2_ptc_ek_nandflash_defconfig | 1 +
configs
/timer/atmel_tcb_timer.c
@@ -0,0 +1,155 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2022 Microchip Corporation
+ *
+ * Author: Clément Léger
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+#define TCB_CHAN(chan) ((chan) * 0x40)
+
+#define TCB
interrupts property to tcb node
Changes in v3:
- Remove useless defines
- Add printf in case of unsupported timers specified in device-tree
- Add "syscon" compatible to tcb node
Changes in v2:
- Reworked driver to use existing Linux bindings
Clément Léger (3):
timer: atmel_tcb_timer: add
Le Fri, 4 Mar 2022 09:32:16 +,
a écrit :
> On 3/4/22 11:12 AM, Clément Léger wrote:
>
> > Add the device-tree node to describe the TCB timer.
> >
> > Signed-off-by: Clément Léger
> > ---
> > arch/arm/dts/sama5d2.dtsi | 16
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 1 +
configs/sama5d2_ptc_ek_mmc_defconfig | 1 +
configs/sama5d2_ptc_ek_nandflash_defconfig | 1 +
configs
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 16
1 file changed, 16 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..63588b27b8 100644
--- a/arch/arm/dts
/timer/atmel_tcb_timer.c
@@ -0,0 +1,155 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2022 Microchip Corporation
+ *
+ * Author: Clément Léger
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+#define TCB_CHAN(chan) ((chan) * 0x40)
+
+#define TCB
defines
- Add printf in case of unsupported timers specified in device-tree
- Add "syscon" compatible to tcb node
Changes in v2:
- Reworked driver to use existing Linux bindings
Clément Léger (3):
timer: atmel_tcb_timer: add atmel_tcb driver
ARM: dts: at91: sama5d2: add TCB node
config
Le Thu, 3 Mar 2022 09:31:14 +,
a écrit :
> Hello Clement,
>
> Thank you for your patch.
>
> On 2/2/22 4:42 PM, Clément Léger wrote:
> > Add a driver for the timer counter block that can be found on sama5d2.
> > This driver will be used when booting under
and a review on the driver.
>
> Hello Clement,
>
> According to this :
>
> https://lore.kernel.org/linux-arm-kernel/yf0bkh4pxkorm...@piout.net/
>
> ... the interrupt is mandatory.
Hi Eugen,
No worries, I'll add it in a V3 but I will wait for the driver review to
do so
Le Fri, 4 Feb 2022 07:52:26 +,
a écrit :
> Hello Clement,
>
> Subject should be ARM: dts: [at91:] sama5d2: ...
>
> On 2/2/22 4:43 PM, Clément Léger wrote:
> > Add the device-tree node to describe the TCB timer.
> >
> > Signed-off-by: Clément Léger
> &
use existing Linux bindings
Clément Léger (3):
timer: atmel_tcb_timer: add atmel_tcb driver
dts: sama5d2: add TCB node
configs: sama5d2: enable option CONFIG_ATMEL_TCB_TIMER
MAINTAINERS | 1 +
arch/arm/dts/sama5d2.dtsi| 15 ++
configs
,160 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2022 Microchip Corporation
+ *
+ * Author: Clément Léger
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+#define TCB_CHAN(chan) ((chan) * 0x40)
+
+#define TCB_CCR(chan) (0x0 +
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 1 +
configs/sama5d2_ptc_ek_mmc_defconfig | 1 +
configs/sama5d2_ptc_ek_nandflash_defconfig | 1 +
configs
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 15 +++
1 file changed, 15 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..fc6a4fbe4d 100644
--- a/arch/arm/dts
This will allow using the TCB timer instead of the PIT one when running
under OP-TEE.
Signed-off-by: Clément Léger
---
configs/sama5d2_icp_mmc_defconfig| 1 +
configs/sama5d2_ptc_ek_mmc_defconfig | 1 +
configs/sama5d2_ptc_ek_nandflash_defconfig | 1 +
configs
Add the device-tree node to describe the TCB timer.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2.dtsi | 6 ++
1 file changed, 6 insertions(+)
diff --git a/arch/arm/dts/sama5d2.dtsi b/arch/arm/dts/sama5d2.dtsi
index 038cd73c03..c03a9d423c 100644
--- a/arch/arm/dts/sama5d2.dtsi
When booting under OP-TEE, the SYSC is secured which means the PIT is
also not accessible by non-secure world. The TCB 0 however is always
available for non-secure world and thus can be used.
This series add a TCB driver and enables it in sama5d2 configs.
Clément Léger (3):
timer
,152 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2022 Microchip Corporation
+ *
+ * Author: Clément Léger
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+#define TCB_CHAN(chan) ((chan) * 0x40)
+
+#define TCB_CCR(chan) (0x0 +
First two fields are reversed compared to what is expected by the SCMI
specification.
Signed-off-by: Clément Léger
Fixes: 60388844836 ("clk: add clock driver for SCMI agents")
---
include/scmi_protocols.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git
Le Tue, 24 Aug 2021 09:51:24 +,
a écrit :
> On 8/24/21 12:37 PM, Clément Léger wrote:
> > Le Mon, 23 Aug 2021 07:42:58 +,
> > a écrit :
> >
> >> On 8/4/21 5:55 PM, Clément Léger wrote:
> >>> When SYSRESET is enabled, cpu_reset function
Le Mon, 23 Aug 2021 07:42:58 +,
a écrit :
> On 8/4/21 5:55 PM, Clément Léger wrote:
> > When SYSRESET is enabled, cpu_reset function is also defined in
> > sysreset-uclass.c which lead to multiple definitions of this
> > function since reset.c is build unconditio
In order to make it more flexible and allow modifying the base address
of DRAM without recompiling U-Boot, use memory node from device tree
with fdtdec functions.
Signed-off-by: Clément Léger
---
board/atmel/sama5d2_xplained/sama5d2_xplained.c | 11 +++
1 file changed, 7 insertions
When using OP-TEE, address range [0x2000 - 0x2200] is reserved.
This modification allows to have a system which always work even when
OP-TEE is present.
Signed-off-by: Clément Léger
---
include/configs/sama5d27_som1_ek.h | 12
1 file changed, 4 insertions(+), 8 deletions
sama5d2_xplained DRAM detection code will be modified to use device tree
instead of hardcoded addresses. In order to prepare that, add the memory
node to at91-sama5d2_xplained.dts.
Signed-off-by: Clément Léger
---
arch/arm/dts/at91-sama5d2_xplained.dts | 4
1 file changed, 4 insertions
When using OP-TEE, address range [0x2000 - 0x2200] is reserved.
This modification allows to have a system which always work even when
OP-TEE is present.
Signed-off-by: Clément Léger
---
include/configs/sama5d2_xplained.h | 24 ++--
1 file changed, 10 insertions
In order to make it more flexible and allow modifying the base address
of DRAM without recompiling U-Boot, use memory node from device tree
with fdtdec functions.
Signed-off-by: Clément Léger
---
board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c | 12
1 file changed, 8 insertions
necessary exchange memory zones.
Changes in v2:
- Move memory node from sama5d2.dtsi to at91-sama5d2_xplained.dts
Clément Léger (5):
board: sama5d27_som1_ek: Get dram size and base from device tree
board: sama5d27_som1_ek: Modify load addresses
ARM: dts: at91: sama5d2_xplained: Add memory node in
lding SYSRESET_PSCI for instance on this
platform.
Signed-off-by: Clément Léger
---
arch/arm/mach-at91/armv7/Makefile | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-at91/armv7/Makefile
b/arch/arm/mach-at91/armv7/Makefile
index f5b2665957..246050b67b 100644
--- a/arc
Le Tue, 3 Aug 2021 08:58:17 +,
a écrit :
> On 8/2/21 3:39 PM, Clément Léger wrote:
> > sama5d2 support from DRAM will be modified to use device tree
> > instead of hardcoded addresses. In order to prepare that, add the
> > memory node to sama5d2.dtsi file since the boar
When using OP-TEE, address range [0x2000 - 0x2200] is reserved.
This modification allows to have a system which always work even when
OP-TEE is present.
Signed-off-by: Clément Léger
---
include/configs/sama5d2_xplained.h | 24 ++--
1 file changed, 10 insertions
In order to make it more flexible and allow modifying the base address
of DRAM without recompiling U-Boot, use memory node from device tree
with fdtdec functions.
Signed-off-by: Clément Léger
---
board/atmel/sama5d2_xplained/sama5d2_xplained.c | 11 +++
1 file changed, 7 insertions
When using OP-TEE, address range [0x2000 - 0x2200] is reserved.
This modification allows to have a system which always work even when
OP-TEE is present.
Signed-off-by: Clément Léger
---
include/configs/sama5d27_som1_ek.h | 12
1 file changed, 4 insertions(+), 8 deletions
necessary exchange memory zones.
Clément Léger (5):
board: sama5d27_som1_ek: Get dram size and base from device tree
board: sama5d27_som1_ek: Modify load addresses
ARM: dts: at91: sama5d2: Add memory node in devicetree
board: sama5d2_xplained: Get dram size and base from device tree
board
sama5d2 support from DRAM will be modified to use device tree instead of
hardcoded addresses. In order to prepare that, add the memory node to
sama5d2.dtsi file since the boards supported by U-Boot with sama5d2 all
contains 512Mb of DDR.
Signed-off-by: Clément Léger
---
arch/arm/dts/sama5d2
In order to make it more flexible and allow modifying the base address
of DRAM without recompiling U-Boot, use memory node from device tree
with fdtdec functions.
Signed-off-by: Clément Léger
---
board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c | 12
1 file changed, 8 insertions
66 matches
Mail list logo