Commit Graph

3078 Commits

Author SHA1 Message Date
mrg
32d2ab845e fix the zx@fhc attachment. 2011-08-01 10:18:23 +00:00
mrg
a14d5855e1 use device_private(). thanks to jmcneill for pointing this out. 2011-08-01 08:36:39 +00:00
martin
95377927e5 Get rid of #ifdef __sparc__ in uvm code - as noted by cgd back 1996,
now that we have __HAVE_CPU_VMSPACE_EXEC/cpu_vmspace_exec().
2011-07-30 19:29:12 +00:00
mrg
39a57b1caa port the openbsd central and fhc drivers, and the clock/zs attachments.
doesn't quite work yet, crashes when central_attach() calls
config_attach() (faulting address is 0xf8000000.)
2011-07-29 08:37:36 +00:00
nakayama
81762e2b5f Don't attach same ivec's event coutner more than once. They are
difficult to distinguish since they are handled by intr_list_handler.
2011-07-27 21:50:16 +00:00
nakayama
ffaed6f279 ivec is assigned to hardware, so count its event counter up in
interrupt_vector, not in softint, and do some optimization.
2011-07-27 20:07:49 +00:00
jakllsch
4ada5b7e5e Enable or note aubtfwl(4) wherever ubt(4) is enabled or noted. 2011-07-23 21:12:57 +00:00
martin
e81042abcf Enable DIAGNOSTIC by default 2011-07-23 19:14:37 +00:00
macallan
33f3feb81b add per ivec event counters 2011-07-20 12:06:00 +00:00
macallan
d1b2ece17f some malloc() -> kmem_alloc() 2011-07-20 10:39:43 +00:00
dyoung
9c93e701a6 Switch sparc and sparc64 to new-style <sys/bus.h>. 2011-07-17 23:29:10 +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
mrg
f31d8e575a rename sparc64 BLOCK_SIZE and BLOCK_ALIGN to have SPARC64_ prefixes.
for the assembler files, define the old names to the new names
since using the new names cause ugliness due to longer identifer
names, and reduces churn.

fixes build issues in dtv and vaguely makes <machine/psl.h> slightly
less name-space invasive.
2011-07-12 07:51:33 +00:00
mrg
3e0afb42a3 sparc64 with GCC 4.5 has about a 2% code bloat, unfortunately.
bump the instfs size to 9MB.
2011-07-10 08:51:24 +00:00
dyoung
9c4afb0ddd Don't install sparc64/bus.h any more. 2011-07-09 17:15:46 +00:00
mrg
d551e1eb60 apply some (uintptr_t) between pointer and int assignments. 2011-07-09 15:03:35 +00:00
mrg
57aacd8a5d redo previous correctly:
don't try to print fr_arg[6] since it doesn't exist.
2011-07-02 13:11:48 +00:00
dyoung
9aff02ebc1 #include <sys/bus.h> instead of <machine/bus.h>. 2011-07-01 20:57:45 +00:00
dyoung
b6584574fc #include <sys/bus.h> instead of <machine/bus.h>. 2011-07-01 18:41:51 +00:00
dyoung
59adf08e17 Per discussion at
<http://mail-index.netbsd.org/tech-kern/2010/04/02/msg007941.html>,
divide each machine's bus.h into bus_defs.h (constants & data types)
and bus_funcs.h (macro implementations of bus_space(9) routines and MD
prototypes).

Note that some bus_space(9) routines' implementation will move to .c
files from inline subroutines or macros in .h files.

I've only made the split for machine architectures where there is PCI.
All of the non-PCI-having architectures will require a similar split.

These #include files are not referenced by any (committed) Makefiles or
header files, yet.  Changes to Makefiles, to <sys/bus.h>, and to some
more machine-dependent files will dribble in before I throw the switch.
2011-07-01 17:09:58 +00:00
mrg
7e433992a7 use the right variables for the fp and pc, and avoid array bounds
violations.
2011-07-01 08:37:28 +00:00
wiz
4cbd24b23f dependant -> dependent 2011-06-30 20:09:15 +00:00
nakayama
493fed0c2e No need to repeat checking want_resched then call preempt() in
T_AST case, so check it only once.
2011-06-23 13:39:40 +00:00
mrg
2ba5b6cced there's no fr_arg[6] or fr_arg[7] -- they're called fr_fp and fr_pc.
use the right names and avoid some array bounds violations picked up
by GCC 4.5.  it's a real bug, but the code would have been generated
correctly for the sparc* ABIs.
2011-06-22 05:50:47 +00:00
pgoyette
d9b90a6705 Initialize sensor states before registering. 2011-06-20 17:01:45 +00:00
nakayama
17e0aea6a2 Remove frame32 hack with using the same trick in netbsd32_machdep.c. 2011-06-20 09:25:48 +00:00
nakayama
93c3c7c14f Limit reading from registers at most once every second with using
ratecheck(9).
2011-06-19 21:37:10 +00:00
nakayama
74bd9793c1 Add fast softint(9) support for sparc64.
Reviewed on port-sparc64.
2011-06-18 18:51:17 +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
mrg
4138bf2744 convert dcache_flush_page() into a function pointer. introduce a
sp_dcache_flush_page() to help the smp version.

XXX: probably best to have usI/II and usIII (and nop) of this and
XXX: avoid the need for sp_dcache_flush_page at all.
2011-06-06 02:49:39 +00:00
mrg
fd360a0fec sort 2011-06-06 01:23:31 +00:00
mrg
5f30cba72a re-implement blast_dcache() and blast_icache() via function pointers so that
we can set these to functions that simply return on sun4us/sun4v systems.

also include some work-in-progress #if 0'ed code to do the same for the
dcache_flush*() functions.


(some of these could probably move into the cpuinfo except that sparc64
systems don't really ever work with mismatches AFAICT.)
2011-06-06 01:16:48 +00:00
christos
0fa0719a9a forgot _NEW again. 2011-06-03 03:21:12 +00:00
christos
817999e9d9 CFATTACH_DECL_NEW 2011-06-03 03:20:39 +00:00
christos
88655ce235 CFATTACH_DECL_NEW 2011-06-03 03:05:21 +00:00
christos
0cdde954ce forgot _NEW 2011-06-03 03:02:36 +00:00
christos
a9190d7f6d forgot the _NEW part 2011-06-03 03:02:12 +00:00
christos
40babd3eb8 CFATTACH_DECL_NEW 2011-06-03 03:01:23 +00:00
christos
ae8fd9fd91 CFATTACH_DECL_NEW 2011-06-03 02:48:33 +00:00
christos
d27a3b5952 more CFATTACH_DECL_NEW fixes 2011-06-03 02:33:27 +00:00
christos
4fc6381ab4 split mainbus 2011-06-02 00:35:23 +00:00
christos
d92ab1d44a split auxio, ebus, psycho, sab. 2011-06-02 00:24:23 +00:00
mrg
0d643fd11f also look for "FJSV,su" as found on PRIMEPOWER machines.
while here, copy some code from openbsd that should allow this to work
on the Fujitsu SPARC Enterprise Mx000 systems.
2011-06-02 00:16:22 +00:00
mrg
705a46009a convert stackdump() to look up symbols rather than dumping raw %pc values. 2011-06-01 23:41:04 +00:00
macallan
01de9909d6 allow display devices to work if they have been set up by OF even of they're
not the firmware console. While there get rid of some more code carried over
from macppc that doesn't work on sparc64 and consistently use node vs.
console_node.
2011-06-01 16:00:10 +00:00
nakayama
9c3fe3cc10 Fix 32-bit kernel build. 2011-05-27 12:41:18 +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
mrg
b6a024784e define MANUF_FUJITSU (and fix CPU_IS_SPARC64_V_UP()) and MANUF_SUN.
use CPU_IS_SPARC64_V_UP() to choose some US-III versions of some
cache functions.
2011-05-25 12:01:30 +00:00
mrg
bb85999d1f for SPI devices, allow platform code to set "scsi-initiator-id" device
property, and if set, use it instead of pfp.PortSCSIID.

on sparc64 systems on "scsi" or "scsi-2" devices, look from our node
up the tree for a "scsi-initiator-id" property, and if present, copy
it into the device properties.

this fixes mpt(4) issues on PRIMEPOWER250 (and probably other) systems.
idea from freebsd r207243/r207287, but reworked to use our device
properties instead of platform #ifdefs.


look in "device_type" as well as "name" for "ethernet" or "network",
and also look to see if a "local-mac-address" is set when choosing if
this may be a network device.  fixes bge(4) nul ethernet address on
the same PRIMEPOWER250.
2011-05-24 10:08:03 +00:00
mrg
6cc4338539 also match the fujitsu sab: "FJSV,se" (from openbsd, pointed out by jdc) 2011-05-24 01:17:36 +00:00