Bart Van Assche
5299709d0a
treewide: Constify most dma_map_ops structures
...
Most dma_map_ops structures are never modified. Constify these
structures such that these can be write-protected. This patch
has been generated as follows:
git grep -l 'struct dma_map_ops' |
xargs -d\\n sed -i \
-e 's/struct dma_map_ops/const struct dma_map_ops/g' \
-e 's/const struct dma_map_ops {/struct dma_map_ops {/g' \
-e 's/^const struct dma_map_ops;$/struct dma_map_ops;/' \
-e 's/const const struct dma_map_ops /const struct dma_map_ops /g';
sed -i -e 's/const \(struct dma_map_ops intel_dma_ops\)/\1/' \
$(git grep -l 'struct dma_map_ops intel_dma_ops');
sed -i -e 's/const \(struct dma_map_ops dma_iommu_ops\)/\1/' \
$(git grep -l 'struct dma_map_ops' | grep ^arch/powerpc);
sed -i -e '/^struct vmd_dev {$/,/^};$/ s/const \(struct dma_map_ops[[:blank:]]dma_ops;\)/\1/' \
-e '/^static void vmd_setup_dma_ops/,/^}$/ s/const \(struct dma_map_ops \*dest\)/\1/' \
-e 's/const \(struct dma_map_ops \*dest = \&vmd->dma_ops\)/\1/' \
drivers/pci/host/*.c
sed -i -e '/^void __init pci_iommu_alloc(void)$/,/^}$/ s/dma_ops->/intel_dma_ops./' arch/ia64/kernel/pci-dma.c
sed -i -e 's/static const struct dma_map_ops sn_dma_ops/static struct dma_map_ops sn_dma_ops/' arch/ia64/sn/pci/pci_dma.c
sed -i -e 's/(const struct dma_map_ops \*)//' drivers/misc/mic/bus/vop_bus.c
Signed-off-by: Bart Van Assche <[email protected] >
Reviewed-by: Christoph Hellwig <[email protected] >
Cc: Benjamin Herrenschmidt <[email protected] >
Cc: Boris Ostrovsky <[email protected] >
Cc: David Woodhouse <[email protected] >
Cc: Juergen Gross <[email protected] >
Cc: H. Peter Anvin <[email protected] >
Cc: Ingo Molnar <[email protected] >
Cc: [email protected]
Cc: [email protected]
Cc: Russell King <[email protected] >
Cc: [email protected]
Signed-off-by: Doug Ledford <[email protected] >
2017-01-24 12:23:35 -05:00
Marc Zyngier
2fbadc3002
arm/arm64: xen: Move shared architecture headers to include/xen/arm
...
ARM and arm64 Xen ports share a number of headers, leading to
packaging issues when these headers needs to be exported, as it
breaks the reasonable requirement that an architecture port
has self-contained headers.
Fix the issue by moving the 5 header files to include/xen/arm,
and keep local placeholders to include the relevant files.
Signed-off-by: Marc Zyngier <[email protected] >
Reviewed-by: Stefano Stabellini <[email protected] >
2016-12-02 11:49:55 -08:00