Commit graph

859 commits

Author SHA1 Message Date
David Gibson
d06cda32f6 dtc: Fix FAIL() macro varargs
The way the checking subsystem FAIL() macro is currently implemented
it must take at least one paramater after the format string.  This
patch corrects the problem.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-12-05 08:27:22 -06:00
Kumar Gala
501e21cc6f Print out the total size as part of ftdump
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-12-05 08:27:00 -06:00
David Gibson
92cb9a25b1 dtc: Add many const qualifications
This adds 'const' qualifiers to many variables and functions.  In
particular it's now used for passing names to the tree accesor
functions.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-12-04 07:54:03 -06:00
David Gibson
2d72816ccf dtc: Fix uninitialized use of structure_ok
My rework of the tree checking code introduced a potentially nasty bug
- it uses the structure_ok variable uninitialized.  This patch fixes
the problem.  It's a fairly ugly bandaid approach, but the ugly will
disappear once future patches have folded the semantic checks into the
new framework.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-12-04 07:27:08 -06:00
Kumar Gala
2b7dc8dce5 Add an option to pad the blob that is generated
There are times when we need extra space in the blob and just want
to have it added on w/o know the exact size to make it.

The padding and min size options are mutually exclusive.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-12-04 07:26:47 -06:00
David Gibson
7c44c2f9cb dtc: Fix some lexical problems with references
The recent change to the lexer to only recognize property and node
names in the appropriate context removed a number of lexical warts in
our language that would have gotten ugly as we add expression support
and so forth.

But there's one nasty one remaining: references can contain a full
path, including the various problematic node name characters (',', '+'
and '-', for example).  This would cause trouble with expressions, and
it also causes trouble with the patch I'm working on to allow
expanding references to paths rather than phandles.  This patch
therefore reworks the lexer to mitigate these problems.

	- References to labels cause no problems.  These are now
recognized separately from references to full paths.  No syntax change
here.

	- References to full paths, including problematic characters
are allowed by "quoting" the path with braces
e.g. &{/pci@10000/somedevice@3,8000}.  The braces protect any internal
problematic characters from being confused with operators or whatever.

	- For compatibility with existing dts files, in v0 dts files
we allow bare references to paths as before &/foo/bar/whatever - but
*only* if the path contains no troublesome characters.  Specifically
only [a-zA-Z0-9_@/] are allowed.

This is an incompatible change to the dts-v1 format, but since AFAIK
no-one has yet switched to dts-v1 files, I think we can get away with
it.  Better to make the transition when people to convert to v1, and
get rid of the problematic old syntax.

Strictly speaking, it's also an incompatible change to the v0 format,
since some path references that were allowed before are no longer
allowed.  I suspect no-one has been using the no-longer-supported
forms (certainly none of the kernel dts files will cause trouble).
We might need to think about this harder, though.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-28 13:51:38 -06:00
Kumar Gala
f29454eb7e Fix whitespace in libfdt/fdt.h
Take from u-boot whitespace fixup of the file

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-11-28 09:44:27 -06:00
David Gibson
dc941774e2 dtc: Merge refs and labels into single "markers" list (v2)
Currently, every 'data' object, used to represent property values, has
two lists of fixup structures - one for labels and one for references.
Sometimes we want to look at them separately, but other times we need
to consider both types of fixup.

I'm planning to implement string references, where a full path rather
than a phandle is substituted into a property value.  Adding yet
another list of fixups for that would start to get silly.  So, this
patch merges the "refs" and "labels" lists into a single list of
"markers", each of which has a type field indicating if it represents
a label or a phandle reference.  String references or any other new
type of in-data marker will then just need a new type value - merging
data blocks and other common manipulations will just work.

While I was at it I made some cleanups to the handling of fixups which
simplify things further.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-26 16:00:19 -06:00
David Gibson
b16a2bd89d dtc: Flexible tree checking infrastructure (v2)
dtc: Flexible tree checking infrastructure

Here, at last, is a substantial start on revising dtc's infrastructure
for checking the tree; this is the rework I've been saying was
necessary practically since dtc was first release.

In the new model, we have a table of "check" structures, each with a
name, references to checking functions, and status variables.  Each
check can (in principle) be individually switched off or on (as either
a warning or error).  Checks have a list of prerequisites, so if
checks need to rely on results from earlier checks to make sense (or
even to avoid crashing) they just need to list the relevant other
checks there.

For now, only the "structural" checks and the fixups for phandle
references are converted to the new mechanism.  The rather more
involved semantic checks (which is where this new mechanism will
really be useful) will have to be converted in future patches.

At present, there's no user interface for turning on/off the checks -
the -f option now forces output even if "error" level checks fail.
Again, future patches will be needed to add the fine-grained control,
but that should be quite straightforward with the infrastructure
implemented here.

Also adds a testcase for the handling of bad references, which catches
a bug encountered while developing this patch.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-26 16:00:08 -06:00
David Gibson
67b6b33b9b dtc: Add valgrind support to testsuite
This patch adds some options to the run_tests.sh script allowing it to
run all the testcases under valgrind to check for pointer corruption
bugs and memory leaks.  Invoking "make checkm" will run the testsuite
with valgrind.

It include a mechanism for specifying valgrind errors to be suppressed
on a per-testcase basis, and adds a couple of such suppression files
for the mangle-layout and open_pack testcases which dump for use by
other testcases a buffer which may contain uninitialized sections.  We
use suppressions rather than initializing the buffer so that valgrind
will catch any internal access s to the uninitialized data, which
would be a bug.

The patch also fixes one genuine bug caught by valgrind -
_packblocks() in fdt_rw.c was using memcpy() where it should have been
using memmove().

At present the valgrinding won't do anything useful for testcases
invoked via a shell script - which includes all the dtc testcases.  I
plan to fix that later.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-26 15:57:58 -06:00
David Gibson
3ce5363387 dtc: Remove some redundant testcases
This patch removes a number of testcases from the testsuite that are
extremely unlikely to find any bugs that won't be found by the other
tests.  This speeds up the testsuite.

	- Both loops across the various tree block layouts run the
tree1_tests on the basic mangled tree.  This is completely redundant,
so remove the second copy. This removes 456 testcases.

	- We currently run tree1_tests on various trees manipulated by
move_and_save.  We replace those with just a dtbs_equal_ordered test
to check that the manipulated tree is equal to the original.  What
we're testing here is that fdt_move() operates correctly - it's very
unlikely it would succeed well enough for the ordered_equal test to
succeed, but the tree1_tests would fail on the result.  This removes
162 testcases.

	- Currently we re-ordered with mangle-layout both the basic
test_tree1.dtb and sw_tree1.test.dtb.  Since we've already checked
that these dtbs are equivalent with dtbs_ordered_equal, it's very
unlikely that the tests would fail on one but not the other.
Therefore reduce this to only using test_tree1.dtb.  This removes 828
testcases.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-26 15:19:33 -06:00
Jon Loeliger
8eaf5e3583 Add a script that compares an "old" and "new" dtc results.
Lots of room for improvement here.  Command line options, etc.
The script iterates over a hard-coded list of kernel DTS files.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-11-20 09:14:03 -06:00
David Gibson
b2e61bde9f dtc: Don't use env(1) in testsuite
The run_tests.sh script currently invokes the testcase binaries via
env(1).  This behaviour is inherited from the libhugetlbfs testsuite
which uses this approach to easily set various configuration
environment variables in testcases.

We don't use that for dtc, and are unlikely to ever want to.
Therefore this patch removes that technique, which substantially
speeds up the testsuite.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-20 09:04:19 -06:00
David Gibson
0d6ade2547 dtc: Add testcases for tree checks
This patch adds a group of testcases to check that dtc correctly
rejects trees with various structural errors.

To make things easier to test, we change dtc so that failing checks
(as opposed to other errors) result in exit code 2.

This patch also fixes an embarrasing bug uncovered by these new tests:
check_phandles() worked out if the tree's phandles were valid, then
throws that information away and returns success always.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-20 09:03:51 -06:00
David Gibson
2cf86939af libfdt: Abolish fdt_offset_ptr_typed()
The fdt_offset_ptr_typed() macro seemed like a good idea at the time.
However, it's not actually used all that often, it can silently throw
away const qualifications and it uses a gcc extension (typeof) which
I'd prefer to avoid for portability.

Therefore, this patch gets rid of it (and the fdt_offset_ptr_typed_w()
variant which was never used at all).  It also makes a few variables
const in testcases, which always should have been const, but weren't
caught before because of the aforementioned silent discards.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-20 09:01:29 -06:00
David Gibson
9521dc5ecc libfdt: Abolish _typed() variants, add _cell() variants
In a number of places through libfdt and its tests, we have *_typed()
macro variants on functions which use gcc's typeof and statement
expression extensions to allow passing literals where the underlying
function takes a buffer and size.

These seemed like a good idea at the time, but in fact they have some
problems.  They use typeof and statement expressions, extensions I'd
prefer to avoid for portability.  Plus, they have potential gotchas -
although they'll deal with the size of the thing passed, they won't
deal with other representation issues (like endianness) and results
could be very strange if the type of the expression passed isn't what
you think it is.

In fact, the only users of these _typed() macros were when the value
passed is a single cell (32-bit integer).  Therefore, this patch
removes all these _typed() macros and replaces them with explicit
_cell() variants which handle a single 32-bit integer, and which also
perform endian convesions as appropriate.

With this in place, it now becomes easy to use standardized big-endian
representation for integer valued properties in the testcases,
regardless of the platform we're running on.  We therefore do that,
which has the additional advantage that all the example trees created
during a test run are now byte-for-byte identical regardless of
platform.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-20 09:00:37 -06:00
David Gibson
682576d85b dtc: Add testcase for dtc references
This patch adds a testcase for dtc's reference-to-phandle
functionality.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-13 07:40:11 -06:00
David Gibson
7346858f81 libfdt: Add phandle related functions
This patch adds fdt_get_phandle() and fdt_node_offset_by_phandle()
functions to libfdt.  fdt_get_phandle() will retreive the phandle
value of a given node, and fdt_node_offset_by_phandle() will locate a
node given a phandle.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-13 07:40:06 -06:00
David Gibson
f6588bc32f dtc: Add missing dependencies for tests
At present, the Makefiles will not rebuild trees.o or the dtb files
derived from it if testdata.h is updated.  This is incorrect, and is
because of missing dependency information.

This patch fixes the problem by making sure that dependency
information is generated from trees.S and dumptrees.c.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-13 07:33:01 -06:00
David Gibson
91967acabd dtc: -Odts produces v1 output
This patch alters the -Odts mode output so that it uses dts-v1 format.
This means that dtc -Idts -Odts used on a v0 dts file will convert
that file to v1.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-11-12 07:46:04 -06:00
David Gibson
9138db565a dtc: Switch dtc to C-style literals
dtc: Switch dtc to C-style literals

This patch introduces a new version of dts file, distinguished from
older files by starting with the special token /dts-v1/.  dts files in
the new version take C-style literals instead of the old bare hex or
OF-style base notation.  In addition, the "range" for of memreserve entries
(/memreserve/ f0000-fffff) is no longer recognized in the new format.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-11-08 11:14:07 -06:00
David Gibson
9ed27a2aac dtc: Simplify lexing/parsing of literals vs. node/property names
The current scheme of having CELLDATA and MEMRESERVE states to
recognize hex literals instead of node or property names is
arse-backwards.  The patch switches things around so that literals are
lexed in normal states, and property/node names are only recognized in
the special PROPNODENAME state, which is only entered after a { or a
;, and is left as soon as we scan a property/node name or a keyword.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-11-08 11:14:07 -06:00
David Gibson
53acf491e9 libfdt: Add more documentation (path the fifth)
This patch documents a few more functions in libfdt.h.  All the
read-only functions are now documented.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-08 11:13:04 -06:00
David Gibson
9409bd96a5 dtc: Better exercise dtc base and bytestring features
This patch alters the main testcase, and the dts file corresponding to
it so that we at least trivially exercise dtc's bytestring and base
conversion features.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-08 09:05:21 -06:00
David Gibson
b433db0fc7 dtc: Add testcases exercising -Odts mode
This patch adds a batch of testcases exercising dtc's -Odts mode.
Specifically it checks that using dtc to convert dtb->dts->dtb
preserves the original dtb for a number of example dtb files.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-08 09:04:11 -06:00
David Gibson
d3ea6e5f96 dtc: Make -Idts -Odts preserve property-internal labels
This patch changes -Odts mode output so that labels within property
values in the input are preserved in the output.  Applied on top of
the earlier patch to preserve node and property labels in -Odts mode,
this means that dtc in -Idts -Odts mode will transfer all labels in
the input to the output.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-08 09:02:49 -06:00
David Gibson
ed01ae41e2 dtc: Refactor printing of property values in -Odts mode
Currently the main recursive tree printing function,
write_tree_source_node(), calls guess_type() to apply heuristics to
see how to print a property value, then calls the appropriate
write_propval_*() function to print it.

However, future heuristics for handling internal labels and the like
don't work well this way.  Therefore, this patch refactors things to
have write_tree_source_node() call a new write_propval() function,
which incorporates the heurstic logic from guess_type() and also calls
the right function to do the actual printing.

No behavioural change.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-08 09:00:36 -06:00
David Gibson
d79d4e280f libfdt: Fix sw_tree1 testcase
There is a bug in the sw_tree1 testcase / utility which puts two
"compatible" properties in one node in the output tree.  This patch
fixes the bug, and also adds a new test checking that the sw_tree1
output is equal to test_tree1.dtb as its supposed to be, which should
catch future errors of this type.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-06 12:18:32 -06:00
David Gibson
9d3af7ab62 libfdt: Add more documentation (patch the fourth)
This patch documents a few more functions in libfdt.h.  It also makes
a slight update to the description of the FDT_ERR_INTERNAL error code.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-05 08:49:28 -06:00
David Gibson
2ec634d24b libfdt: Add more documentation (patch the third)
libfdt: Add more documentation (patch the third)

This patch adds documentation in libfdt.h for a few more libfdt
functions.  It also makes a slight update to the documentation of
fdt_get_name().

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-05 08:48:57 -06:00
Emil Medve
e0f2989809 dtc: Fix the install target
/usr/bin/install: cannot stat `fdt.h': No such file or directory
/usr/bin/install: cannot stat `libfdt.h': No such file or directory

Signed-off-by: Emil Medve <Emilian.Medve@Freescale.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-05 08:48:42 -06:00
David Gibson
f7497dc6be dtc: Don't force alignment of cell list data
At present, defining a property as, say:
	foo = [abcd], <ffffffff>;

Will cause dtc to insert 2 bytes of zeros between the abcd and the
ffffffff, to align the cell form data.

Doing so seemed like a good idea at the time, but I don't believe
there are any users who actually rely on this behaviour.  Segher
claims that OF has some defined bindings which include properties an
unaligned subsection of which is interpreted as 32-bit ints (i.e. like
cell data).

Worse, this alignment will cause nothing but pain when we add
expression support to dtc (when celldata is included in a larger
bytestring expession, we won't know the size of the preceding chunk of
the expression until it's evaluated, so we would have to carry
alignment fixup information right through the expression evaluation
process).

Therefore, this patch kills off this alignment behaviour.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-05 08:42:10 -06:00
David Gibson
02563ad023 dtc: Make -Idts -Odts preserve node/property labels
This patch changes -Odts mode output so that labels on properties,
nodes and memreserve entries in input source are preserved in the
output.

Preserving labels within property values is trickier - another patch
coming later.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-05 08:41:23 -06:00
David Gibson
bf141b96cd dtc: Don't include libfdt in global LDFLAGS
Remove the uneccessary LDFLAGS from the top-level makefile.  It only
added libfdt/ to the link path.  dtc doesn't need libfdt at all, and
the testcases which do, already link libfdt.a by explicit path.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-05 08:40:52 -06:00
David Gibson
2f1ccc36f4 dtc: Move tree checking code to checks.c
This patch moves the dtc code for checking the device tree its
processing into a new checks.c.  The tree accessor functions from
livetree.c which the checks use are exported and added to dtc.h.

Another small step towards a flexible checking architecture.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-01 08:03:37 -05:00
David Gibson
a041dcdc48 libfdt: Handle v16 and re-ordered trees for r/w
Currently all the read/write functions in libfdt require that the
given tree be v17, and further, that the tree has the memory
reservation block, structure block and strings block stored in that
physical order.

This patch eases these constraints, by making fdt_open_int() reorder
the blocks, and/or convert the tree to v17, so that it will then be
ready for the other read-write functions.

It also extends fdt_pack() to actually remove any gaps between blocks
that might be present.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-11-01 08:03:31 -05:00
David Gibson
4a5df5c026 libfdt: Correctly handle versions > 17
If future dtb version > 17 are defined, that are still backwards
compatible with v16, libfdt will of course be able to read and
understand them.  However, when modifying such a tree, it can't
guarantee that it won't clobber additional structure from the new
version which it doesn't know about.  Therefore, before making
modifications to a tree of version >17, we must change it's version to
be exactly 17.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-30 07:48:35 -05:00
David Gibson
7e14259791 dtc: Remove leftover debugging printf() from mangle-layout
The mangle-layout testcase/utility had a leftover debugging printf().
This patch removes it.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-30 07:46:19 -05:00
Jon Loeliger
7b3fb789d2 DTC: Remove the need for the GLR Parser.
Previously, there were a few shift/reduce and reduce/reduce
errors in the grammar that were being handled by the not-so-popular
GLR Parser technique.

Flip a right-recursive stack-abusing rule into a left-recursive
stack-friendly rule and clear up three messes in one shot: No more
conflicts, no need for the GLR parser, and friendlier stackness.
Compensate by reversing the property list on the node.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-10-25 11:13:29 -05:00
David Gibson
3bef796b44 libfdt: Test on trees with different block layouts
At present, all the example dtbs we use in the testsuite are version
17 and have reservation map, then structure block then strings block
(the natural ordering based on alignment constraints).  However, all
libfdt's read-only and in-place write functions should also work on
v16 trees, and on trees with other layouts.

This patch adds a testcase / utility function to rearrange the blocks
of a dtb and/or regress a v17 tree to v16, and uses it to run tests on
trees with different layouts and versions.

Signed-off-by: David Gibson <david@tgibson.dropbear.id.au>
2007-10-25 09:50:07 -05:00
David Gibson
9b91134ba3 libfdt: Remove un-const-safe fdt_set_header macro
The fdt_set_header() macro casts an arbitrary pointer into (struct
fdt_header *) to set fdt header fields.  While we need to change the
type, so that we can use this macro on the usual (void *) used to
represent a device tree blob, the current macro also casts away any
const on the input pointer, which loses an important check.

This patch replaces the fdt_set_header() macro with a set of inline
functions, one for each header field which do a similar thing, but
which won't silently remove const from a given pointer.  This approach
is also more in keeping with the individual accessor macros we use for
reading fdt header fields.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-25 09:49:18 -05:00
David Gibson
57f99b7b3f libfdt: Documentation (patch the second)
Add documentation for another handful of libfdt functions to libfdt.h

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-25 09:37:53 -05:00
David Gibson
cec0c384ef libfdt: Add some documenting comments in libfdt.h
This patch adds some internal documentation in libfdt.h, in the form
of comments on the error codes and some functions.  Only a couple of
functions are covered so far, leaving the documentation still woefully
inadequate, but hey, it's a start.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-24 09:57:26 -05:00
David Gibson
3c44c87bde libfdt: Rename and publish _fdt_next_tag()
Although it's a low-level function that shouldn't normally be needed,
there are circumstances where it's useful for users of libfdt to use
the _fdt_next_tag() function.  Therefore, this patch renames it to
fdt_next_tag() and publishes it in libfdt.h.

In addition, this patch adds a new testcase using fdt_next_tag(),
dtbs_equal_ordered.  This testcase tests for structural equality of
two dtbs, including the order of properties and subnodes, but ignoring
NOP tags, the order of the dtb sections and the layout of strings in
the strings block.  This will be useful for testing other dtc
functionality in the future.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-24 09:56:27 -05:00
David Gibson
96b5fad3a1 libfdt: Rename and publish _fdt_check_header()
It's potentially useful for users of libfdt to sanity check a device
tree (or, rather, a blob of data which may or may not be a device
tree) before processing it in more detail with libfdt.

This patch renames the libfdt internal function _fdt_check_header() to
fdt_check_header() and makes it a published function, so it can now be
used for this purpose.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-24 07:58:13 -05:00
Jon Loeliger
2d50f8f9dd Quiet a bogus "May be used uninitialized" warning.
Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-10-23 10:13:00 -05:00
Jon Loeliger
afa8c2e1d7 Appease the printf() format $Gods with a correct type.
Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-10-23 09:43:14 -05:00
Jon Loeliger
7dfba39a23 DTC: Remove an unneeded %token definition.
Signed-off-by: Jon Loeliger <jdl@freescale.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-23 09:37:09 -05:00
Jon Loeliger
5641289a46 DTC: Minor grammar rule shuffle.
I like to see the basis cases established early in
the rule sets, so place  "empty" reduction first.
Purely cosmetic.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-23 09:35:36 -05:00
Jon Loeliger
30807ca1ce Reformat grammar rules to not mix language syntax and yacc syntax.
Use consistent indenting on all rule actions.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
2007-10-22 11:40:51 -05:00