Commit Graph

1437 Commits

Author SHA1 Message Date
pooka
8357a02c05 doesn't need files.rump 2010-08-30 11:51:29 +00:00
pooka
4c62970c70 * record proc's cred in p_cred too
* account procs for uids
2010-08-30 10:49:40 +00:00
pooka
72a4517ea3 regen: rump syscalls for kern_prot interfaces 2010-08-30 10:34:51 +00:00
pooka
9a611a11e0 Empty commit to show makesyscalls.sh rev 1.99 didn't change anything (yet). 2010-08-30 10:24:42 +00:00
pooka
f0fb0d2ca1 do 5.0 compat for fstat 2010-08-30 10:08:39 +00:00
pooka
e731bd97ef Include kern_prot.c for setuid etc. 2010-08-30 09:44:40 +00:00
pooka
64cced98e7 Use one line per sys/kern source module. no functional change. 2010-08-30 09:44:11 +00:00
pooka
33e9636157 Move the manpage from the kernel sources into lib, 'cause that's
where it's used.
2010-08-27 08:21:43 +00:00
pooka
e50b65b297 update a bit 2010-08-26 22:48:36 +00:00
pooka
5cfa84d3e6 print one line of dmesg per cpu present 2010-08-26 19:56:07 +00:00
pooka
cf0a627569 whoopsie, need to commit this as part of scsitest 2010-08-24 13:19:04 +00:00
pooka
64d9536df5 Implement enough of a SCSI target to be able to perform tests on
our SCSIPI driver stack.  Currently we pretend to be a single CD
controller with an optional host file as the image, but I guess
the sky's the limit.

dmesg porn:
NetBSD 5.99.39 (RUMP-ROAST) #0: Mon Aug 23 11:38:16 CEST 2010
        pooka@pain-rustique.localhost:/usr/allsrc/src/sys/rump/librump/rumpkern
total memory = unlimited (host limit)
timecounter: Timecounters tick every 10.000 msec
timecounter: Timecounter "rumpclk" frequency 100 Hz quality 0
root file system type: rumpfs
mainbus0 (root)
scsitest0 at mainbus0
scsibus0 at scsitest0: 2 targets, 1 lun per target
cd0 at scsibus0 target 1 lun 0: <RUMPHOBO, It's a LIE, 0.00> cdrom removable
2010-08-24 11:23:35 +00:00
pooka
4d40787853 Split scsipi out of librumpdev_umass into librumpdev_scsipi. umass
still compile time depends on scsipi in the sense of "ifdef
NATAPIBLUES", but I'm not going to fix that now.
2010-08-23 20:49:53 +00:00
pgoyette
85e292c065 Initialize the new kernconfig_lock for rump kernels before it can be used.
Should fix the rather massive breakage in the automated test runs, too.
Sorry for breaking rump.
2010-08-23 14:00:40 +00:00
pgoyette
0a1d427681 Add the new kern_cfglock.c to rump. 2010-08-21 13:20:43 +00:00
pooka
14ac9d6c4c Use the same base pagerflags for both ubc_uiomove and ubc_zerorange. 2010-08-19 02:07:11 +00:00
pooka
942c727880 Prefault bus pages in driver attachment. This seems to work around
weird corruption I've been seeing (most likely a host kernel bug).

For more details, see thread at:
http://mail-index.netbsd.org/tech-kern/2010/08/17/msg008749.html
2010-08-17 20:42:47 +00:00
pooka
c2fbfedc83 Fix hopefully last off-by-one: if we fill the bus, we must also
advance the "first" pointer.  This problem triggered only if the
bus was filled in the first round, since the first pointer is at
the end-of-bus only for the bootstrap round.
2010-08-17 12:59:53 +00:00
pooka
86ea9bb1a9 * fix off-by-wrap case where current datagram aligns exactly with
the end of the bus
* clarify the "can we still use the device's next pointer" calculation
  and move it to its own routine
* sprinkle dprintf
2010-08-17 11:35:23 +00:00
pooka
1108237392 simplify, improve, etc. 2010-08-16 17:33:52 +00:00
pooka
d2a293bcc2 reset pktsize each loop 2010-08-15 21:57:58 +00:00
pooka
962bc2f851 reset wrap where necessary 2010-08-15 21:41:39 +00:00
pooka
57245467f6 Implement softints properly: they need to have a schedulable entity
per cpu.
2010-08-15 21:28:33 +00:00
pooka
e46b5d009d Increment lwp's context switch counter when it is scheduled onto
a CPU.  This fixes some heavy-load problems with the pool code when
rump kernels essentially lied and caused the pool code not to do
a proper backdown from the fastpath when a context switch happened
when taking a lock.
2010-08-15 20:23:04 +00:00
pooka
50fa67ff5f Move the lockops together with the interface -- they are needed
only at runtime.
2010-08-15 18:55:03 +00:00
pooka
9ae53a340e Take kernel lock before passing data to if_input. This is in line
with IPL_NET interrupts generally not being MPSAFE.
2010-08-15 18:48:38 +00:00
pooka
dc24e61692 introduce a sleep to trying to grab the bus 2010-08-15 18:47:38 +00:00
pooka
b1559dbb99 Don't do timestamping with buslock held. it's the little things ... 2010-08-15 18:40:41 +00:00
pooka
86d75f6695 truncate pcap output file 2010-08-13 11:45:47 +00:00
pooka
b97bdf9424 Include a timestamp in the frame header. When converting to pcap,
it can give some idea of when packets were sent.

nb. it's the sending host's timestamp, not an observer timestamp
like in the typical pcap case.
2010-08-13 10:13:44 +00:00
pooka
ce68b7ae71 Include a pointer to the beginning of the buffer and add support
to the packet dumper.  This helps in situations where the juicy
details are in a bus multiple generations old.
2010-08-12 21:41:47 +00:00
pooka
38800eaa1c further simplify & fix calculations 2010-08-12 18:39:54 +00:00
pooka
6461f6dd05 Recognize ``-'' for stdout. allows piping output to tcpdump -r - 2010-08-12 18:22:40 +00:00
pooka
d5a83df798 * include a magic number in the bus format
* simplify offset calculations by making them start from beginning of data
2010-08-12 18:17:23 +00:00
pooka
36e63e6874 Make shmif memory access slightly more sane. Create a header which
is shared by the interface and the bus analyzer.
2010-08-12 17:33:55 +00:00
pooka
3b2b85fd24 pass Wall 2010-08-12 17:00:41 +00:00
pooka
65028c6bf3 Add a little utility to convert shmif bus traffic to a pcap file
which can be then examined with tcpdump -r, wireshark, etc.
2010-08-11 12:41:09 +00:00
pooka
e2f111efb1 * remove some magic numbers from the code
* include bus version number in header just in case we want to examine
  bus traffic at some point in the future
2010-08-11 12:10:39 +00:00
pgoyette
fa0f1ddde5 Keep condvar wmesg within 8 char limit 2010-08-11 11:51:06 +00:00
pooka
855ec3e9a1 Change bus header a little: reserve only 32bits for the lock and
use 32bit atomic ops to handle it.  Begin data from 0x10 instead
of 0x14.
2010-08-11 10:30:30 +00:00
pooka
6fe4bb4ba8 Support carp. It would be nice to support this as its own component,
but there's about 1000 lines of #ifdef which disagree with my wish.
2010-08-10 21:50:10 +00:00
pooka
10881f3354 Attach 1 loop instead of 0.
not tested on animals
2010-08-10 21:48:23 +00:00
pooka
0c2778236c Don't create the percpu clock interrupt threads as softint threads
because they aren't softint threads.  This fixes callouts in
situations where there is nothing else happening in the rump kernel
(i.e. no threads executed which would trigger the softints when
they unschedule).
2010-08-10 21:32:38 +00:00
pooka
f762b5222f Use correct indices for clock threads and more descriptive ones
for the softint threads.
2010-08-10 19:16:04 +00:00
pooka
066824f414 * use atomic ops instead of __cpu_simple_luck
* this interface is un-IFF_SIMPLEX
2010-08-10 18:17:12 +00:00
pooka
8a20e6b473 * improve diagnostic print
* deal with a tap quirk when it returns 0 bytes
2010-08-10 18:06:10 +00:00
pooka
fffcd29dff Attach component to make it work after defpseudodev conversion
(yea, i need to fix the infrastructure for this).
2010-08-03 19:55:17 +00:00
pooka
316bb4eafe * print interface number, backend path and ethernet address for dmesg
* make kassert more demanding
2010-07-29 22:48:11 +00:00
pooka
334470517a * increase bus size so that we don't wrap so quickly when NFS
flushes writes
* verbosize debug print a bit
2010-07-29 18:30:39 +00:00
hannken
ecb633e650 Correct previous. Skip marker pages in uvm_pagelookup().
Already awake :-)
2010-07-29 15:13:00 +00:00