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-prev] [day] [month] [year] [list]
Message-ID: <5f7e348bb17b19ced22eaa20d5396e66eb724a8f.camel@intel.com>
Date: Mon, 9 Sep 2024 08:39:24 +0000
From: "Winiarska, Iwona" <iwona.winiarska@...el.com>
To: "tmaimon77@...il.com" <tmaimon77@...il.com>, "tali.perry1@...il.com"
	<tali.perry1@...il.com>, "venture@...gle.com" <venture@...gle.com>,
	"avifishman70@...il.com" <avifishman70@...il.com>,
	"christophe.jaillet@...adoo.fr" <christophe.jaillet@...adoo.fr>,
	"yuenn@...gle.com" <yuenn@...gle.com>, "Fair, Benjamin"
	<benjaminfair@...gle.com>
CC: "kernel-janitors@...r.kernel.org" <kernel-janitors@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"openbmc@...ts.ozlabs.org" <openbmc@...ts.ozlabs.org>
Subject: Re: [PATCH] peci: npcm: Constify struct peci_controller_ops​

On Sat, 2024-09-07 at 09:00 +0200, Christophe JAILLET wrote:
> 'struct peci_controller_ops' is not modified in this driver.
> 
> Constifying this structure moves some data to a read-only section, so
> increase overall security, especially when the structure holds some
> function pointers.
> 
> On a x86_64, with allmodconfig:
> Before:
> ======
>    text	   data	    bss	    dec	   
> hex	filename
>    8003	    784	     48	   8835	  
> 2283	drivers/peci/controller/peci-npcm.o
> 
> After:
> =====
>    text	   data	    bss	    dec	   
> hex	filename
>    8003	    776	     48	   8827	  
> 227b	drivers/peci/controller/peci-npcm.o
> 
> Signed-off-by: Christophe JAILLET <christophe.jaillet@...adoo.fr>

Reviewed-by: Iwona Winiarska <iwona.winiarska@...el.com>

Thanks
-Iwona

> ---
> Compile tested only
> ---
>  drivers/peci/controller/peci-npcm.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/peci/controller/peci-npcm.c
> b/drivers/peci/controller/peci-npcm.c
> index ec613d35c796..fa91be58f6f3 100644
> --- a/drivers/peci/controller/peci-npcm.c
> +++ b/drivers/peci/controller/peci-npcm.c
> @@ -224,7 +224,7 @@ static const struct regmap_config npcm_peci_regmap_config
> = {
>  	.fast_io = true,
>  };
>  
> -static struct peci_controller_ops npcm_ops = {
> +static const struct peci_controller_ops npcm_ops = {
>  	.xfer = npcm_peci_xfer,
>  };
>  

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ