diff options
author | Paul Walmsley <paul@pwsan.com> | 2011-07-09 19:14:05 -0600 |
---|---|---|
committer | Paul Walmsley <paul@pwsan.com> | 2011-07-09 19:14:05 -0600 |
commit | 78183f3fdf76f422431a81852468be01b36db325 (patch) | |
tree | c236cc685b3568c2092e8aca16a20da0a87008b2 /arch/arm/plat-omap | |
parent | ecba3287b4121dcf3ca7607fe71c205913edec06 (diff) | |
download | talos-obmc-linux-78183f3fdf76f422431a81852468be01b36db325.tar.gz talos-obmc-linux-78183f3fdf76f422431a81852468be01b36db325.zip |
omap_hwmod: use a null structure record to terminate omap_hwmod_addr_space arrays
Previously, struct omap_hwmod_addr_space arrays were unterminated; and
users of these arrays used the ARRAY_SIZE() macro to determine the
length of the array. However, ARRAY_SIZE() only works when the array
is in the same scope as the macro user.
So far this hasn't been a problem. However, to reduce duplicated
data, a subsequent patch will move common data to a separate, shared
file. When this is done, ARRAY_SIZE() will no longer be usable.
This patch removes ARRAY_SIZE() usage for struct omap_hwmod_addr_space
arrays and uses a null structure member as the array terminator
instead.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Diffstat (limited to 'arch/arm/plat-omap')
-rw-r--r-- | arch/arm/plat-omap/include/plat/omap_hwmod.h | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/arch/arm/plat-omap/include/plat/omap_hwmod.h b/arch/arm/plat-omap/include/plat/omap_hwmod.h index 1adea9c62984..523e0b585b6c 100644 --- a/arch/arm/plat-omap/include/plat/omap_hwmod.h +++ b/arch/arm/plat-omap/include/plat/omap_hwmod.h @@ -220,7 +220,6 @@ struct omap_hwmod_addr_space { * @clk: interface clock: OMAP clock name * @_clk: pointer to the interface struct clk (filled in at runtime) * @fw: interface firewall data - * @addr_cnt: ARRAY_SIZE(@addr) * @width: OCP data width * @user: initiators using this interface (see OCP_USER_* macros above) * @flags: OCP interface flags (see OCPIF_* macros above) @@ -239,7 +238,6 @@ struct omap_hwmod_ocp_if { union { struct omap_hwmod_omap2_firewall omap2; } fw; - u8 addr_cnt; u8 width; u8 user; u8 flags; |