Commit Graph

357 Commits

Author SHA1 Message Date
christos
a640264e31 Merge db_trace for x86. From: Vladimir Kirillov proger at wilab dot org dot ua 2011-04-10 20:36:48 +00:00
jruoho
ad932f2c35 Move PowerNow! to the cpufeaturebus. 2011-02-24 10:56:00 +00:00
rmind
7c940b718e Unify i386 and amd64 procfs MD code into x86. 2010-07-08 11:24:59 +00:00
jruoho
039f34b662 Move vald(4) to sys/dev/acpi. This is MI and should work also on amd64.
ok jmcneill@

XXX:    This is broken: it calls methods with absolute pathnames (almost
        guaranteed not to be portable across models), it accesses methods
        that are in the domain of other drivers, it walks the namespace on
        its own, it contains plenty of magic constants, it does not
        integrate with existing KPIs, etc. Summa summarum: this should be
        rewritten as a more generic toshiba_acpi(4).
2010-04-10 17:55:24 +00:00
dholland
39e9a9ec1a One last bit of whitespace from PR kern/22595. 2010-01-03 04:06:31 +00:00
dyoung
e48f8429d1 Add a kernel configuration flag, SPLDEBUG, that activates a per-CPU log
of transitions to IPL_HIGH from lower IPLs.  SPLDEBUG is only available
on i386 and Xen kernels, today.

'options SPLDEBUG' adds instrumentation to spllower() and splraise() as
well as routines to start/stop debugging and to record IPL transitions:
spldebug_start(), spldebug_stop(), spldebug_raise(), spldebug_lower().
2009-11-03 05:23:27 +00:00
christos
574b39dfa6 move spic to common acpi. 2009-08-09 19:35:02 +00:00
bouyer
3ac2dfe9bf Split mc146818-related functions from clock.c into rtc.c.
Call rtc_set_ymdhms() from xen/xen/clock.c:xen_rtc_set() for xen3 dom0
kernels as the Xen3 hypervisor doesn't write the new date/time to the CMOS
by itself.
Now a XEN3_DOM0 kernel properly updates the CMOS time.
2009-06-16 21:05:33 +00:00
nonaka
e0297d1ead Added SD/MMC support from OpenBSD.
tested on i386, amd64 at current-users ML by pgoyette@.
tested on zaurus by myself.
2009-04-21 03:00:29 +00:00
rmind
3de18e79b4 - Add macros to handle (some) trapframe registers for common x86 code.
- Merge i386 and amd64 syscall.c into x86.  No functional changes intended.

Proposed on (port-i386 & port-amd64).  Unfortunately, I cannot merge these
lists into the single port-x86. :(
2009-04-16 15:34:23 +00:00
rmind
44170e3c3a Merge i386 and amd64 ipifuncs.c into x86. No functional changes intended.
XXX: fpu #ifdefs are ugly (should be revisited at some point).
2009-03-30 22:28:39 +00:00
rmind
70456c4d9e Merge i386 and amd64 vm_machdep.c into x86. No functional changes intended.
Note: some #ifdefs will be removed with macros.
2009-03-30 22:20:55 +00:00
rmind
74a033c8eb Merge/move core_machdep.c into x86, no difference between i386 and amd64. 2009-03-30 22:13:42 +00:00
jmcneill
f654d345dd Mark old vesabios/vesafb flags as obsolete, noted by cube 2009-02-19 13:06:49 +00:00
jmcneill
08224a94a7 Remove vesafb, it has been replaced by genfb on x86. 2009-02-19 00:54:08 +00:00
cube
df0059e2e8 Don't set version deep in the source tree if it's older than the one in
conf/files.
2009-02-14 20:22:59 +00:00
ad
5e34fbf90e - Kill NOREDZONE.
- Make the redzone conditional on DIAGNOSTIC.
- Give amd64 an additional page for the uarea. 2 is not enough.
2008-12-20 12:41:19 +00:00
ad
8551373dea Put the COMPAT_NOMID stuff into its own file. 2008-11-20 10:53:08 +00:00
ad
92ce8c6a3d Make the emulations, exec formats, coredump, NFS, and the NFS server
into modules. By and large this commit:

- shuffles header files and ifdefs
- splits code out where necessary to be modular
- adds module glue for each of the components
- adds/replaces hooks for things that can be installed at runtime
2008-11-19 18:35:57 +00:00
christos
a41d00937d pointless to compile md_root.c without md.c 2008-06-13 17:26:33 +00:00
jmcneill
9709f2afe2 Add support for PCI_BUS_FIXUP and PCI_ADDR_FIXUP on amd64. 2008-05-18 02:06:14 +00:00
ad
50d8ae9d14 Simplify x86 identcpu code, and share between i386/amd64. 2008-05-11 14:44:53 +00:00
dyoung
db4cb7c623 Commit straggler: elansc now attaches to something that provides
the 'pcibus' interface instead of the 'pci' interface.
2008-04-10 06:53:12 +00:00
xtraeme
c524510b66 Split off the Transmeta Crusoe Longrun code into its own file, that
way identcpu.c and machdep.c are not cluttered with foreign code.

The driver is built by default as before, but the sysctl subtree will
only be created if longrun is detected and not always as the old code
did. This matches what the FreeBSD code does.

Ok by christos@.
2008-02-26 18:24:28 +00:00
drochner
bb33f35f20 Since files.wscons et al. are included by ~all ports anyway, include
them in the mi "files" file, and remove include statements from md files.
These shouldn't pull in additional kernel code when not in use, so it
shouldn't do any harm except a risk of namespace collisions which
should be easy to fix.
2008-02-20 21:43:33 +00:00
joerg
6e869e402d Refactor in_cksum/in4_cksum/in6_cksum implementations:
- All three functions are included in the kernel by default.
  They call a backend function cpu_in_cksum after possibly
  computing the checksum of the pseudo header.
- cpu_in_cksum is the core to implement the one-complement sum.
  The default implementation is moderate fast on most platforms
  and provides a 32bit accumulator with 16bit addends for L32 platforms
  and a 64bit accumulator with 32bit addends for L64 platforms.
  It handles edge cases like very large mbuf chains (could happen with
  native IPv6 in the future) and provides a good base for new native
  implementations.
- Modify i386 and amd64 assembly to use the new interface.

This disables the MD implementations on !x86 until the conversion is
done. For Alpha, the portable version is faster.
2008-01-25 21:12:10 +00:00
dyoung
42bde7e9fa Attach two new devices to the AMD Elan SC520 System Controller,
elansc(4).

elanpex(4) is for PCI exception reporting.  I've already found some
kernel bugs by reading the exceptions reported.  Beware that it
will spam the console a lot while the kernel and pcictl(8) probe
non-existing addresses in PCI configuration space.

elanpar(4) protects the kernel text from writes by the CPU and by
PCI bus masters.  As you might guess, this is not compatible with
setting breakpoints using a debugger; detach the device using
'drvctl -d elanpar0' before you try to set breakpoints.  In the
future, I hope to extend elanpar(4) to provide general-purpose RAM
write-protection.
2008-01-21 08:04:51 +00:00
ad
dfe83e08ca Remove options MATH_EMULATE. 2008-01-16 09:37:04 +00:00
ad
ee652e42b1 - Split crashdump code out into its own file.
- Remove NO_SPARSE_DUMP.
- Minor KNF, sprinkle static.
2008-01-12 20:03:41 +00:00
xtraeme
810aa8579e Add gcscpcib(4): a driver for the AMD CS5535 and CS5536 Companion Device
that acts as PCI-ISA bridge and supports a Timecounter, Watchdog Timer
and GPIO.

Adapted by Yojiro UO and minor tweaks by me from OpenBSD. Tested on
CS5535 and CS5536. This closes PR kern/37577.
2008-01-09 14:23:46 +00:00
ad
0805a9416a Add MODULAR option. Include kernel linker stuff if MODULAR. 2008-01-06 18:03:58 +00:00
joerg
2b35d82f32 Add PHYSMEM_MAX_ADDR and PHYSMEM_MAX_SIZE options. This limit physical
memory based on overall size (useful for debugging to keep core dumps
small) or maximum address (when using devices with bus dma limits).
Contrary to REALBASEMEM and REALEXTMEM, they still use the BIOS memory
map and can therefore deal with fragmented memory.
2007-12-26 16:28:15 +00:00
jmcneill
9f7f6d9be0 Move Sony Notebook Controller (sony(4)) driver from MD to MI directory,
as it can be used on amd64 as well.
2007-12-23 17:29:26 +00:00
joerg
870cffb0ab Add new IPI for saving CPU state explicitly, share high-level part of
ACPI wakeup code and teach it how to start the APs again. As a side
effect the CPU_START interface allows choosing between different
bootstrap codes more easily now.
2007-12-18 07:17:08 +00:00
jmcneill
4c1d81b2b5 Merge jmcneill-pm branch. 2007-12-09 20:27:42 +00:00
bouyer
4e54134323 Pull up the bouyer-xenamd64 branch to HEAD. This brings in amd64 support
to NetBSD/Xen, both Dom0 and DomU.
2007-11-22 16:16:40 +00:00
ad
deae4f32c5 Remove support for 80386 level CPUs. PR port-i386/36163. 2007-11-15 19:18:32 +00:00
ad
9014362808 - Remove I486_CPU, I586_CPU, I686_CPU options. They buy us nothing and
clutter the code significantly.
- Remove pccons.
2007-11-14 17:54:56 +00:00
xtraeme
7e8be191f1 Share pcib(4) and amdpcib(4) between i386 and amd64; one copy is enough. 2007-10-26 22:17:13 +00:00
xtraeme
3338a139da - Share pchb(4) between i386 and amd64; one copy is enough for both.
- Move some of the x86 PCI devices into x86/pci/files.pci.
- Add more x86 stuff into x86/conf/files.x86.

ok joerg.
2007-10-26 21:49:50 +00:00
yamt
24a1632cb3 merge yamt-x86pmap branch.
- reduce differences between amd64 and i386.  notably, share pmap.c
  between them.  it makes several i386 pmap improvements available to
  amd64, including tlb shootdown reduction and bug fixes from Stephan Uphoff.
- implement deferred pmap switching for amd64.
- remove LARGEPAGES option.  always use large pages if available.
  also, make it work on amd64.
2007-10-18 15:28:31 +00:00
garbled
d974db0ada Merge the ppcoea-renovation branch to HEAD.
This branch was a major cleanup and rototill of many of the various OEA
cpu based PPC ports that focused on sharing as much code as possible
between the various ports to eliminate near-identical copies of files in
every tree.  Additionally there is a new PIC system that unifies the
interface to interrupt code for all different OEA ppc arches.  The work
for this branch was done by a variety of people, too long to list here.

TODO:
bebox still needs work to complete the transition to -renovation.
ofppc still needs a bunch of work, which I will be looking at.
ev64260 still needs to be renovated
amigappc was not attempted.

NOTES:
pmppc was removed as an arch, and moved to a evbppc target.
2007-10-17 19:52:51 +00:00
ad
9c412e0cbf x86 changes for pcc and LKMs.
- Replace most inline assembly with proper functions. As a side effect
  this reduces the size of amd64 GENERIC by about 120kB, and i386 by a
  smaller amount. Nearly all of the inlines did something slow, or something
  that does not need to be fast.
- Make curcpu() and curlwp functions proper, unless __GNUC__ && _KERNEL.
  In that case make them inlines. Makes curlwp LKM and preemption safe.
- Make bus_space and bus_dma more LKM friendly.
- Share a few more files between the ports.
- Other minor changes.
2007-09-26 19:48:34 +00:00
ad
fbb58ada61 Merge most x86 changes from the vmlocking branch, except the threaded soft
interrupt stuff. This is mostly comprised of changes to the pmap modules to
work on multiprocessor systems without kernel_lock, and changes to speed up
tlb shootdowns.
2007-08-29 23:38:01 +00:00
xtraeme
031bec6d2c Some changes for the ichlpcib driver:
- Moved to x86/pci, so that EM64T systems running NetBSD/amd64 can use it.
- Added support for the TCO on ICH6 or newer chipsets, adapted from
  FreeBSD.
- Added timecounter support for the power management timer, adapted from
  OpenBSD.
- Plus some misc/cosmetic changes.

Thanks to yukonbob on irc@freenode for testing the TCO part on ICH4-M.
Tested by me with ICH7 too.
2007-08-26 16:49:47 +00:00
jmcneill
424b422ccd Add gcscehci(4), an EHCI glue driver for the AMD CS5536 companion
controller. This driver enables USB 2.0 high speed support on the
Soekris net5501 (comBIOS ver. 1.31m).
2007-07-08 01:13:26 +00:00
tsutsui
6a8a584d1a Remove leftover netns stuff. 2007-07-07 05:13:14 +00:00
xtraeme
a5ac7ff5aa Import i386/gcscide(4). A driver for the IDE Controller of the
AMD CS5535 Companion device found in the decTOP.

gcscide0 at pci0 dev 15 function 2
gcscide0: National Semiconductor/AMD CS5535 IDE Controller (rev. 0x00)

Supports Ultra DMA mode 4, Pio Mode 4 and MDMA mode 2.

"Go for it" jmcneill@.
2007-06-27 23:02:52 +00:00
jmcneill
f269d91119 Import driver for the AMD Geode LX AES Security Block, from OpenBSD. The
glxsb(4) driver provides random numbers and AES acceleration.
2007-06-15 23:02:20 +00:00
xtraeme
583a110ce0 Remove Enhanced Speedstep stuff from here, it's defined on files.x86
now.
2007-06-03 19:37:50 +00:00