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] [thread-next>] [day] [month] [year] [list]
Message-Id: <20170211013758.3288-4-me@jessfraz.com>
Date:   Fri, 10 Feb 2017 17:37:57 -0800
From:   Jess Frazelle <me@...sfraz.com>
To:     Stuart Yoder <stuart.yoder@....com>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Bharat Bhushan <bharat.bhushan@....com>,
        Bhaktipriya Shridhar <bhaktipriya96@...il.com>,
        Nipun Gupta <nipun.gupta@....com>,
        Jess Frazelle <me@...sfraz.com>,
        linux-kernel@...r.kernel.org (open list:QORIQ DPAA2 FSL-MC BUS DRIVER),
        devel@...verdev.osuosl.org (open list:STAGING SUBSYSTEM)
Cc:     kernel-hardening@...ts.openwall.com
Subject: [PATCH v2 4/5] staging: set msi_domain_ops as __ro_after_init

Marked msi_domain_ops structs as __ro_after_init when called only during init.
This protects the data structure from accidental corruption.

Suggested-by: Kees Cook <keescook@...omium.org>
Signed-off-by: Jess Frazelle <me@...sfraz.com>
---
 drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
index 6b1cd574644f..0e2c1b5e13b7 100644
--- a/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
+++ b/drivers/staging/fsl-mc/bus/irq-gic-v3-its-fsl-mc-msi.c
@@ -51,7 +51,7 @@ static int its_fsl_mc_msi_prepare(struct irq_domain *msi_domain,
 	return msi_info->ops->msi_prepare(msi_domain->parent, dev, nvec, info);
 }

-static struct msi_domain_ops its_fsl_mc_msi_ops = {
+static struct msi_domain_ops its_fsl_mc_msi_ops __ro_after_init = {
 	.msi_prepare = its_fsl_mc_msi_prepare,
 };

--
2.11.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ