summaryrefslogtreecommitdiff
path: root/sys/arch/amd64
AgeCommit message (Collapse)Author
2009-04-23add missing newline in the unknown model caseJonathan Gray
2009-04-21Simplify PCI config space access code. There is no way we're ever going toMark Kettenis
see the ancient mode 2 on machines capable of running OpenBSD/amd64. ok deraadt@, toby@, oga@
2009-04-21add a sg_dma backend for amd64 bus_dma. This is a lot more clever aboutOwain Ainsworth
mapping to the gart than the old code, and shouldn't conflict with bouncebuffers when they're added. This is essentially the sparc64 iommu code that's been modularised a bit so I can eventually use the same code for agp-based dma for memory managed drm drivers. Now, this would overflow ramdiskA, so iommu and sg_dma are now #ifndef SMALL_KERNEL. ok kettenis@, marco@. SMALL_KERNEL discussions with deraadt.
2009-04-20fixed style, no binary changeAriane van der Steldt
2009-04-20bigmem is not tweakable by config(8), it never was.Reyk Floeter
ok oga@
2009-04-20amas device for amd64, describes the physical memory layout on AMD64 CPU.Ariane van der Steldt
Replaces pchb with amas for the AMD64 address map. amas0 at pci0 dev 24 function 1 "AMD AMD64 0Fh Address Map" rev 0x00 Currently disabled (causing pchb to attach instead). ok art@
2009-04-20Add a BUS_DMA_ZERO flag for bus_dmamem_alloc() to return zeroed memory.Owain Ainsworth
Saves every damned driver calling bzero(), and continues the M_ZERO, PR_ZERO symmetry.
2009-04-19Enable schsio(4) everywhere to get it tested.Michael Knudsen
``please commit'' deraadt
2009-04-19For consistency, make sure that all archs that use the same patternOwain Ainsworth
always increment uvmexp.softs while inside the lock. While i'm here, make alpha's dispatch loop look like the rest. "sure" miod@
2009-04-19Count number of cpus found (potentially not attached) and store thatTheo de Raadt
in sysctl hw.ncpufound; ok miod kettenis
2009-04-19Switch the softinterrupt code on x86 over to mutexes instead ofOwain Ainsworth
simplelocks + splhigh(). First part of making it possible to make mpsafe softinterrupts. "oh yes, definitely" miod@
2009-04-15The current iommu code only touches the hardware if the bios did notOwain Ainsworth
enable it (I have found the code that does enable it problematic on quite a few machines, however, that's a different issue). So provide some code that so if the bios initialised the iommu for us, we'll use what it gave us. Makes iommu work on a machine of todd's. while i'm here, we don't need to scan all pci functoins to find the hypertransport bridge. the gart is always on function 3, so just scan for all the bridges and not iterate over the functions too. Thanks to todd for his infinite patience while I gave him diffs that went ``Boom!''.
2009-04-15fix properly; size gets decremented while we check the segments, so save it soOwain Ainsworth
when we setmapsize it's not zero. *sigh*
2009-04-15make load_raw do the same as the others and set mapsize and nsegs toOwain Ainsworth
zero so that we return an empty map on error.
2009-04-15bus_dmamap_load_raw didn't set map->dm_mapsize on successful load.Owain Ainsworth
I just spent five hours looking in the wrong place because of this.
2009-04-14Convert the waitok field of uvm_pglistalloc to "flags", more will be added soon.Owain Ainsworth
For the possibility of sleeping, the first two flags are UVM_PLA_WAITOK and UVM_PLA_NOWAIT. It is an error not to show intention, so assert that one of the two is provided. Switch over every caller in the tree to using the appropriate flag. ok art@, ariane@
2009-04-14enable ix(4).Jonathan Gray
ok reyk@
2009-04-13Ignore zero-sized regions from the BIOS memory map when reserving root PCIMark Kettenis
bus address space. Fixes a problem reported by david@.
2009-04-11Create extents for resource accounting on the root PCI bus and populate themMark Kettenis
based on the BIOS memory map.
2009-04-11There is no support for building multi-socket machines in AMD Family 11hMark Kettenis
processors, so the registers to configure addition HyperTransport links are absent. Don't try attaching addition pci busses on these processors to avoid probing non-existant registers.
2009-04-09in bus_dmamap_load_raw, only map the requested number of bytes into theDavid Gwynne
dmamap rather than all the bytes that are described by the sg list we're mapping. tested on iwn by me and beck@
2009-04-09unrevert marco's revert of my bus_dmamap_load_raw change now that i foundDavid Gwynne
the bug in it. bugfix will be committed next. make bus_dmamap_load_raw respect the constraints of the dmamap we're loading the raw memory into, particularly the segment size constraint.
2009-04-08Rever _raw change from dlg because it breaks iwn.Marco Peereboom
ok oga
2009-04-04Remove an unused function inherited from NetBSD that deals with a brokenMark Kettenis
SiS chipset that we'll never see on and amd64 machine. ok oga@
2009-04-04Remove unused #include.Mark Kettenis
2009-04-04make bus_dmamap_load_raw respect teh constraints of the dmamap we'reDavid Gwynne
loading the raw memory into, particularly the segment size constraint. written in june/july last year, but my studies held me back from handling it.
2009-03-31bzero pci attach argsMark Kettenis
2009-03-31- remove obsolete commentArtur Grabowski
- remove dead (#if 0) code - move switch_error panics to after cpu_switchto to make branch prediction happier and the code more readable. no functional change
2009-03-30make the code look the same; ok kettenisTheo de Raadt
2009-03-30Remove the direct uncached map. All its users have been removed.Owain Ainsworth
In the future, we need to mark the correct parts of the direct map uncached, but that's another diff. art@, kettenis@ ok.
2009-03-26Change amd64 bus_space_{map,unmap} to be the same as i386. WhileOwain Ainsworth
theoretically the current solution of using the direct (and direct uncached) maps is better for tlb pressure, two direct maps is dangerous, especially when we support Page Attribute Tables (soon), since that will cause illegal cache aliases. When that work is done a clever solution may be worked out. "reluctant ok, the uncached direct map is evil" art@
2009-03-26Remove cpu_wait(). It's original use was to be called from the reaper soOwain Ainsworth
MD code would free resources that couldn't be freed until we were no longer running in that processor. However, it's is unused on all architectures since mikeb@'s tss changes on x86 earlier in the year. ok miod@
2009-03-24link otus(4) to the build on i386 and amd64.Damien Bergamini
2009-03-23Add missing dependency generation for assym.h (...the lack of whichPhilip Guenthe
made testers of art's affinity diff go insane) ok krw@ miod@
2009-03-23Processor affinity for processes.Artur Grabowski
- Split up run queues so that every cpu has one. - Make setrunqueue choose the cpu where we want to make this process runnable (this should be refined and less brutal in the future). - When choosing the cpu where we want to run, make some kind of educated guess where it will be best to run (very naive right now). Other: - Set operations for sets of cpus. - load average calculations per cpu. - sched_is_idle() -> curcpu_is_idle() tested, debugged and prodded by many@
2009-03-15Introduce splsoftassert(), similar to splassert() but for soft interruptMiod Vallat
levels. This will allow for platforms where soft interrupt levels do not map to real hardware interrupt levels to have soft ipl values overlapping hard ipl values without breaking spl asserts.
2009-03-11Attach iommu on AMD family 10h processors (e.g. phenom) too.Owain Ainsworth
11h (Turion) still needs testing, so isn't part of this commit. ok reyk@, marco@
2009-03-10First step in cleaning up amd64 iommu.Owain Ainsworth
Firstly, don't keep identical data for each of the GARTs (we keep them in sync, but there is one per cpu socket), all that varies is the pci_tag_t, so just keep an array of those and have the rest of the information once. Secondly, don't keep the softc as a global, use the _cookie field of the dmatag_t, that's what it's there for. Finally, use dmamap_map to map the page tables, instead of the direct NC map. This is because later changes to support PAT will be a lot easier with one direct map (where we change the cacheability if needed), since otherwise it's just asking for illegal cache aliases. More changes will be upcoming. Tested by a few people, with an without bigmem, thanks to those. weingart@ liked the direction this is going, marco@ and kettenis@ oked it.
2009-03-10remove the _BUS_DMA_PRIVATE define from amd64 and i386.Owain Ainsworth
a define needed to get to ``private'' functions that needs to be defined 5 or more times isn't much use and may cause namespace issues anyway. Other archs will probably follow. Discussed in portugal. "Hell yes" weingart@, ok kettenis@, no objections miod@
2009-03-10Enable VMware VMXnet Virtual Interface Controller (vic) driverJonathan Gray
on amd64 as well. ok dlg@
2009-03-10enable urtw(4)Kevin Lo
ok jsg@
2009-03-07When allocating memory in bus_dmamem_alloc() with uvm_pglistalloc(), do notMiod Vallat
try to be smart for the address range, uvm_pglistalloc() is smart enough nowadays.
2009-02-26Add a two new ioctls to the apm(4) interface.Owain Ainsworth
APM_IOC_{SUSPEND,STANDBY}_REQ: This is to fix an issue with apm suspend where a call to zzz suspended the machine immediately, not giving anyone listening for apm events (other than apmd) a chance to deal with the upcoming change. This hit X hard since the introduction of drm, since it needs to have time to idle the 3d engine and otherwise get the device into a recoverable state. Such things are needed until we support modesetting in the kernel. Now, instead of forcing a suspend, using ioctl sends out an event similar to if you had put the lid down, giving all userland applications a chance to reply. tested by sthen@ and beck@, especial thanks to sthen for sitting there while I tried to debug this remotely, I owe him beer. Prompted by and ok deraadt@
2009-02-25enable ale(4) on both i386 and amd64Kevin Lo
ok deraadt@
2009-02-24match new cpuid stuff from i386; by jsgTheo de Raadt
ok toby and tedu
2009-02-24back out est.c 1.8 and bring acpicpu.c all the way back to 1.47 because ofTheo de Raadt
hanging machines. backed out correctly this time, as pointed out by tedu.
2009-02-19suspend/resume bits so that we can develop this in tree. This is disabled.Marco Peereboom
code from mlarkin and me help from art,toby,jordan and several others ok jordan, go for it deraadt
2009-02-16Cancel the automatic boot when you hold ctrl to skip boot.conf.Stuart Henderson
"I like it" deraadt "sweet" tedu "love it" marco
2009-02-16remove incorrect cast of pcb_cr3. okay kettenis@ weingart@Kurt Miller
2009-02-16Core i7 chips don't have MSR_TEMPERATURE_TARGET register, and blow upKenneth R Westerback
if attempts are made to read it. So read MSR_TEMPERATURE_TARGET only when ci_model == 0xe. Found when my Core i7 box blew up. FreeBSD allows a few more chips but this allows my box to boot. ok jsg@