272679 Commits

Author SHA1 Message Date
jmcneill
6a87d864d9 Include device decoding type in acpi_mem resources 2019-12-31 13:39:15 +00:00
ad
5c06357c90 Rename uvm_free() -> uvm_availmem(). 2019-12-31 13:07:09 +00:00
ad
b78a6618bd Rename uvm_page_locked_p() -> uvm_page_owner_locked_p() 2019-12-31 12:40:27 +00:00
jmcneill
439fe91982 Fetch bus_dma tags when acpi devnodes are created. They do not change
and this allows MD code to create more complex tags without being
concerned with the tag being destroyed later. While here, capture
translations offsets for address32/address64 resources.
2019-12-31 12:27:50 +00:00
ad
a31ca245b2 sys_fchdir: use LK_SHARED. 2019-12-31 11:49:08 +00:00
jmcneill
c1448d3e66 The DMA restrictions may not be defined in the direct parent of a device,
so search up the tree for a module device.
2019-12-31 11:42:46 +00:00
tkusumi
7b5209fa85 dm: Remove unnecessary inlining
These two don't really need to be inlined.
2019-12-31 10:30:30 +00:00
mlelstv
0aac85d51a Free buffers only when allocated. 2019-12-31 09:10:15 +00:00
skrll
44dc5bd335 Add another cache invalidation before reading memory for firmware query
results.
2019-12-31 08:01:19 +00:00
uki
6cb418f169 Done giving syspkg names without xorg_server_ver=110 2019-12-31 05:01:49 +00:00
uki
09a8769c6e Give syspkg name to macppc machine dependency files 2019-12-31 01:54:19 +00:00
uki
22f63fdf6d Give syspkg name to x68k machine dependency files 2019-12-31 01:20:06 +00:00
jmcneill
405e6792d9 Split vchiq into separate fdt and acpi attachments. 2019-12-31 01:00:22 +00:00
jmcneill
1a13a6c968 acpi glue is conditional on acpinodebus 2019-12-31 00:59:26 +00:00
thorpej
9473b3b786 Fix a problem with intr_unmask() that can cause a forever-loop:
- When handling the source-is-masked case in the interrupt vector, set the
  interrupt bit in a new ci_imasked field and ensure the bit is cleared
  from ci_ipending.
- In intr_unmask(), transfer the bit from ci_imasked to ci_ipending for
  non-level-sensitive interrupts (the PIC does the work for us in the
  level-sensitive case), and only force pending interrupts to be processed
  in this case.  (In all cases, make sure the now-unmasked bit is cleared
  from ci_imasked.)

Before, the bit was left in ci_ipending so as not to use edge-triggered
interrupts while the source is masked, but Xspllower() relies on the
pending bits getting cleared.

Tested by forcing all wm(4) interrupts on my test system though an
intr_mask() / softint / intr_unmask() cycle and exercising the network
heavily.
2019-12-30 23:32:29 +00:00
ad
0e79d963e9 PR port-sparc/54789: Sparc boot fails with "Trap 0x21 while interrupts disabled"
Remove assumption that cpu_info is smaller than 1kB.
2019-12-30 22:13:46 +00:00
jmcneill
bd97401499 Hide ACPI0004 devices on aarch64 2019-12-30 19:52:11 +00:00
jmcneill
d69f9e1943 If a device node is a child of a module device, and the module device declares DMA range restrictions, use them. 2019-12-30 19:50:29 +00:00
jmcneill
460e9b9a71 MD code may allocate a new dma tag for attach args, so destroy it if the device node is not claimed 2019-12-30 19:49:38 +00:00
jmcneill
a90d5931ec Add bcmmbox at acpi 2019-12-30 18:53:54 +00:00
jmcneill
3b3e15cc49 Add BCM2835 EMMC acpi glue 2019-12-30 18:53:34 +00:00
jmcneill
8f3c29f91c Split bcm2835 mbox driver into separate fdt and acpi frontends. 2019-12-30 18:43:38 +00:00
ad
be643866ce pg->phys_addr -> VM_PAGE_TO_PHYS(). 2019-12-30 18:28:06 +00:00
ad
87f077e02f Whitespace. 2019-12-30 18:18:03 +00:00
ad
9344a5952a pagedaemon:
- Use marker pages to keep place in the queue when scanning, rather than
  relying on assumptions.

- In uvmpdpol_balancequeue(), lock the object once instead of twice.

- When draining pools, the situation is getting desperate, but try to avoid
  saturating the system with xcall, lock and interrupt activity by sleeping
  for 1 clock tick if being continually awoken and all pools have been
  cycled through at least once.

- Pause & resume the freelist cache during pool draining.

PR kern/54209: NetBSD 8 large memory performance extremely low
PR kern/54210: NetBSD-8 processes presumably not exiting
PR kern/54727: writing a large file causes unreasonable system behaviour
2019-12-30 18:08:37 +00:00
ad
7875bd6d4d Freelist cache: drain using a high-priority xcall and re-enable now that
the pagedaemon starvation problem should be fixed.
2019-12-30 17:47:06 +00:00
ad
595f59ee30 uvm_pagealloc_pgb(): don't fill cache if we're into the reserves.
uvm_pagereplace(): use radix_tree_replace_node() to avoid alloc/free.
2019-12-30 17:45:53 +00:00
skrll
a5607601e1 Oops, don't match brcm,bcm2711-emmc2 here.
Thanks to jmcneill for pointing out my mistake
2019-12-30 16:41:38 +00:00
mlelstv
4aa047282b Follow the Linux driver an use the FDT "compatible" property to build a
filename for the nvram config file, fall back to the standard filename.

E.g.

# ofctl -p /
[Caching 123 nodes and 1093 properties]
#address-cells          00000001 ........ ........ ........     1
#size-cells             00000001 ........ ........ ........     1
compatible              73696e6f 766f6970 2c627069 2d6d322d   "sinovoip,bpi-m2-
            0010:       7a65726f 00...... ........ ........   zero"
            0015:       616c6c77 696e6e65 722c7375 6e38692d   "allwinner,sun8i-
            0025:       68322d70 6c757300 ........ ........   h2-plus"
interrupt-parent        00000001 ........ ........ ........   ....
model                   42616e61 6e612050 69204250 492d4d32   "Banana Pi BPI-M2
            0010:       2d5a6572 6f00.... ........ ........   -Zero"
name                    00...... ........ ........ ........   ""
serial-number           30326330 30303432 65636431 36376566   02c00042ecd167ef
            0010:       00...... ........ ........ ........   .


-rw-r--r--  1 root  wheel     875 Nov  2 12:06 brcmfmac43430-sdio.AP6212.txt
lrwxr-xr-x  1 root  wheel      29 Dec 30 16:19 brcmfmac43430-sdio.sinovoip,bpi-m2-zero.txt -> brcmfmac43430-sdio.AP6212.txt
-rw-r--r--  1 root  wheel     874 Jun 30  2019 brcmfmac43430-sdio.raspberrypi,3-model-b.txt
-rw-r--r--  1 root  wheel    1864 Jun 30  2019 brcmfmac43455-sdio.raspberrypi,3-model-b-plus.txt
lrwxr-xr-x  1 root  wheel      29 Dec 30 11:24 brcmfmac43455-sdio.raspberrypi,4-model-b-plus.txt -> brcmfmac43455-sdio.raspberrypi,3-model-b-plus.txt
2019-12-30 16:28:14 +00:00
skrll
eb468e55d0 Fix up ARM_LOCAL for 2711 so that it works now. 2019-12-30 16:19:27 +00:00
skrll
d5ea93478a Invalidate the cache just before trying to read the results from the
firmware as RPI4 A72s can fill the cache with speculation
2019-12-30 16:06:29 +00:00
skrll
a8634404fe Drop DEVMAP_{TRUNK_ADDR,ROUND_SIZE} to 4KB pages now that pmap_map_chunk
allows this.
2019-12-30 16:05:15 +00:00
skrll
6766bc22ce Update pmap_map_chunk to allow L[12] block mappings and L3 page mappings 2019-12-30 16:03:48 +00:00
skrll
a3be557976 Add emmc2 clock goop from mlelstv@
(missing commit)
2019-12-30 15:58:12 +00:00
skrll
c14f4bc647 Flush the cache and disable TTBR0 translations once we're done with
them in cpu_kernel_vm_init

The Cortex A72s in RPI4 need the cache flush for some reason.
2019-12-30 15:54:55 +00:00
skrll
2c916fc627 Remove unnecessary brackets and unwrap a conditional. Same code before
and after.
2019-12-30 15:42:39 +00:00
skrll
d074b17987 Add emmc2 clock goop from mlelstv@ 2019-12-30 15:36:37 +00:00
skrll
85769dec53 Match brcm,bcm2711-emmc2 2019-12-30 15:31:15 +00:00
macallan
ec8f7d43c7 add highly experimental NUMA support for US-IIIi machines 2019-12-30 06:54:31 +00:00
uki
469e7eba30 Fix incorrect obsolete package name 2019-12-30 05:37:19 +00:00
uki
23cdb66599 Give syspkg names to sparc machine dependency files 2019-12-30 05:36:51 +00:00
uki
57981cf58f Give syspkg name to sparc64 machine dependency files 2019-12-30 04:35:45 +00:00
uwe
7b0d3f464c Use -dash list instead of -tag list without content. 2019-12-30 00:49:56 +00:00
jmcneill
3d25b0def2 Allow MD code to provide custom bus_dma tags on a per-node basis. On Arm
this is required to return non-coherent bus_dma tags for device nodes with
_CCA=0
2019-12-29 23:47:56 +00:00
wiz
37492cb5bd Add missing '-width' argument to macro. 2019-12-29 23:03:20 +00:00
tsutsui
cbcfce8df3 Make sure rc, rc.subr, and rc.shutdown are properly updated.
Currently there is no info which rc* files should be updated
or not on upgrade (at least rc.conf and rc.local shouldn't),
so put back an explicit list in the postinstall script.
"Go for it" by christos@ in PR/54741.

Should be pulled up to netbsd-9.
2019-12-29 22:19:13 +00:00
martin
5ee3555ec5 Simplify some macros: if we only ever use them on the local cpu,
there is no need to do another pointer derefernence to go via the global
address of our cpu info.
Pointed out by ad.
2019-12-29 21:09:27 +00:00
triaxx
f47126f28c urndis.4: add LGE Nexus 5 as a knonw working device. 2019-12-29 20:58:34 +00:00
christos
128e5f5e67 1. Remove all the special handling of variables (-d -p -P -s -S) that
were dealing with DBG (-d) LDSTATIC/NOPIE (-p), and the rest with
   disabling/enabling sanitizers.
2. Use emalloc/estrdup for all the allocators instead of only some cases.
3. Add -V varspec which passes variables on the command line (as DBG
   and LDSTATIC used to be passed before) instead of appending them
   to the on-the-fly Makefile using -v varspec.
4. Change the distrib and rescue Makefiles to use -V instead of the removed
   flags.

The motivation of this is to make variable handling consistent, less magical,
and remove the need for changing crunchgen each time we want to add disabling
an option by default.

(as proposed in tech-toolchain)
2019-12-29 18:26:16 +00:00
ad
ddf9eff946 It looks like the freelist cache can starve the pagedaemon under certain
conditions, so temporarily disable it.  Will revisit soon.
2019-12-29 15:45:28 +00:00