1
0
mirror of https://github.com/prirun/p50em.git synced 2026-01-22 10:11:31 +00:00

193 Commits

Author SHA1 Message Date
Jim
f77c58a69b bs: remove remaining crs[] references: BI/DX/Y, I/DRX, ... 2011-10-17 22:39:30 -04:00
Jim
8b5d47c733 bs: change add16 to a function, change all callers to use get/put 2011-10-17 22:30:28 -04:00
Jim
fa097d21fc BS rvec, memory accesses; order of RPH/RPL is byte-order dependent,
fix bug in get32 when -DFAST isn't used
2011-10-17 22:14:55 -04:00
Jim
7b150eed02 bs: replace pmep C pointer with Prime physical address 2011-10-17 15:15:35 -04:00
Jim
5790718ed7 Add swap calls to get/put functions & macros, add tracei target for Intel 2011-10-17 15:06:55 -04:00
Jim
2a89fb6ab8 First set of byte-swap changes; should compile equal to version 194 2011-10-17 10:53:58 -04:00
Jim
69a37aef55 Remove crs[] and crsl[] references in trace output, add vfy target to
makefile to allow comparing emulator binaries
2011-10-17 10:53:12 -04:00
Jim
aad6c9f94c Don't delay on first BDX * to avoid Prime bug in SCHED.PMA causing
backstop process to delay on the first cycle
2011-10-11 17:39:32 -04:00
Jim
b9980bfe30 devamlc: add outbound dedicated lines, programmable clock line,
move local vars to the block that uses them
2011-10-10 00:07:51 -04:00
Jim
77ee732144 Changes to get rev 18 to boot 2011-10-01 22:42:59 -04:00
Jim
d1596b5e82 devamlc: fix ttymsg bug 2011-09-17 15:21:13 -04:00
Jim
ff48e0c07a fatal: display message on nested call 2011-09-17 12:00:56 -04:00
Jim
3a64f463f0 devamlc: minor edits 2011-09-16 09:46:51 -04:00
Jim
f912f5dcc5 devamlc: major revision to interrupt only on the clock line board,
and in general, optimize operation of the AMLC subsystem.
2011-09-15 18:27:33 -04:00
Jim
efada91773 Fixed several AMLC issues:
- Kermit/telnet negotiations work now: fd var was not being set, so
write() was not actually working

- with many controllers, Primos would halt with tumble table overflow:
you can't do read processing until lines are enabled

- only look for new connections when handling the clock line
controller; there is no sense doing this more than 10x per second, and
it probably should still have a timer in case polls are being sped up

- use buf[] for tty message, not another static buf

- when a new connection occurs, set devpoll for the controller.  The
first connection to a controller was taking 5 seconds when more than 1
controller was present

- when status is read and an eor occurred, do read processing again
rather than waiting for the next poll

- divide tumble table space up by # of connected lines.  The old way
read MAXREAD (64) chars from each line until the tumble table was
full.  But with 8 AMLC boards configured, there is only 53 words of TT
space in each double buffer.  A select() on connected fd's would be
better.

- allow # as first character of amlc.cfg for comment lines

- turn on TCP/IP NODELAY (disable Nagle) to improve character echo
2011-09-13 14:02:28 -04:00
Jim
88d7a3fba6 Add a way for device to be polled when CPU is idle. Maybe this can be used
to interleave user processes with device & DIM processes, for example, during
a file upload.
2011-09-05 16:20:26 -04:00
Jim
023edffb04 Remove "room left in input buffer" concept, remove DMT support 2011-09-05 16:17:48 -04:00
Jim
20e43665bd Add mtread/mtwrite: read/write .tap files from/to physical tape 2011-08-31 13:40:22 -04:00
Jim
5d43e41c12 Revert #139 (eafa); emacs, esc75* inserted garbage, not 75 *'s 2011-08-31 12:46:53 -04:00
Jim
871568778f Re-add broken Kermit negotiation, but now telnet works again! 2011-08-27 20:51:19 -04:00
Jim
4e59c7728b Re-add Kermit telnet negotiation, but leave it disabled 2011-08-27 20:35:12 -04:00
Jim
cc4d7561ed devamlc comments and cleanups 2011-08-27 20:23:32 -04:00
Jim
7230a331f3 Back out telnet changes for Kermit; they screwed up regular telnet 2011-08-27 20:11:37 -04:00
Jim
927d8c9c13 Tried to fix Kermit telnet negotiation so /nowait isn't required; worked
for most things, but not for DO KERMIT / WILL KERMIT - still hangs. :(
2011-08-27 17:04:59 -04:00
Jim
d7dc1847a8 amlc.cfg: can dedicate AMLC lines to an IP address. This is useful
for serial device servers connected to a serial printer for example,
where the SDS initiates the telnet connect to the Prime when the
printer is turned on.
2011-08-27 08:29:44 -04:00
Jim
51aaaeb341 Reverse order of devpnc.h and devamlc.h: both use MAXHOSTLEN 2011-08-27 07:34:52 -04:00
Jim
5a5be64d17 Split devamlc into .h file, correct devpnc.h brace bug (hobby) 2011-08-24 17:42:35 -04:00
Jim
b643ed80ed Add Unix versions of smad, smag for Prime pdevs 2011-08-24 17:15:16 -04:00
Jim
d398a93143 Removed PNCXSNAK - don't need it 2011-08-24 17:12:36 -04:00
Jim
50a95cc1ba Use close(): shutdown() causes a descriptor leak. Add a trace when a
connection is accepted.
2011-08-19 17:04:31 -04:00
Jim
49eaf4b21b Don't zero uid of disabled node, to avoid "can't find uid" error. 2011-08-19 16:15:16 -04:00
Jim
a3a1f06d6f When a packet is too big to receive, disable the node it came from.
This happens for example if a node is configured with a 1024-word
packet size and sends to a node with a 256-word packet size.  In the
emulator PNC design, the packet has already been ACK'd at the sending
side, so there is no way to indicate a transmission error other than
taking down the connection.  Since the error will just occur again,
the best course is to disable the node until the next reboot.
Primenet will disconnect the sending and receive nodes from each other
in about 30 seconds.

Also removed pnchexuid: useful in the beginning, not so much now.
2011-08-19 16:04:39 -04:00
Jim
2a698b038d Don't NAK xmit packets. prmnt1 seems to indicate that a packet no one
accepts is NAK'd, but if we do that, it keeps getting sent over and
over.  If we're not connected, retries don't make sense.
2011-08-19 13:37:02 -04:00
Jim
6b8abd3a8b Use current hg rev when building 2011-08-18 20:58:18 -04:00
Jim
aba2688490 Don't enable tsrc$$ trace hack whenever tracing is enabled. 2011-08-18 14:07:23 -04:00
Jim
063a23144a Fix several devpnc bugs:
1. Need 32-bit integer for dma address so newer Primos can use I/O
segments other than 0.
2. Ignore interrupted select()
3. Set fd to -1 after closing when not connected, to avoid bad
file descriptor error
2011-08-18 14:04:55 -04:00
Jim
05251fbcce Allow tracing 3-digit user numbers vs 2. System processes sometimes
have high user numbers.
2011-08-18 13:35:33 -04:00
Jim
459873ff90 Add stlb/iotlb trace option "tlb", set T_EAS when requested 2011-08-18 13:17:54 -04:00
Jim
2ef1438900 Updated some comments. Still some confusion about PTLB re: IOTLB. 2011-08-18 10:10:28 -04:00
Jim
8200cff70d devpnc: don't print disconnected message in error.log when we were
trying to connect but failed.  Only print them when we actually were
connected.
2011-08-17 16:28:58 -04:00
Jim
1bc93f304a devpnc: ensure ring.cfg unique id is really unique: it determines the
node-id for incoming connections.
2011-08-17 15:48:01 -04:00
Jim
834cb1977f Add simulate token OCP, just for documentation purposes. This is only
used by T&M's.
2011-08-17 12:05:21 -04:00
Jim
a68971cc1c Flush tracefile every line only when "flush" arg is used. This is
useful for situations where the emulator bombs, eg, with a Unix seg
fault.  But it's slower too, so make it optional.
2011-08-17 09:35:01 -04:00
Jim
8c635c19c8 Minor devpnc edits, change MAXACCEPTTIME from 5 to 15 seconds 2011-08-16 18:34:16 -04:00
Jim
1b943bce0a Enabled PNC async I/O, changed poll from 100ms to 1 sec, performance
seems to be fine.  Remote ld -size no longer takes 1 second per entry,
but that is probably because of earlier PNC changes.
2011-08-16 18:04:13 -04:00
Jim
8aac162418 Use select() to find out if any node has sent us data; more efficient
than doing a read on each socket.
2011-08-16 17:55:55 -04:00
Jim
51dfd5101b Only dump packets when tracing w/RIO 2011-08-16 15:31:07 -04:00
Jim
f742bc46a9 Add code to devpnc to remember when it triggers interrupts, seems to
work okay and not have the 30-second delay problem.

Over netlink, a prirun, l, displays a couple of medium-sized packets,
then '55' from PR0055 in a tiny packet, then one more reasonable-size
packet.  The tiny packet seems odd, but I'm guessing it's a window
size or buffer size thing inside Primos / Primenet.
2011-08-16 15:28:14 -04:00
Jim
6a668b877d Timestamp packet dumps and polls, check for interrupt needed when
interrupts are enabled.  This fixes the 30-second lag problem, but
also causes PNCDIM to get notified too many times.  After an xmit,
devpnc causes an immediate interrupt.  This is handled by the SEG4
phantom interrupt code by disabling PNC interrupts, then notifying
PNCDIM.  (Remember, PNCDIM is still in the xmit OTA, or shortly
following).  PNCDIM finishes its loop, enables interrupts, and does a
WAIT.  When it enables interrupts before the WAIT, devpnc doesn't
remember that it has already interrupted, and interrupts again.  I
think this is a bug - the other emulator controllers have a state
variable to remember whether they have already interrupted.  But,
if I fix this "bug", we'll probably have 30-second delays again.
Hmmm...
2011-08-16 14:46:36 -04:00
Jim
4ddd43debf Add async I/O code to devpnc, but disabled for now: there is a delay
problem with remote terminal sessions:

1. netlink to remote Prime
2. a prirun
3. l (list directory)
4. displays a little, then a longish pause up to 30 seconds, then the rest

Does a similar thing with stat us.  Hitting Enter will cause it to
finish, while typing characters does not.  I suspect this is a problem
with Prime's networking code, but not sure.

Also, if async I/O is used, the QUIT. OK, message doesn't appear after
ctrl-p.  I think they are getting wiped out by Primenet's buffer
flushes.

All of this might be subtle timing problems because I changed the
default clock rate from 250/330/500/whatever times per sec to 20 times
per second in this rev 19 version of Primos.
2011-08-15 17:11:28 -04:00