1/* 2 * Copyright (c) 2021, Commonwealth Scientific and Industrial Research 3 * Organisation (CSIRO) ABN 41 687 119 230. 4 * Copyright (c) 2025 Analog Devices, Inc. 5 * 6 * SPDX-License-Identifier: Apache-2.0 7 * 8 * Application overlay for testing the devicetree.h extension API's. 9 * 10 * Names in this file should be chosen in a way that won't conflict 11 * with real-world devicetree nodes, to allow these tests to run on 12 * (and be extended to test) real hardware. 13 */ 14 15/ { 16 test { 17 #address-cells = <0x1>; 18 #size-cells = <0x1>; 19 20 test_sram1: sram@20000000 { 21 compatible = "zephyr,memory-region", "mmio-sram"; 22 reg = <0x20000000 0x1000>; 23 zephyr,memory-region = "SRAM_REGION"; 24 }; 25 26 test_sram2: sram@20001000 { 27 compatible = "zephyr,memory-region", "mmio-sram"; 28 reg = <0x20001000 0x1000>; 29 zephyr,memory-region = "SRAM@REGION#2"; 30 }; 31 32 test_fixed_clk: test-fixed-clock { 33 compatible = "fixed-clock"; 34 clock-frequency = <25000000>; 35 #clock-cells = <0>; 36 }; 37 38 test_clk: test-clock { 39 compatible = "vnd,clock"; 40 #clock-cells = <2>; 41 }; 42 43 test_adc_1: adc@10002000 { 44 reg = <0x10002000 0x1000>; 45 compatible = "vnd,adc"; 46 status = "okay"; 47 #io-channel-cells = <1>; 48 }; 49 50 test_adc_2: adc@10003000 { 51 reg = <0x10003000 0x1000>; 52 compatible = "vnd,adc"; 53 status = "okay"; 54 #io-channel-cells = <1>; 55 }; 56 57 test_mbox: mbox { 58 compatible = "vnd,mbox"; 59 #mbox-cells = <1>; 60 status = "okay"; 61 }; 62 63 test_mbox_zero_cell: mbox_zero_cell { 64 compatible = "vnd,mbox-zero-cell"; 65 #mbox-cells = <0>; 66 status = "okay"; 67 }; 68 69 /* there should only be one of these */ 70 test_temp_sensor: temperature-sensor { 71 compatible = "vnd,adc-temp-sensor"; 72 clocks = <&test_clk 3 7>, <&test_fixed_clk>, <&test_clk 8 2>; 73 clock-names = "clk-a", "clk-fixed", "clk-b"; 74 io-channels = <&test_adc_1 10>, <&test_adc_2 20>; 75 io-channel-names = "ch1", "ch2"; 76 mboxes = <&test_mbox 1>, <&test_mbox 2>, <&test_mbox_zero_cell>; 77 mbox-names = "tx", "rx", "zero"; 78 }; 79 80 test_hwspinlock: hwspinlock { 81 compatible = "vnd,hwspinlock"; 82 #hwlock-cells = <1>; 83 status = "okay"; 84 }; 85 86 test_hwspinlock_dev: hwspinlock-dev { 87 compatible = "vnd,hwspinlock-device"; 88 hwlocks = <&test_hwspinlock 1>, <&test_hwspinlock 2>; 89 hwlock-names = "rd", "wr"; 90 status = "okay"; 91 }; 92 }; 93}; 94