dts: nrf: Expand nRF DTS to support watchdog

Commit introduces support for watchdog configuration for Nordic
Semiconductor nRF SoCs in device tree.

Signed-off-by: Karol Lasończyk <karol.lasonczyk@nordicsemi.no>
This commit is contained in:
Karol Lasończyk 2018-04-17 15:29:12 +02:00 committed by Maureen Helm
parent 0c2ef4ea3d
commit 83e4947cf1
7 changed files with 83 additions and 0 deletions

View file

@ -19,4 +19,8 @@
#define CONFIG_I2C_1_IRQ_PRI NORDIC_NRF5_I2C_40004000_IRQ_0_PRIORITY
#define CONFIG_I2C_1_IRQ NORDIC_NRF5_I2C_40004000_IRQ_0
#define CONFIG_WDT_0_NAME NORDIC_NRF_WATCHDOG_40010000_LABEL
#define CONFIG_WDT_NRF_IRQ NORDIC_NRF_WATCHDOG_40010000_IRQ_WDT
#define CONFIG_WDT_NRF_IRQ_PRI NORDIC_NRF_WATCHDOG_40010000_IRQ_WDT_PRIORITY
/* End of SoC Level DTS fixup file */

View file

@ -28,4 +28,8 @@
#define CONFIG_USBD_NRF5_NUM_ISOOUT_EP NORDIC_NRF_USBD_0X40027000_NUM_ISOOUT_ENDPOINTS
#define CONFIG_USBD_NRF5_NAME NORDIC_NRF_USBD_0X40027000_LABEL
#define CONFIG_WDT_0_NAME NORDIC_NRF_WATCHDOG_40010000_LABEL
#define CONFIG_WDT_NRF_IRQ NORDIC_NRF_WATCHDOG_40010000_IRQ_WDT
#define CONFIG_WDT_NRF_IRQ_PRI NORDIC_NRF_WATCHDOG_40010000_IRQ_WDT_PRIORITY
/* End of SoC Level DTS fixup file */

View file

@ -74,3 +74,11 @@ config HAS_DTS_USB
help
This option specifies that the target platform supports device tree
configuration for USB.
config HAS_DTS_WDT
bool
default n
depends on HAS_DTS
help
This option specifies that the target platform supports device tree
configuration for WDT.

View file

@ -67,6 +67,14 @@
status = "disabled";
label = "I2C_1";
};
wdt: watchdog@40010000 {
compatible = "nordic,nrf-watchdog";
reg = <0x40010000 0x1000>;
interrupts = <16 1>;
interrupt-names = "wdt";
label = "WDT";
};
};
};

View file

@ -67,6 +67,14 @@
status = "disabled";
label = "I2C_1";
};
wdt: watchdog@40010000 {
compatible = "nordic,nrf-watchdog";
reg = <0x40010000 0x1000>;
interrupts = <16 1>;
interrupt-names = "wdt";
label = "WDT";
};
};
};

View file

@ -89,6 +89,14 @@
status = "disabled";
label = "USBD";
};
wdt: watchdog@40010000 {
compatible = "nordic,nrf-watchdog";
reg = <0x40010000 0x1000>;
interrupts = <16 1>;
interrupt-names = "wdt";
label = "WDT";
};
};
};

View file

@ -0,0 +1,43 @@
#
# Copyright (c) 2018, Nordic Semiconductor ASA
#
# SPDX-License-Identifier: Apache-2.0
#
---
title: Nordic Semiconductor NRF watchdog driver
id: nordic,nrf-watchdog
version: 0.1
description: >
This is a representation of the NRF watchdog
properties:
compatible:
type: string
category: required
description: compatible strings
constraint: "nordic,nrf-watchdog"
reg:
type: int
description: mmio register space
generation: define
category: required
label:
type: string
category: required
description: Human readable string describing the device (used by Zephyr for API name)
generation: define
interrupts:
type: array
category: required
description: required interrupts
generation: define
interrupt-names:
type: stringlist
category: optional
description: readable string describing the interrupts
generation: define