iommu.lists.linux-foundation.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] constify mmu_notifier_ops structures
@ 2015-11-29 22:02 Julia Lawall
  2015-11-29 22:02 ` [PATCH 2/3] iommu/amd: " Julia Lawall
  0 siblings, 1 reply; 3+ messages in thread
From: Julia Lawall @ 2015-11-29 22:02 UTC (permalink / raw)
  To: iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA
  Cc: kernel-janitors-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	xen-devel-GuqFBffKawtpuQazS67q72D2FQJk+8+b,
	linux-rdma-u79uwXL29TY76Z2rM5mHXA

mmu_notifier_ops structures are never modified, so declare them all as
const.

---

 drivers/infiniband/core/umem_odp.c |    2 +-
 drivers/iommu/amd_iommu_v2.c       |    2 +-
 drivers/xen/gntdev.c               |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH 2/3] iommu/amd: constify mmu_notifier_ops structures
  2015-11-29 22:02 [PATCH 0/3] constify mmu_notifier_ops structures Julia Lawall
@ 2015-11-29 22:02 ` Julia Lawall
  2015-12-14 14:45   ` Joerg Roedel
  0 siblings, 1 reply; 3+ messages in thread
From: Julia Lawall @ 2015-11-29 22:02 UTC (permalink / raw)
  To: Joerg Roedel; +Cc: kernel-janitors, iommu, linux-kernel

This mmu_notifier_ops structure is never modified, so declare it as
const, like the other mmu_notifier_ops structures.

Done with the help of Coccinelle.

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
The patches in this series are independent of each other.

 drivers/iommu/amd_iommu_v2.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iommu/amd_iommu_v2.c b/drivers/iommu/amd_iommu_v2.c
index d21d4ed..c847f2f 100644
--- a/drivers/iommu/amd_iommu_v2.c
+++ b/drivers/iommu/amd_iommu_v2.c
@@ -432,7 +432,7 @@ static void mn_release(struct mmu_notifier *mn, struct mm_struct *mm)
 	unbind_pasid(pasid_state);
 }
 
-static struct mmu_notifier_ops iommu_mn = {
+static const struct mmu_notifier_ops iommu_mn = {
 	.release		= mn_release,
 	.clear_flush_young      = mn_clear_flush_young,
 	.invalidate_page        = mn_invalidate_page,


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 2/3] iommu/amd: constify mmu_notifier_ops structures
  2015-11-29 22:02 ` [PATCH 2/3] iommu/amd: " Julia Lawall
@ 2015-12-14 14:45   ` Joerg Roedel
  0 siblings, 0 replies; 3+ messages in thread
From: Joerg Roedel @ 2015-12-14 14:45 UTC (permalink / raw)
  To: Julia Lawall; +Cc: kernel-janitors, iommu, linux-kernel

On Sun, Nov 29, 2015 at 11:02:50PM +0100, Julia Lawall wrote:
> This mmu_notifier_ops structure is never modified, so declare it as
> const, like the other mmu_notifier_ops structures.
> 
> Done with the help of Coccinelle.
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
> 
> ---
> The patches in this series are independent of each other.
> 
>  drivers/iommu/amd_iommu_v2.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied, thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-12-14 14:45 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-29 22:02 [PATCH 0/3] constify mmu_notifier_ops structures Julia Lawall
2015-11-29 22:02 ` [PATCH 2/3] iommu/amd: " Julia Lawall
2015-12-14 14:45   ` Joerg Roedel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).