lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 13 Mar 2023 08:49:03 +0800
From:   "Peng Fan (OSS)" <peng.fan@....nxp.com>
To:     shawnguo@...nel.org, s.hauer@...gutronix.de
Cc:     kernel@...gutronix.de, festevam@...il.com, linux-imx@....com,
        linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
        Peng Fan <peng.fan@....com>, kernel test robot <lkp@...el.com>
Subject: [PATCH] soc: imx: imx8m-blk-ctrl: reordering the fields

From: Peng Fan <peng.fan@....com>

The clang-analyzer reports:
"Excessive padding in 'struct imx8m_blk_ctrl_domain_data'
(12 padding bytes, where 4 is optimal). Optimal fields order: name,
clk_names, path_names, gpc_name, num_clks, num_paths, rst_mask, clk_mask,
mipi_phy_rst_mask, consider reordering the fields or adding explicit
padding members [clang-analyzer-optin.performance.Padding]
   struct imx8m_blk_ctrl_domain_data {"

So reordering the fields.

Reported-by: kernel test robot <lkp@...el.com>
Signed-off-by: Peng Fan <peng.fan@....com>
---
 drivers/soc/imx/imx8m-blk-ctrl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/soc/imx/imx8m-blk-ctrl.c b/drivers/soc/imx/imx8m-blk-ctrl.c
index 9b0f81dc292b..716e6eb4838f 100644
--- a/drivers/soc/imx/imx8m-blk-ctrl.c
+++ b/drivers/soc/imx/imx8m-blk-ctrl.c
@@ -37,10 +37,10 @@ struct imx8m_blk_ctrl {
 struct imx8m_blk_ctrl_domain_data {
 	const char *name;
 	const char * const *clk_names;
-	int num_clks;
 	const char * const *path_names;
-	int num_paths;
 	const char *gpc_name;
+	int num_clks;
+	int num_paths;
 	u32 rst_mask;
 	u32 clk_mask;
 
-- 
2.37.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ