From: Juergen Gross <jgross@suse.com>
To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org
Cc: Juergen Gross <jgross@suse.com>,
samuel.thibault@ens-lyon.org, wei.liu2@citrix.com
Subject: [PATCH v2 10/18] mini-os: remove unused mem_test() function
Date: Fri, 5 Aug 2016 19:35:54 +0200 [thread overview]
Message-ID: <1470418562-11234-11-git-send-email-jgross@suse.com> (raw)
In-Reply-To: <1470418562-11234-1-git-send-email-jgross@suse.com>
mem_test() isn't used anywhere and its value is rather questionable
with mini-os being in a mature state. Remove the function.
Signed-off-by: Juergen Gross <jgross@suse.com>
---
arch/x86/mm.c | 55 -------------------------------------------------------
1 file changed, 55 deletions(-)
diff --git a/arch/x86/mm.c b/arch/x86/mm.c
index 6aa4468..e2f026b 100644
--- a/arch/x86/mm.c
+++ b/arch/x86/mm.c
@@ -302,61 +302,6 @@ static void set_readonly(void *text, void *etext)
}
/*
- * A useful mem testing function. Write the address to every address in the
- * range provided and read back the value. If verbose, print page walk to
- * some VA
- *
- * If we get MEM_TEST_MAX_ERRORS we might as well stop
- */
-#define MEM_TEST_MAX_ERRORS 10
-int mem_test(unsigned long *start_va, unsigned long *end_va, int verbose)
-{
- unsigned long mask = 0x10000;
- unsigned long *pointer;
- int error_count = 0;
-
- /* write values and print page walks */
- if ( verbose && (((unsigned long)start_va) & 0xfffff) )
- {
- printk("MemTest Start: 0x%p\n", start_va);
- page_walk((unsigned long)start_va);
- }
- for ( pointer = start_va; pointer < end_va; pointer++ )
- {
- if ( verbose && !(((unsigned long)pointer) & 0xfffff) )
- {
- printk("Writing to %p\n", pointer);
- page_walk((unsigned long)pointer);
- }
- *pointer = (unsigned long)pointer & ~mask;
- }
- if ( verbose && (((unsigned long)end_va) & 0xfffff) )
- {
- printk("MemTest End: %p\n", end_va-1);
- page_walk((unsigned long)end_va-1);
- }
-
- /* verify values */
- for ( pointer = start_va; pointer < end_va; pointer++ )
- {
- if ( ((unsigned long)pointer & ~mask) != *pointer )
- {
- printk("Read error at 0x%lx. Read: 0x%lx, should read 0x%lx\n",
- (unsigned long)pointer, *pointer,
- ((unsigned long)pointer & ~mask));
- error_count++;
- if ( error_count >= MEM_TEST_MAX_ERRORS )
- {
- printk("mem_test: too many errors\n");
- return -1;
- }
- }
- }
- return 0;
-}
-
-
-/*
* get the PTE for virtual address va if it exists. Otherwise NULL.
*/
static pgentry_t *get_pgt(unsigned long va)
--
2.6.6
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2016-08-05 17:35 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-05 17:35 [PATCH v2 00/18] mini-os: support of auto-ballooning Juergen Gross
2016-08-05 17:35 ` [PATCH v2 01/18] mini-os: correct first free pfn Juergen Gross
2016-08-10 20:02 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 02/18] mini-os: remove unused alloc_contig_pages() function Juergen Gross
2016-08-10 20:02 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 03/18] mini-os: remove MM_DEBUG code Juergen Gross
2016-08-10 20:03 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 04/18] mini-os: add description of x86 memory usage Juergen Gross
2016-08-10 20:04 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 05/18] mini-os: add nr_free_pages counter Juergen Gross
2016-08-10 20:05 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 06/18] mini-os: let memory allocation fail if no free page available Juergen Gross
2016-08-10 20:06 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 07/18] mini-os: add ballooning config item Juergen Gross
2016-08-10 20:10 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 08/18] mini-os: get maximum memory size from hypervisor Juergen Gross
2016-08-10 20:11 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 09/18] mini-os: modify virtual memory layout for support of ballooning Juergen Gross
2016-08-10 20:16 ` Samuel Thibault
2016-08-05 17:35 ` Juergen Gross [this message]
2016-08-10 20:17 ` [PATCH v2 10/18] mini-os: remove unused mem_test() function Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 11/18] mini-os: add checks for out of memory Juergen Gross
2016-08-10 20:18 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 12/18] mini-os: don't allocate new pages for level 1 p2m tree Juergen Gross
2016-08-10 20:24 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 13/18] mini-os: add function to map one frame Juergen Gross
2016-08-10 20:26 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 14/18] mini-os: move p2m related macros to header file Juergen Gross
2016-08-10 20:29 ` Samuel Thibault
2016-08-05 17:35 ` [PATCH v2 15/18] mini-os: remap p2m list in case of ballooning Juergen Gross
2016-08-10 20:35 ` Samuel Thibault
2016-08-10 20:41 ` Samuel Thibault
2016-08-11 4:04 ` Juergen Gross
2016-08-05 17:36 ` [PATCH v2 16/18] mini-os: map page allocator's bitmap to virtual kernel area for ballooning Juergen Gross
2016-08-10 20:45 ` Samuel Thibault
2016-08-11 4:05 ` Juergen Gross
2016-08-05 17:36 ` [PATCH v2 17/18] mini-os: add support for ballooning up Juergen Gross
2016-08-10 21:02 ` Samuel Thibault
2016-08-11 5:50 ` Juergen Gross
2016-08-05 17:36 ` [PATCH v2 18/18] mini-os: balloon up in case of oom Juergen Gross
2016-08-10 21:07 ` Samuel Thibault
2016-08-11 5:51 ` Juergen Gross
2016-08-10 21:07 ` [PATCH v2 00/18] mini-os: support of auto-ballooning Samuel Thibault
2016-08-11 5:52 ` Juergen Gross
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=1470418562-11234-11-git-send-email-jgross@suse.com \
--to=jgross@suse.com \
--cc=minios-devel@lists.xenproject.org \
--cc=samuel.thibault@ens-lyon.org \
--cc=wei.liu2@citrix.com \
--cc=xen-devel@lists.xenproject.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).