From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>, qemu-devel@nongnu.org
Cc: "Peter Maydell" <peter.maydell@linaro.org>,
"Philippe Mathieu-Daudé" <philmd@redhat.com>
Subject: [PATCH v3 03/25] scripts/cocci: Rename memory-region-{init-ram -> housekeeping}
Date: Mon, 16 Mar 2020 19:49:44 +0100 [thread overview]
Message-ID: <20200316185006.576-4-philmd@redhat.com> (raw)
In-Reply-To: <20200316185006.576-1-philmd@redhat.com>
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>
---
...t-ram.cocci => memory-region-housekeeping.cocci} | 13 +++++++++++++
MAINTAINERS | 1 +
2 files changed, 14 insertions(+)
rename scripts/coccinelle/{memory-region-init-ram.cocci => memory-region-housekeeping.cocci} (84%)
diff --git a/scripts/coccinelle/memory-region-init-ram.cocci b/scripts/coccinelle/memory-region-housekeeping.cocci
similarity index 84%
rename from scripts/coccinelle/memory-region-init-ram.cocci
rename to 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.
diff --git a/MAINTAINERS b/MAINTAINERS
index 32867bc636..e06ef9bb56 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2036,6 +2036,7 @@ F: include/exec/ramblock.h
F: memory.c
F: include/exec/memory-internal.h
F: exec.c
+F: scripts/coccinelle/memory-region-housekeeping.cocci
SPICE
M: Gerd Hoffmann <kraxel@redhat.com>
--
2.21.1
next prev parent reply other threads:[~2020-03-16 19:19 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-16 18:49 [PATCH v3 00/25] hw: Sanitize various MemoryRegion calls Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 01/25] memory: Correctly return alias region type Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 02/25] memory: Simplify memory_region_init_rom_nomigrate() to ease review Philippe Mathieu-Daudé
2020-03-16 18:49 ` Philippe Mathieu-Daudé [this message]
2020-03-16 18:49 ` [PATCH v3 04/25] scripts/cocci: Patch to replace memory_region_init_{ram, readonly -> rom} Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 05/25] hw/arm: Use memory_region_init_rom() with read-only regions Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 06/25] hw/display: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 07/25] hw/m68k: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 08/25] hw/net: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 09/25] hw/pci-host: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 10/25] hw/ppc: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 11/25] hw/riscv: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 12/25] hw/sh4: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 13/25] hw/sparc: " Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 14/25] scripts/cocci: Patch to detect potential use of memory_region_init_rom Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 15/25] scripts/cocci: Patch to remove unnecessary memory_region_set_readonly() Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 16/25] scripts/cocci: Patch to let devices own their MemoryRegions Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 17/25] hw/core: Let devices own the MemoryRegion they create Philippe Mathieu-Daudé
2020-03-16 18:49 ` [PATCH v3 18/25] hw/display: " Philippe Mathieu-Daudé
2020-03-16 18:50 ` [PATCH v3 19/25] hw/dma: " Philippe Mathieu-Daudé
2020-03-16 18:50 ` [PATCH v3 20/25] hw/riscv: " Philippe Mathieu-Daudé
2020-03-16 18:50 ` Alistair Francis
2020-03-16 18:50 ` [PATCH v3 21/25] hw/char: " Philippe Mathieu-Daudé
2020-03-16 18:50 ` [PATCH v3 22/25] hw/arm/stm32: Use memory_region_init_rom() with read-only regions Philippe Mathieu-Daudé
2020-03-16 18:50 ` [PATCH v3 23/25] hw/ppc/ppc405: " Philippe Mathieu-Daudé
2020-03-16 18:50 ` [PATCH v3 24/25] hw/arm: Remove unnecessary memory_region_set_readonly() on ROM alias Philippe Mathieu-Daudé
2020-03-16 18:50 ` [PATCH v3 25/25] hw/arm: Let devices own the MemoryRegion they create Philippe Mathieu-Daudé
2020-03-16 19:50 ` [PATCH v3 00/25] hw: Sanitize various MemoryRegion calls Aleksandar Markovic
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200316185006.576-4-philmd@redhat.com \
--to=philmd@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).