summaryrefslogtreecommitdiffstats
path: root/scripts/coccinelle
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé2020-02-24 14:45:07 +0100
committerPaolo Bonzini2020-03-17 15:18:46 +0100
commit044e2af9f5f55d81be754a0e2ba1d206ad2b3bc6 (patch)
treecdc81b35e31afc1266f47a714e107b35a19b3da6 /scripts/coccinelle
parentmemory: Simplify memory_region_init_rom_nomigrate() to ease review (diff)
downloadqemu-044e2af9f5f55d81be754a0e2ba1d206ad2b3bc6.tar.gz
qemu-044e2af9f5f55d81be754a0e2ba1d206ad2b3bc6.tar.xz
qemu-044e2af9f5f55d81be754a0e2ba1d206ad2b3bc6.zip
scripts/cocci: Rename memory-region-{init-ram -> housekeeping}
As we are going to add various semantic changes related to the memory region API, rename this script to be more generic. Add a 'usage' header, and an entry in MAINTAINERS to avoid checkpatch warning. Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Diffstat (limited to 'scripts/coccinelle')
-rw-r--r--scripts/coccinelle/memory-region-housekeeping.cocci (renamed from scripts/coccinelle/memory-region-init-ram.cocci)13
1 files changed, 13 insertions, 0 deletions
diff --git a/scripts/coccinelle/memory-region-init-ram.cocci b/scripts/coccinelle/memory-region-housekeeping.cocci
index d290150872..3699c1017e 100644
--- a/scripts/coccinelle/memory-region-init-ram.cocci
+++ b/scripts/coccinelle/memory-region-housekeeping.cocci
@@ -1,3 +1,16 @@
+/*
+ Usage:
+
+ spatch \
+ --macro-file scripts/cocci-macro-file.h \
+ --sp-file scripts/coccinelle/memory-region-housekeeping.cocci \
+ --keep-comments \
+ --in-place \
+ --dir .
+
+*/
+
+
// Replace by-hand memory_region_init_ram_nomigrate/vmstate_register_ram
// code sequences with use of the new memory_region_init_ram function.
// Similarly for the _rom and _rom_device functions.