[PATCH 0/8] Implement a new DTS Source Language

Jon Loeliger jdl at jdl.com
Wed Sep 24 05:04:04 EST 2008


This series of patches enhances the DTS source language to
support a fullly interpreted language for generating nodes
and properties.  It is backward compatible with V1 sources.

The main features implemented by this patch set support
function definitions, 'if', 'for', 'return' and assignment
statements.  Local variables, global constants and
almost complete C-like expressions are also supported.

Enhancements to the source position and error/warning
reporting now support source column positions too.

Jon Loeliger (8):
  Remove support for the legacy DTS source file format.
  Add conditionalized debug() print macro.
  Enhance source position implementation.
  Add header files for new Internal Representation form.
  Add most of the new IR implementation files.
  Add the main IR evaluation implementation
  Introduce new DTS language.
  Add documentation for the new DTS language.

 Documentation/manual.txt  |  500 ++++++++++++++--
 Makefile                  |    2 +-
 Makefile.dtc              |   18 +-
 dtc-lexer.l               |  299 +++++++---
 dtc-parser.y              |  726 +++++++++++++++++------
 dtc.c                     |    7 +-
 dtc.h                     |    9 +
 ir.c                      |  197 ++++++
 ir.h                      |  161 +++++
 ir_builtin.c              |  178 ++++++
 ir_builtin.h              |   41 ++
 ir_dump.c                 |  220 +++++++
 ir_emit.c                 |  492 +++++++++++++++
 ir_eval.c                 | 1504 +++++++++++++++++++++++++++++++++++++++++++++
 ir_scope.c                |  319 ++++++++++
 ir_scope.h                |  114 ++++
 livetree.c                |   16 +
 nv.c                      |  108 ++++
 nv.h                      |   34 +
 srcpos.c                  |  136 ++++-
 srcpos.h                  |   25 +-
 tests/base01.dts          |   24 +-
 tests/empty.dts           |    2 +
 tests/escapes.dts         |    2 +
 tests/label01.dts         |   38 +-
 tests/references_dts0.dts |   12 +-
 tests/run_tests.sh        |   27 +-
 tests/test01.dts          |   38 +-
 tests/test_tree1_dts0.dts |   18 +-
 treesource.c              |    3 +
 30 files changed, 4872 insertions(+), 398 deletions(-)
 create mode 100644 ir.c
 create mode 100644 ir.h
 create mode 100644 ir_builtin.c
 create mode 100644 ir_builtin.h
 create mode 100644 ir_dump.c
 create mode 100644 ir_emit.c
 create mode 100644 ir_eval.c
 create mode 100644 ir_scope.c
 create mode 100644 ir_scope.h
 create mode 100644 nv.c
 create mode 100644 nv.h




More information about the devicetree-discuss mailing list