From owner-svn-src-head@freebsd.org Thu Jul 9 22:54:18 2020 Return-Path: Delivered-To: svn-src-head@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 39A5435892E; Thu, 9 Jul 2020 22:54:18 +0000 (UTC) (envelope-from oliver.pntr@gmail.com) Received: from mail-yb1-xb31.google.com (mail-yb1-xb31.google.com [IPv6:2607:f8b0:4864:20::b31]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4B2s1P6K48z3WKF; Thu, 9 Jul 2020 22:54:17 +0000 (UTC) (envelope-from oliver.pntr@gmail.com) Received: by mail-yb1-xb31.google.com with SMTP id 133so1771435ybu.7; Thu, 09 Jul 2020 15:54:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=Oim7yTt5GoujOZiP87SE5YHfxZInGp2WTFnAeolgfJ4=; b=tNehUkknyL1jxdcPDSmSgNiOrK+nMaps36M3bdPRt/SZtTuPArM2XQEb75oMrhLMxt pyGLaH49hyWyaaSSCC4cq5szyLZLE/wP5DgiRLD0tkiONP6ySCWa1l/89+HWYG4nhXs3 PYFkP4yCFBTP5mXnwE82uZpxS0UhG+55Z3hceIRrpWBlfZmoYBSAs/AQ5j77eCszXb4Z YfkuAYzBLFKpeEFMgWm0ufBZGAIDNz2NbAsmXKkl6J0drXIwE7+Xu7Cu9I57YouJTB/U D3BMZNSDs5oQbWeglN5tn6trpU8d4rcZrGMoWcBqpDfnYf61uhDZmaL3UJyaIU8T1sDn 5sWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=Oim7yTt5GoujOZiP87SE5YHfxZInGp2WTFnAeolgfJ4=; b=rb1F7AepA4BWyHZXzRdWAjqrDzRdx3UZAYRMt033m2N7WgTmrJAf74k8KYQ5tEqX4I ts98PQ+cakE8EVyzxgkWfrAuGfHvW30f/RDxlPqJWt3QIW3uEcJe8YUEyYOJWMXlX6tl jTII3tOVJfX5nG4XsV8uf+OCGkrubCy5CH0WtMgO6iZYq2T0Z+v6ZMQ9DwsSMCcL0Yh6 cwwiusslGJdqJPQ10YNA2J0lkaP8t69Y1ke9ExitvlHlXACY2feGNqFFgipcO2gelw/A 8Hq2bVkYXdCJZgRHt8IJEizQVGNGzdcGVozExK8Qr9ic4W/MegefSa+J5WOAnmO1dsUB SyyA== X-Gm-Message-State: AOAM530O7wod1fiwbhRlHK1vX+RK8bpDnw85+mNRGBJU0zQtZ0QRBBzG z0Ea68QC2Z8UPBBHrRuqJfI0zDHwFn1Et6mEfK7F6w== X-Google-Smtp-Source: ABdhPJxMoOqBctqQJT1cYFo4ZcNXpgp60X2V3utboZEEAemYDXnsNIaN2aiFuaBuh2sHUYPRCVyZDRKPBdgJL5mW9IQ= X-Received: by 2002:a25:d843:: with SMTP id p64mr44987852ybg.68.1594335255868; Thu, 09 Jul 2020 15:54:15 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a5b:30b:0:0:0:0:0 with HTTP; Thu, 9 Jul 2020 15:54:15 -0700 (PDT) In-Reply-To: <202007092238.069McbU4014226@repo.freebsd.org> References: <202007092238.069McbU4014226@repo.freebsd.org> From: Oliver Pinter Date: Fri, 10 Jul 2020 00:54:15 +0200 Message-ID: Subject: Re: svn commit: r363060 - in head: stand/defaults sys/amd64/amd64 sys/powerpc/aim sys/vm To: Scott Long Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" X-Rspamd-Queue-Id: 4B2s1P6K48z3WKF X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; TAGGED_FROM(0.00)[]; REPLY(-4.00)[] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2020 22:54:18 -0000 On Friday, July 10, 2020, Scott Long wrote: > Author: scottl > Date: Thu Jul 9 22:38:36 2020 > New Revision: 363060 > URL: https://svnweb.freebsd.org/changeset/base/363060 > > Log: > Revert r362998, r326999 while a better compatibility strategy is devised. > > Modified: > head/stand/defaults/loader.conf > head/sys/amd64/amd64/pmap.c > head/sys/powerpc/aim/mmu_radix.c > head/sys/vm/vm_page.c > head/sys/vm/vm_page.h > > Modified: head/stand/defaults/loader.conf > ============================================================ > ================== > --- head/stand/defaults/loader.conf Thu Jul 9 20:55:18 2020 > (r363059) > +++ head/stand/defaults/loader.conf Thu Jul 9 22:38:36 2020 > (r363060) > @@ -53,7 +53,7 @@ entropy_cache_type="boot_entropy_cache" # > Required for > ram_excludelist_load="NO" # Set this to YES to load a file > # containing a list of addresses to > # exclude from the running system. > -ram_excludelist_name="/boot/excludelist.txt" # Set this to the name of > the file > +ram_excludeist_name="/boot/excludelist.txt" # Set this to the name of > the file Hi! This part of the revert seems still broken. > ram_excludelist_type="ram_excludelist" # Required for the kernel to find > # the blacklist module > > > Modified: head/sys/amd64/amd64/pmap.c > ============================================================ > ================== > --- head/sys/amd64/amd64/pmap.c Thu Jul 9 20:55:18 2020 (r363059) > +++ head/sys/amd64/amd64/pmap.c Thu Jul 9 22:38:36 2020 (r363060) > @@ -2060,7 +2060,7 @@ pmap_init(void) > int error, i, ret, skz63; > > /* L1TF, reserve page @0 unconditionally */ > - vm_page_excludelist_add(0, bootverbose); > + vm_page_blacklist_add(0, bootverbose); > > /* Detect bare-metal Skylake Server and Skylake-X. */ > if (vm_guest == VM_GUEST_NO && cpu_vendor_id == CPU_VENDOR_INTEL && > @@ -2081,7 +2081,7 @@ pmap_init(void) > printf("SKZ63: skipping 4M RAM starting " > "at physical 1G\n"); > for (i = 0; i < atop(0x400000); i++) { > - ret = vm_page_excludelist_add(0x40000000 + > + ret = vm_page_blacklist_add(0x40000000 + > ptoa(i), FALSE); > if (!ret && bootverbose) > printf("page at %#lx already > used\n", > > Modified: head/sys/powerpc/aim/mmu_radix.c > ============================================================ > ================== > --- head/sys/powerpc/aim/mmu_radix.c Thu Jul 9 20:55:18 2020 > (r363059) > +++ head/sys/powerpc/aim/mmu_radix.c Thu Jul 9 22:38:36 2020 > (r363060) > @@ -3557,7 +3557,7 @@ mmu_radix_init() > int error, i, pv_npg; > > /* L1TF, reserve page @0 unconditionally */ > - vm_page_excludelist_add(0, bootverbose); > + vm_page_blacklist_add(0, bootverbose); > > zone_radix_pgd = uma_zcache_create("radix_pgd_cache", > RADIX_PGD_SIZE, NULL, NULL, > > Modified: head/sys/vm/vm_page.c > ============================================================ > ================== > --- head/sys/vm/vm_page.c Thu Jul 9 20:55:18 2020 (r363059) > +++ head/sys/vm/vm_page.c Thu Jul 9 22:38:36 2020 (r363060) > @@ -155,11 +155,10 @@ vm_page_t vm_page_array; > long vm_page_array_size; > long first_page; > > -static TAILQ_HEAD(, vm_page) excludelist_head; > -static int sysctl_vm_page_excludelist(SYSCTL_HANDLER_ARGS); > -SYSCTL_PROC(_vm, OID_AUTO, page_excludelist, CTLTYPE_STRING | CTLFLAG_RD | > - CTLFLAG_MPSAFE, NULL, 0, sysctl_vm_page_excludelist, "A", > - "Blacklist pages"); > +static TAILQ_HEAD(, vm_page) blacklist_head; > +static int sysctl_vm_page_blacklist(SYSCTL_HANDLER_ARGS); > +SYSCTL_PROC(_vm, OID_AUTO, page_blacklist, CTLTYPE_STRING | CTLFLAG_RD | > + CTLFLAG_MPSAFE, NULL, 0, sysctl_vm_page_blacklist, "A", "Blacklist > pages"); > > static uma_zone_t fakepg_zone; > > @@ -259,16 +258,16 @@ vm_set_page_size(void) > } > > /* > - * vm_page_excludelist_next: > + * vm_page_blacklist_next: > * > - * Find the next entry in the provided string of excludelist > + * Find the next entry in the provided string of blacklist > * addresses. Entries are separated by space, comma, or newline. > * If an invalid integer is encountered then the rest of the > * string is skipped. Updates the list pointer to the next > * character, or NULL if the string is exhausted or invalid. > */ > static vm_paddr_t > -vm_page_excludelist_next(char **list, char *end) > +vm_page_blacklist_next(char **list, char *end) > { > vm_paddr_t bad; > char *cp, *pos; > @@ -315,13 +314,13 @@ vm_page_excludelist_next(char **list, char *end) > *list = cp; > return (trunc_page(bad)); > } > - printf("Garbage in RAM excludelist, skipping\n"); > + printf("Garbage in RAM blacklist, skipping\n"); > *list = NULL; > return (0); > } > > bool > -vm_page_excludelist_add(vm_paddr_t pa, bool verbose) > +vm_page_blacklist_add(vm_paddr_t pa, bool verbose) > { > struct vm_domain *vmd; > vm_page_t m; > @@ -337,7 +336,7 @@ vm_page_excludelist_add(vm_paddr_t pa, bool verbose) > vm_domain_free_unlock(vmd); > if (ret != 0) { > vm_domain_freecnt_inc(vmd, -1); > - TAILQ_INSERT_TAIL(&excludelist_head, m, listq); > + TAILQ_INSERT_TAIL(&blacklist_head, m, listq); > if (verbose) > printf("Skipping page with pa 0x%jx\n", > (uintmax_t)pa); > } > @@ -345,35 +344,35 @@ vm_page_excludelist_add(vm_paddr_t pa, bool verbose) > } > > /* > - * vm_page_excludelist_check: > + * vm_page_blacklist_check: > * > - * Iterate through the provided string of excludelist addresses, > pulling > + * Iterate through the provided string of blacklist addresses, pulling > * each entry out of the physical allocator free list and putting it > - * onto a list for reporting via the vm.page_excludelist sysctl. > + * onto a list for reporting via the vm.page_blacklist sysctl. > */ > static void > -vm_page_excludelist_check(char *list, char *end) > +vm_page_blacklist_check(char *list, char *end) > { > vm_paddr_t pa; > char *next; > > next = list; > while (next != NULL) { > - if ((pa = vm_page_excludelist_next(&next, end)) == 0) > + if ((pa = vm_page_blacklist_next(&next, end)) == 0) > continue; > - vm_page_excludelist_add(pa, bootverbose); > + vm_page_blacklist_add(pa, bootverbose); > } > } > > /* > - * vm_page_excludelist_load: > + * vm_page_blacklist_load: > * > - * Search for a special module named "ram_excludelist". It'll be a > + * Search for a special module named "ram_blacklist". It'll be a > * plain text file provided by the user via the loader directive > * of the same name. > */ > static void > -vm_page_excludelist_load(char **list, char **end) > +vm_page_blacklist_load(char **list, char **end) > { > void *mod; > u_char *ptr; > @@ -382,7 +381,7 @@ vm_page_excludelist_load(char **list, char **end) > mod = NULL; > ptr = NULL; > > - mod = preload_search_by_type("ram_excludelist"); > + mod = preload_search_by_type("ram_blacklist"); > if (mod != NULL) { > ptr = preload_fetch_addr(mod); > len = preload_fetch_size(mod); > @@ -396,7 +395,7 @@ vm_page_excludelist_load(char **list, char **end) > } > > static int > -sysctl_vm_page_excludelist(SYSCTL_HANDLER_ARGS) > +sysctl_vm_page_blacklist(SYSCTL_HANDLER_ARGS) > { > vm_page_t m; > struct sbuf sbuf; > @@ -407,7 +406,7 @@ sysctl_vm_page_excludelist(SYSCTL_HANDLER_ARGS) > if (error != 0) > return (error); > sbuf_new_for_sysctl(&sbuf, NULL, 128, req); > - TAILQ_FOREACH(m, &excludelist_head, listq) { > + TAILQ_FOREACH(m, &blacklist_head, listq) { > sbuf_printf(&sbuf, "%s%#jx", first ? "" : ",", > (uintmax_t)m->phys_addr); > first = 0; > @@ -794,14 +793,14 @@ vm_page_startup(vm_offset_t vaddr) > } > > /* > - * Remove excludelisted pages from the physical memory allocator. > + * Remove blacklisted pages from the physical memory allocator. > */ > - TAILQ_INIT(&excludelist_head); > - vm_page_excludelist_load(&list, &listend); > - vm_page_excludelist_check(list, listend); > + TAILQ_INIT(&blacklist_head); > + vm_page_blacklist_load(&list, &listend); > + vm_page_blacklist_check(list, listend); > > - list = kern_getenv("vm.excludelist"); > - vm_page_excludelist_check(list, NULL); > + list = kern_getenv("vm.blacklist"); > + vm_page_blacklist_check(list, NULL); > > freeenv(list); > #if VM_NRESERVLEVEL > 0 > > Modified: head/sys/vm/vm_page.h > ============================================================ > ================== > --- head/sys/vm/vm_page.h Thu Jul 9 20:55:18 2020 (r363059) > +++ head/sys/vm/vm_page.h Thu Jul 9 22:38:36 2020 (r363060) > @@ -613,7 +613,7 @@ vm_page_t vm_page_alloc_contig_domain(vm_object_t obje > vm_page_t vm_page_alloc_freelist(int, int); > vm_page_t vm_page_alloc_freelist_domain(int, int, int); > void vm_page_bits_set(vm_page_t m, vm_page_bits_t *bits, vm_page_bits_t > set); > -bool vm_page_excludelist_add(vm_paddr_t pa, bool verbose); > +bool vm_page_blacklist_add(vm_paddr_t pa, bool verbose); > vm_page_t vm_page_grab(vm_object_t, vm_pindex_t, int); > vm_page_t vm_page_grab_unlocked(vm_object_t, vm_pindex_t, int); > int vm_page_grab_pages(vm_object_t object, vm_pindex_t pindex, int > allocflags, > _______________________________________________ > svn-src-head@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-head > To unsubscribe, send any mail to "svn-src-head-unsubscribe@freebsd.org" >