| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
|
| |
This avoids errors that can arise when multiple cores update the
variable at the same time.
|
|
|
|
| |
ok drahn@
|
|
|
|
|
|
|
| |
delay is awful in a hot path, and the SMMU is actually quite quick on
invalidation, so simply removing the delay is worth a thousand roses.
Found with mental support from dlg@ (and btrace)
|
|
|
|
| |
there until we have a proper way of making the MSI pages available.
|
|
|
|
|
|
|
|
|
|
| |
which is based on the IOMMU's. If you think about it, using the IOMMU's
DMA tag makes more sense because it is the IOMMU that does the actual DMA.
Noticed while debugging, since the SMMU's map function was called twice:
once for the PCI device, and once for its ppb(4). As the transaction has
the PCI device's Stream ID, not the ppb(4)'s, this would be useless work.
Suggested by kettenis@
|
|
|
|
| |
ok kettenis@
|
|
|
|
| |
ok kettenis@
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
regular ARM CPU MMU re-used for I/O devices. Implementations can have a
mix of stage-2 only and stage-2/stage-2 context blocks (domains). The
IOMMU allows different ways of grouping devices into a single domain.
This implementation only supports SMMUv2, since there is basically
no relevant SMMUv1 hardware. It also only supports AArch64
pagetables, the same as our pmap. Hence lots of code was taken from
there. There is no support for 32-bit pagetables, which would have
also been needed for SMMUv1 support. I have not yet seen any
machines with SMMUv3, which will probably need a new driver.
There is some work to be done, but the code works and it's about
time it hits the tree.
ok kettenis@
|
|
|
|
|
|
| |
contains information which IOMMUs we have and how the devices are routed.
ok kettenis@
|
|
|
|
| |
ok kettenis@
|
|
|
|
| |
ok kettenis@
|
|
|
|
| |
ok kettenis@
|
| |
|
|
|
|
| |
ok patrick@
|
|
|
|
| |
ok patrick@
|
|
|
|
|
|
| |
so that we can provide IOMMU-hooked bus DMA tags for each PCI device.
ok kettenis@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
the first cut of this diff was made with coccinelle using this spatch:
@rule@
type caddr_t;
expression m, off, len, cp;
@@
-m_copydata(m, off, len, (caddr_t)cp)
+m_copydata(m, off, len, cp)
i had fix it's opinionated idea of formatting by hand though, so
i'm not sure it was worth it.
ok deraadt@ bluhm@
|
|
|
|
|
|
| |
Apple M1 SoCs.
ok patrick@
|
|
|
|
|
|
|
|
| |
While here, zap a few ARGUSED linter comments.
Compile-tested by deraadt@.
ok deraadt@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Without this modification, because of the volatile qualifier, the
compiler does not produce four `` = 0 '' assignments, but code
equivalent to:
*(volatile uint32_t *)INT_ST_MASK3 = 0;
*(volatile uint32_t *)INT_ST_MASK2 =
*(volatile uint32_t *)INT_ST_MASK3;
*(volatile uint32_t *)INT_ST_MASK1 =
*(volatile uint32_t *)INT_ST_MASK2;
*(volatile uint32_t *)INT_ST_MASK0 =
*(volatile uint32_t *)INT_ST_MASK1;
Anders Gavare reported to Miod Vallat, and he gave me a diff.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The timecounter struct is large and I think it may change in the
future. Changing it later will be easier if we use C99-style
initialization for all timecounter structs. It also makes reading the
code a bit easier.
For reasons I cannot explain, switching to C99-style initialization
sometimes changes the hash of the resulting object file, even though
the resulting struct should be the same. So there is a binary change
here, but only sometimes. No behavior should change in either case.
I can't compile-test this everywhere but I have been staring at the
diff for days now and I'm relatively confident this will not break
compilation. Fingers crossed.
ok gnezdo@
|
|
|
|
| |
From miod@
|
| |
|
| |
|
|
|
|
|
|
| |
This allows us to reboot the machine.
ok patrick@
|
|
|
|
|
|
|
|
| |
The driver currently only supports AES-CBC mode but can easily
be extended to other algorithms and modes.
The aesv8-armx.S file was generated from the CRYPTOGAMS project.
Asked to commit by and ok patrick@
|
|
|
|
|
|
| |
running the kernel in EL2.
ok patrick@
|
| |
|
| |
|
|
|
|
|
|
|
| |
Enables a clock and/or power domain for a group of devices.
Required to use linux 5.11 dtbs on am335x and omap4.
ok kettenis@
|
|
|
|
|
|
|
| |
The loongson bootblocks are compiled with -mno-abicalls and do not use
gp-relative addressing.
A similar change has been made to the mips64 kernels recently.
|
|
|
|
|
| |
The address filter is not affected by link parameter changes,
so its reprogramming can be skipped.
|
|
|
|
|
|
|
|
| |
since its interrupts seem to be hardwared to trigger an FIQ instead of an
IRQ. This means we need to manipulate both the F and the I bit in the
DAIF register when enabling and disabling interrupts.
ok patrick@
|
|
|
|
|
|
|
|
| |
posted and non-posted device memory mappings and set the right memory
attributes for them. Needed because on the Apple M1 using the wrong
mapping will fault.
ok patrick@, dlg@
|
| |
|
|
|
|
|
|
|
|
| |
write-combining on arm64 as Linux does, this doesn't seem to work on
NXP's LX2160A SoC. So switch to using "device" mappings for now to
make amdgpu(4) work better.
ok patrick@
|
|
|
|
| |
device trees.
|
| |
|
|
|
|
|
|
|
| |
Use the right clock for the Cortex-A7 cores.
Support CPU clocks and remove exclock_cpuspeed().
ok patrick@
|
|
|
|
|
|
|
| |
children of the node claimed by expower(4). That node also fained a
"syscon" compatible in the process. Deal with these changes,
ok patrick@
|
|
|
|
|
|
|
|
|
| |
Set up the DMAC filter in one go instead of doing it separately for
unicast and multicast DMACs. This attempts to make the code a little
more readable. The setup should now run a bit faster as well because
it now does fewer register accesses.
Tested on CN5020, CN6120 and CN7130.
|
| |
|
|
|
|
| |
No code/functional change
|
|
|
|
| |
No code/functional change
|
|
|
|
| |
ok kettenis@
|
|
|
|
| |
ok kettenis@
|
|
|
|
|
|
|
|
|
| |
On OpenBSD/mips64, the kernel is compiled with -mno-abicalls. This
disables gp-relative addressing and essentially makes gp a spare
register in the kernel. Hence it is unnecessary to initialize gp when
entering the kernel. The _gp symbol is not needed either.
Suggested by miod@
|