Tegra: pmc: fix defects flagged during MISRA analysis
authorAnthony Zhou <anzhou@nvidia.com>
Mon, 13 Mar 2017 08:47:58 +0000 (16:47 +0800)
committerVarun Wadekar <vwadekar@nvidia.com>
Thu, 15 Jun 2017 00:01:15 +0000 (17:01 -0700)
commit31d97dc2d876d1948963e4f4e6ef3b549dc98e18
tree98507b68da7102a474cedaa84f7999ac81a333ef
parentf5f64e4dbc9077ffe1299ee9e19a440ed12ac755
Tegra: pmc: fix defects flagged during MISRA analysis

Main fixes:

* Fixed if/while statement conditional to be essentially boolean [Rule 14.4]

* Added curly braces ({}) around if/for/while statements in order to
  make them compound [Rule 15.6]

* Added explicit casts (e.g. 0U) to integers in order for them to be
  compatible with whatever operation they're used in [Rule 10.1]

Change-Id: Ic72b248aeede6cf18bf85051188ea7b8fd8ae829
Signed-off-by: Anthony Zhou <anzhou@nvidia.com>
plat/nvidia/tegra/common/drivers/pmc/pmc.c
plat/nvidia/tegra/include/drivers/pmc.h