Commit Graph

113454 Commits

Author SHA1 Message Date
phx 7f7d4934d7 Configure pcf8563rtc for nhnas models. 2012-01-07 21:03:05 +00:00
phx 3828823874 Add direct config support. 2012-01-07 21:02:15 +00:00
phx 57fa1ff5e0 Disable flash device unless nor(4) is not finished.
Add pcf8563rtc(4) for NH230/231.
2012-01-07 20:51:23 +00:00
reinoud 92531faa53 Move target/${USERMODE_CPU} to target/${MACHINE_CPU} to more clearly
distinguish between CPU specific ones and machine specific ones.
2012-01-07 20:44:41 +00:00
christos 7c206e7387 make standalone 2012-01-07 20:20:22 +00:00
christos ba21b5b920 u_intN -> uintN
make standalone
2012-01-07 20:20:12 +00:00
reinoud ec74fc0746 Remove unused thunk_sdl.c file 2012-01-07 20:12:07 +00:00
reinoud a1d9faf5ca Add AMD64 target for NetBSD/usermode next to i386 and reorganize source tree
to have port specific stuff in arch/usermode/target/<port>/
2012-01-07 20:07:00 +00:00
phx 8e46b16673 NH230 PPCBoot configures the memory boundary registers for 128MB, although
the board has only 64MB. Fix that.
2012-01-07 19:57:49 +00:00
christos fbaf57ceb3 According to TOG, <aio.h> is a standalone header. 2012-01-07 19:48:19 +00:00
reinoud 71752b9071 Cleanup trap debug messages 2012-01-07 19:45:14 +00:00
reinoud ad1edb6e92 Change prototype of logical page number in pv_lookop and pv_enter and add
diagnostic checks to check for out-of-bounds.
2012-01-07 19:44:13 +00:00
reinoud abf38a5fd4 Boost symtab space for amd64 2012-01-07 19:43:06 +00:00
jmcneill 01a67a2dc9 support multiple disk images (pass multiple disk=<path> parameters on the
command-line). while changing command-line params, rename tap= option to
net=
2012-01-07 18:10:18 +00:00
jmcneill 7c0f99cad9 increase the max # of sigio handlers 2012-01-07 18:07:57 +00:00
chs d331b836f8 define _UC_TLSBASE and use it to pass the TLS pointer to setcontext().
since there is no available space in ucontext_t on vax, pass the
TLS pointer on the stack referenced by the ucontext_t instead.
suggested by joerg.
2012-01-07 16:47:42 +00:00
skrll 222e907fa3 Allocate a major number for wd and sysmon_power
Part of PR/45783
2012-01-07 16:11:19 +00:00
pgoyette 7eb354b883 Modify the attach message for consistency with most other pci devices. 2012-01-07 15:59:46 +00:00
phx 422b962b84 Fixed 12/24h mode. Bit 6 from the hours register indicates 12h mode.
Do not overwrite the control register (0x07) with random contents.
2012-01-07 15:03:11 +00:00
jmcneill b2424d9a22 add support for elantech (v2) touchpads that report input pressure 2012-01-07 10:27:58 +00:00
skrll 10e01fe7ca s/aprint_verbose/aprint_debug/ 2012-01-06 22:14:04 +00:00
skrll 0b60181db2 Track if a page has an executable mapping and flush the icache (and
dcache) appropriately.

Fixes the lang/python26 build on my C3700 (PA8700) and chuq's J6700 with
PA8500.

Thanks to chuq for ideas and help with this.
2012-01-06 20:55:28 +00:00
reinoud 5c84446921 Split machdep.c into a MI part and a MD part. 2012-01-06 20:44:57 +00:00
reinoud f4334c5283 Enhance debugging printfs to also report the functionname 2012-01-06 20:40:51 +00:00
reinoud a16d774cf6 printf()->thunk_printf() since its for debugging and should be printed outside
the kernel's printing system.
2012-01-06 20:39:42 +00:00
cherry 44fb314fb7 Address those pesky DIAGNOSTIC messages. \n
Take a performance hit at fork() for not DTRT. \n
Note: Only applicable for kernels built with "options DIAGNOSTIC" \n
2012-01-06 15:15:27 +00:00
drochner 47a381e15e more IPSEC header cleanup: don't install unneeded headers to userland,
and remove some differences berween KAME and FAST_IPSEC
2012-01-06 14:17:10 +00:00
jmcneill bd08415c40 support disk images >= 2GB 2012-01-06 14:11:55 +00:00
macallan 85f54afb13 Forgot to commit this along with r128fb.c. Again. 2012-01-06 13:59:50 +00:00
jmcneill a6b5cee522 i386 and x86_64 versions of this code are the same, rename to syscallemu_x86.c 2012-01-06 13:16:20 +00:00
reinoud ee9d19b7a5 Cleanup stack allocation and freeing. This means the memory leak on lwp
destruction ought to be solved.
2012-01-06 12:54:59 +00:00
reinoud 5f34326ed3 Bump pager map default size since KVM is not that tight anymore 2012-01-06 12:53:07 +00:00
skrll 7da1bc7d44 Log the icache sync only if it's done. 2012-01-06 09:41:17 +00:00
skrll 36da247fe2 Comment fix. 2012-01-06 09:12:25 +00:00
skrll a308a2c3d2 No need to flush the icache/itlb for pool pages as they're never marked
executable.
2012-01-06 09:11:45 +00:00
skrll 5f229dee2b Flush the d-cache and i-cache to make sure the text area of the module
is dealt with properly.
2012-01-06 09:09:25 +00:00
skrll f29475a086 Wrap a long line. 2012-01-06 08:54:05 +00:00
skrll 619a565a82 Add a KASSERT. 2012-01-06 08:48:43 +00:00
skrll c00b3a100e More whitespace. 2012-01-06 08:38:11 +00:00
skrll 1fc41dd0ac Whitespace. hi perry. 2012-01-06 08:36:10 +00:00
skrll d5c28a2a4b Group the prototypes. 2012-01-06 08:33:26 +00:00
skrll e6cde8ed1f Simplify code a little. 2012-01-06 08:32:08 +00:00
skrll 853b477cb1 Style. 2012-01-06 08:03:16 +00:00
skrll 0ed9b731f5 Make pmap_check_alias static 2012-01-06 07:59:07 +00:00
macallan e7e44ea620 turns out we can feed some radeons faster than they can process image uploads,
so make periodic stops to let the fifo drain a bit
now this works on my Blade 2500 with a 32MB XVR-100
2012-01-05 21:40:03 +00:00
jym 9fc3eceb8b Comment fix. 2012-01-05 18:11:50 +00:00
reinoud cceff1dc43 Remove unused variable i accidently left standing 2012-01-05 17:26:57 +00:00
reinoud f3a83bd0cb Oops, forgot to revert this patch too... thanks Greg for finding it :-/ 2012-01-05 17:18:02 +00:00
reinoud 5bd510aeaa Revert MAP_NOSYSCALLS patch. 2012-01-05 15:19:52 +00:00
jmcneill d7f6b3d11f Add 'syscallemu' module, required by usermode kernel.
This module registers a syscall that takes a user_start and user_end address.
When a process calls SYS_syscallemu, the start and end address are recorded
and the syscall installs a filter on p->p_md.md_syscall. The filter then
uses the specified start and end addresses to determine where the syscall
should be routed (either host by calling the original md_syscall function,
or process by posting SIGILL).
2012-01-05 13:26:51 +00:00
jmcneill 0cfa3a8fb1 Get rid of MAP_NOSYSCALLS usage; now this relies on a separate kmod that
you can get here: http://www.netbsd.org/~jmcneill/syscallemu.tar
2012-01-05 12:12:58 +00:00
macallan 5eec1b0f55 support anti-aliased fonts in 8 bit, generate an appropriate colour map 2012-01-04 20:18:28 +00:00
macallan d0517cd235 rasops8 expects the colour value replicated in every byte in devcmap[], so
fix that for r3g3b2
2012-01-04 20:17:05 +00:00
macallan f692d005a8 add support for anti-aliased fonts in r3g3b2 2012-01-04 20:16:20 +00:00
macallan 1e50f31f65 use CHAR_IN_FONT() and WSFONT_GLYPH() macros 2012-01-04 17:01:52 +00:00
reinoud 582879d39a Enhance the page_deactivate() to have less side effects. While here also make
a variable local to the debug routine that uses it.
2012-01-04 16:20:41 +00:00
drochner 8fd6dadaf8 include <netipsec/ipsec.h> rather than <netinet6/ipsec.h> from userland
where possible, for consistency and compatibility to FreeBSD
(exception: KAME specific statistics gathering in netstat(1) and systat(1))
2012-01-04 16:09:40 +00:00
haad 62688f9115 Fix wrong KASSERT, reported by mhitch@. 2012-01-04 16:05:53 +00:00
macallan 2d0a8b25c8 use WSFONT_GLYPH() 2012-01-04 15:56:18 +00:00
drochner 3712f81ced -consistently use "char *" for the compiled policy buffer in the
ipsec_*_policy() functions, as it was documented and used by clients
-remove "ipsec_policy_t" which was undocumented and only present
 in the KAME version of the ipsec.h header
-misc cleanup of historical artefacts, and to remove unnecessary
 differences between KAME ans FAST_IPSEC
2012-01-04 15:55:35 +00:00
macallan dd77d71244 add WSFONT_GLYPH() to get a pointer to a given glyph in a given font 2012-01-04 15:53:49 +00:00
reinoud f7656de71f No reason why to have a larger pagefault stackframe for lwp0 2012-01-04 15:18:57 +00:00
reinoud 3a3d6c42df Zero the memory we claim for the stacks 2012-01-04 15:14:57 +00:00
reinoud cbdd12d472 don't try to unmap pv entries with munmap() that are / were already unmapped 2012-01-04 15:10:45 +00:00
jmcneill e51725528c implement cngetc and cnpollc 2012-01-04 14:53:57 +00:00
apb 0f20d9487a Instead of calling clockctl_ioctl directly, lookup the cdevsw and
call its d_ioctl function.  This should fix an undefined reference to
`clockctlioctl' when you build a kernel that has COMPAT_50 but does not
have pseudo-device clockctl.
2012-01-04 14:31:17 +00:00
reinoud 6192921cd1 Revert HZ to 100 what it was 2012-01-04 14:09:48 +00:00
jmcneill 411b87b501 add options NTP & pseudo-device clockctl 2012-01-04 14:04:12 +00:00
apb 989df4c71f Provide a COMPAT_50 version of the CLOCKCTL_NTP_ADJTIME ioctl.
When time_t was changed from 32 to 64 bits, this ioctl's number
was changed from _IOWR('C', 0x4, struct clockctl_ntp_adjtime)
to _IOWR('C', 0x8, struct clockctl_ntp_adjtime), but the data
structure did not change, so all the compat code has to do is
change the number and try again.
2012-01-04 13:45:55 +00:00
apb 7904ca964d When processing ioctl CLOCKCTL_NTP_ADJTIME, set the return value from
ntp_timestatus instead of leaving it uninitialised, and don't use
copyout(9) because args->retval is in kernel space, not user space.

Previously, running ntpd(8) in unprivileged mode would call
libc ntp_adjtime(), which would open /dev/clockctl and call
ioctl(CLOCKCTL_NTP_ADJTIME), which would fail with EFAULT.
2012-01-04 13:40:53 +00:00
reinoud 544f0c24da Add extra debugging info for the vncfb code 2012-01-04 13:31:30 +00:00
reinoud 4399b509b3 This uint shouldn't be there 2012-01-04 11:56:58 +00:00
reinoud aabdcdb8e4 mmap ppl is always < 16 so make it an uint8_t 2012-01-04 11:53:09 +00:00
cherry a4131cfa05 Tighten up locking in the network driver.
This probably needs more attention since xennet_rx_mbuf_free() hooks
into the network layer.
The locking can also be made finer grained. Performance testing could
add some insights.
2012-01-04 10:48:24 +00:00
cherry 84d4985e86 Use macro PDP_SIZE instead of numeric constant, for unshared PAE L3 entries.
Thanks jym@
2012-01-04 10:30:23 +00:00
macallan 86ab503f6f generate a better r3g3b2 colour map which actually produces white for 0xff 2012-01-04 08:38:20 +00:00
macallan 452ccd358c bump character buffers and cache to 32bit per character so flags we store
in the upper bits don't get lost
now autogenerated line drawing characters work with VCONS_DRAW_INTR and don't
get lost when switching screens
2012-01-04 08:25:03 +00:00
macallan a06da19618 split putchar into separate methods for bitmap and alpha fonts, use
FONT_IS_ALPHA()
2012-01-04 07:56:35 +00:00
perseant 232630fdd2 lfs_writerd thread exits when no more LFSs are mounted. 2012-01-04 02:48:58 +00:00
kiyohara 133bfd2508 Use device_t instead of 'struct device *'.
Remove unnecessary \n.
2012-01-04 02:36:26 +00:00
macallan d5062c9e69 split putchar method into one for alpha fonts and one for bitmap fonts 2012-01-03 23:15:11 +00:00
macallan 0012d4bd2f add a macro to identify alpha fonts 2012-01-03 23:13:59 +00:00
reinoud 35600b8c2c Rework NetBSD/usermode pmap fixing some oddities that were left over from
earlier times when we were forced to run PIE executables and were forced to
use a KVM above the kernel.
2012-01-03 21:28:50 +00:00
pgoyette d5ff17bf98 Display current mount point, rather than previous one, when printing
the "replaying log to disk" message.

OK dholland@

Fixes PR kern/39609
2012-01-03 15:44:00 +00:00
reinoud 0e68596237 Set the total memory length to be ALL the space *before* the kernel. 2012-01-03 12:16:16 +00:00
reinoud afa1fedea0 Use M_WAITOK instead of M_NOWAIT for the stack allocations 2012-01-03 12:10:04 +00:00
reinoud cc21223919 Rename the debug printf's to use a thunk_ prefix to avoid confusion. 2012-01-03 12:05:00 +00:00
reinoud 8873d4afdb Fix logic that checks if its the kernel or a userland process that causes the
trap. Signal sending still needs to be addressed.
2012-01-03 10:53:46 +00:00
kiyohara f58fcf6acf Use device_t instead of 'struct device *'.
Call aprint_* in auto-config time.
2012-01-03 07:36:02 +00:00
skrll 28d6e7ce06 Fix the CPU #ifdefs 2012-01-03 06:18:24 +00:00
skrll 7bf579b1ee Tidy up the M[FT]CPU_* hv-specific instructions some more.
Same code before and after change.
2012-01-03 06:11:21 +00:00
macallan 7a8eb8051b support anti-aliased fonts in 32bit colour
enable with options RADEONFB_DEPTH_32
2012-01-03 00:25:49 +00:00
liamjfoy e3d3462211 Remove dead variable 2012-01-02 22:17:11 +00:00
perseant f9b3466d45 * Remove PGO_RECLAIM during lfs_putpages()' call to genfs_putpages(),
to avoid a live lock in the latter when reclaiming a vnode with
  dirty pages.

* Add a new segment flag, SEGM_RECLAIM, to note when a segment is
  being written for vnode reclamation, and record which inode is being
  reclaimed, to aid in forensic debugging.

* Add a new segment flag, SEGM_SINGLE, so that opportunistic writes
  can write a single segment's worth of blocks and then stop, rather
  than writing all the way up to the cleaner's reserved number of
  segments.

* Add assert statements to check mutex ownership is the way it ought
  to be, mostly in lfs_putpages; fix problems uncovered by this.

* Don't clear VU_DIROP until the inode actually makes its way to disk,
  avoiding a problem where dirop inodes could become separated
  (uncovered by a modified version of the "ckckp" forensic regression
  test).

* Move the vfs_getopsbyname() call into lfs_writerd.  Prepare code to
  make lfs_writerd notice when there are no more LFSs, and exit losing
  the reference, so that, in theory, the module can be unloaded.  This
  code is not enabled, since it causes a crash on exit.

* Set IN_MODIFIED on inodes flushed by lfs_flush_dirops.  Really we
  only need to set IN_MODIFIED if we are going to write them again
  (e.g., to write pages); need to think about this more.

Finally, several changes to help avoid "no clean segments" panics:

* In lfs_bmapv, note when a vnode is loaded only to discover whether
  its blocks are live, so it can immediately be recycled.  Since the
  cleaner will try to choose ~empty segments over full ones, this
  prevents the cleaner from (1) filling the vnode cache with junk, and
  (2) squeezing any unwritten writes to disk and running the fs out of
  segments.

* Overestimate by half the amount of metadata that will be required
  to fill the clean segments.  This will make the disk appear smaller,
  but should help avoid a "no clean segments" panic.

* Rearrange lfs_writerd.  In particular, lfs_writerd now pays
  attention to the number of clean segments available, and holds off
  writing until there is room.
2012-01-02 22:10:44 +00:00
reinoud b9d601ff9f Remove tests that are dubious and should be (re)moved anyway. 2012-01-02 22:02:51 +00:00
reinoud 6e429eb748 Add UDF, NILFS and NFS to the standard file systems and boost the symbol table
size to accomodate for this.
2012-01-02 21:48:14 +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
reinoud 7142b8ed9f Do release all l2 pages on destroy 2012-01-02 09:49:12 +00:00
jmcneill 31469ba145 fix range check for mmap 2012-01-02 00:20:30 +00:00
reinoud d8d4ad078a Rewrite usermodes pmap to use indirect adressing significantly reducing pmap
memory usage. Typically a decimation. This is done using L1 and L2 mappings.
2012-01-01 21:40:22 +00:00