Commit Graph

489 Commits

Author SHA1 Message Date
skrll 28d6e7ce06 Fix the CPU #ifdefs 2012-01-03 06:18:24 +00:00
skrll fb2a616612 From OpenBSD...
Fix encoding of DIAG instructions in the MFCPU_T and MTCPU_T macros. MTCPU_T
was encoded as a read instruction, while MFCPU_T was encoded as a
read-through-TH instruction, although the only uses of it concern registers
read through CH.

(You are not supposed to understand this, this is a dark corner of undocumented
rotten PA-RISC bowels).

Cache SID hashing will now correctly be disabled on PCXS, PCXT and PCXT'
processors.

Proper encoding from the old PA-RISC mklinux sources; tested on 720 (PCXS)
and 715/75 (PCXT); ok kettenis@
2012-01-02 16:13:12 +00:00
skrll e51a4c0759 When converting a floating value to an integer, properly raise the "invalid"
exception when the floating value is infinite or NaN or if the integral part
of the floating value exceeds the range of the integer type, as required by
the C99/IEEE754 standard.

Fixes Python 2.6 build on hppa.

From OpenBSD.
2012-01-01 20:04:36 +00:00
skrll 7093284c3d Fix the usage/help for mach frame. 2011-12-31 08:34:49 +00:00
skrll bdd6bbb62b G/C pmap_page_remove_locked prototype. 2011-12-30 07:41:58 +00:00
skrll dea4c976f9 Cope with userland mappings of unmanaged pages (i.e. device memory being
mmap'ed), by properly making these mappings uncached, and correctly accounting
their removal to not get stuck with leftover pte pages.

From OpenBSD.
2011-12-30 07:25:00 +00:00
skrll a03c8eece6 No need for sync_caches - f[di]cache already issue the sync instruction. 2011-12-29 22:13:23 +00:00
skrll 8d30f00ce9 Whitespace. 2011-12-23 16:38:50 +00:00
skrll ef7ea2cdf4 Define PMAP_NEED_PROCWR and provide pmap_procwr so that the i-cache is
synchronised with the d-cache appropriately.
2011-12-23 16:35:00 +00:00
skrll 3afe955de9 Whitespace. 2011-12-16 13:38:44 +00:00
skrll 4f97a985c4 G/C pvh_aliases 2011-12-16 12:45:04 +00:00
skrll 30d371dd7e Fix DIR21L relocations where we missed a bit of 'b'
Add support for DPREL relocations.

Modulo debug information in modules /usr/tests/modules now passes all
tests on NetBSD/hp700 (with a MODULAR kernel)
2011-12-13 12:55:50 +00:00
skrll 30fe64d81b Track if we saved l_private in the mcontext and don't blindly restore it.
This fixes the tests in /usr/tests/lib/libc/setjmp/t_threadjmp
2011-12-08 21:00:49 +00:00
skrll fdb4331779 Whitespace. 2011-12-05 07:34:50 +00:00
chs edf71167bd fix EXIT label for fusufault, caught by new binutils. 2011-10-01 15:50:46 +00:00
joerg 3eb244d801 Retire varargs.h support. Move machine/stdarg.h logic into MI
sys/stdarg.h and expect compiler to provide proper builtins, defaulting
to the GCC interface. lint still has a special fallback.
Reduce abuse of _BSD_VA_LIST_ by defining __va_list by default and
derive va_list as required by standards.
2011-07-17 20:54:30 +00:00
matt 90ee15e239 Fix FLT_* and DBL_* redefinition problem. 2011-07-11 02:54:04 +00:00
matt 7555545545 Add defines for extu_frac[ln]m 2011-07-10 04:49:37 +00:00
mrg 8f21de0400 port to GCC 4.5. 2011-07-07 01:27:13 +00:00
rmind e225b7bd09 Welcome to 5.99.53! Merge rmind-uvmplock branch:
- Reorganize locking in UVM and provide extra serialisation for pmap(9).
  New lock order: [vmpage-owner-lock] -> pmap-lock.

- Simplify locking in some pmap(9) modules by removing P->V locking.

- Use lock object on vmobjlock (and thus vnode_t::v_interlock) to share
  the locks amongst UVM objects where necessary (tmpfs, layerfs, unionfs).

- Rewrite and optimise x86 TLB shootdown code, make it simpler and cleaner.
  Add TLBSTATS option for x86 to collect statistics about TLB shootdowns.

- Unify /dev/mem et al in MI code and provide required locking (removes
  kernel-lock on some ports).  Also, avoid cache-aliasing issues.

Thanks to Andrew Doran and Joerg Sonnenberger, as their initial patches
formed the core changes of this branch.
2011-06-12 03:35:36 +00:00
joerg a2bf8e5d19 Introduce DDB_EXPR_FMT and replace the logic around DB_EXPR_T_IS_QUAD. 2011-05-26 15:34:12 +00:00
skrll 5dea138bb6 HPPA TLS support. 2011-03-17 22:14:43 +00:00
skrll 1ec0684c4b Deal with cr27 in process_{read,write}_regs 2011-03-03 09:37:21 +00:00
skrll 01a744c41e Add the trapframe pointer to the syscall information. 2011-02-28 21:24:25 +00:00
skrll 3c6d72d744 __HAVE___LWP_GETPRIVATE_FAST works now. 2011-02-28 21:23:33 +00:00
skrll 641cef61dc Don't use %tr3 (aka cr27) in emu trap. cr27 is now used for lwp private
info.
2011-02-28 21:22:35 +00:00
skrll 0dad921873 Remove old/incorrect comment. 2011-02-28 21:20:50 +00:00
skrll 5a6623c3f0 Whitespace. 2011-02-26 07:54:48 +00:00
skrll 08ab7fd006 Add a comment. 2011-02-26 07:53:47 +00:00
skrll 80322835aa (Attempt to) bundle some stw/ldws and remove redundant CR_TLS save. 2011-02-26 07:52:32 +00:00
joerg 13b2e74237 Be nicer to software that insists on -ansi and use __inline. 2011-02-25 14:07:12 +00:00
skrll 312d24df76 Get sr4 in cpu_getmcontext.
hi joerg.
2011-02-24 08:59:22 +00:00
skrll 04cc8d36f4 No need to save CR_TLS twice in the DDB case.
hi joerg.
2011-02-24 08:57:39 +00:00
joerg 1631a78097 Allow storing and receiving the LWP private pointer via ucontext_t
on all platforms except VAX and IA64. Add fast access via register for
AMD64, i386 and SH3 ports. Use this fast access in libpthread to replace
the stack based pthread_self(). Implement skeleton support for Alpha,
HPPA, PowerPC, SPARC and SPARC64, but leave it disabled.

Ports that support this feature provide __HAVE____LWP_GETPRIVATE_FAST in
machine/types.h and a corresponding __lwp_getprivate_fast in
machine/mcontext.h.

This material is based upon work partially supported by
The NetBSD Foundation under a contract with Joerg Sonnenberger.
2011-02-24 04:28:41 +00:00
matt a5e30bea72 Put RCSIDs in section .ident. (use .pushsection/.popsection) 2011-02-12 16:31:32 +00:00
pooka 22c822c7f3 Make vmapbuf() return success/error and make physio deal with a
failure.
2011-02-10 14:46:44 +00:00
rmind 9b6bd2d968 Remove clause 3 (UCB advertising clause) from the University of Utah
copyright.  Confirmed by Mike Hibler, mike at cs.utah.edu - thanks!
Also, merge UCB and Utah copyright texts back into one, as they
originally were.

Extra verification by snj@.
2011-02-08 20:20:06 +00:00
skrll b0db353f1b Fix PR/44500 for hppa. 2011-02-07 12:19:35 +00:00
skrll 7ab26f0f09 Grammar. 2011-01-30 22:36:37 +00:00
skrll e0309a99f9 Tweak a comment. Suggestion from rmind@. 2011-01-30 22:36:12 +00:00
skrll 22dc156396 Don't use magic constant. 2011-01-30 10:09:23 +00:00
skrll 773417849f Whitespace. 2011-01-30 09:58:03 +00:00
skrll 299a7684c7 Detect and spin up non-boot CPUs.
Mostly from OpenBSD.
2011-01-23 21:53:39 +00:00
skrll 16d5fda989 Make some more information (psw/fpu_state) per cpu. 2011-01-23 09:44:58 +00:00
skrll 2fd642d363 A couple more registers and their common usage. 2011-01-22 20:24:48 +00:00
skrll 5a4e5babba Save CR24 and CR27 and report in ddb. 2011-01-22 19:35:47 +00:00
skrll 800ee8c445 Have the register number and usage available. 2011-01-22 19:25:01 +00:00
skrll 823dd936c8 Whitespace. 2011-01-22 19:21:40 +00:00
skrll 6d19229feb First attempt at MP _lock_cas. 2011-01-22 19:10:16 +00:00
skrll 2a78b12bfe Fix MULTIPROCESSOR curlwp/curcpu handling. 2011-01-22 10:57:07 +00:00