Commit Graph

471 Commits

Author SHA1 Message Date
scottr 9dfb9a7f87 Add support for Mouse Systems A3 mouse. From Colin Wood. 1997-06-16 06:35:26 +00:00
scottr db9068c773 Don't call Debugger() if we don't have ddb. Fixes PR 3744. 1997-06-15 20:34:15 +00:00
scottr 36b75f2735 Update from Denny Gentry <denny1@home.com>, PR 3685:
Simplify the way transmit buffers are managed, remove assumptions about
NBPG, simplify sonic_get handling, update snioctl to be more like other
current drivers, and probably a few other changes I've now forgotten about.
1997-06-15 20:20:07 +00:00
veego 61e0a78f37 s/mac68k_btop/m68k_btop/ 1997-06-10 20:29:10 +00:00
veego dd62be796a s/mac68k_trunc_page/m68k_trunc_page/ 1997-06-10 19:01:35 +00:00
veego 0cd13fe0b5 s/mac68k_round_page/m68k_round_page/ s/mac68k_trunc_page/m68k_trunc_page/
s/mac68k_btop/m68k_btop/
1997-06-10 19:01:00 +00:00
scottr a0d035c410 Fix some printf format inconsistencies; from SUNAGAWA Keiki
<kei_sun@ba2.so-net.or.jp>, fixes PR 3619.
1997-05-19 17:23:09 +00:00
scottr fac0bcfedb Update a recently-added comment re: bytelanes values. 1997-05-13 13:22:56 +00:00
scottr 5b80f9077f Tweak sbc_drq_intr() (interrupt-driven PDMA interrupt handler); it
now works properly on at least some disks.  Further testing is
necessary.
1997-05-13 06:34:00 +00:00
scottr 3b7a1d3ab0 Convert several interrupt handlers to bus space model, removing some
XXX's.  Also, fix a bug in grfmv_intr_generic() that I found and
confirmed with Allen.
1997-05-12 20:35:50 +00:00
scottr 61322b7b85 KNF and other cosmetics. 1997-05-12 07:53:58 +00:00
scottr ee80f1200e Implement new NuBus slot space mapping/probing code, utilizing bus.h (and
our MD bus_space_probe() extension).  This has several side effects:

 - NuBus drivers must map and unmap slot space, rather than relying
   on this happening before they are attached.
 - Functions exported to NuBus drivers from nubus.c now need to be
   supplied with a bus space tag/handle pair.
 - Old bus map/peek functions can be garbage collected, as can pmap
   support for the same.

Because of some current limitations of the bus space specification, we
are violating the abstraction in grf_mv (NuBus grf driver).  All such
violations are clearly marked /* XXX */, and must be addressed when
the specification is updated.
1997-05-11 19:11:27 +00:00
briggs 5230506ca5 Support for clearing interrupts on a Rasterops Colorboard 364.
Thanks go to Michel Chalufour <michelc@tiac.net> for grovelling around for
me.
1997-05-03 02:29:54 +00:00
briggs 1b2e317732 Thanks to Tobias Beal <tbeal41@maine.maine.edu>, we can clear interrupts
on at least one Radius Precisioncolor 8 board.
1997-05-02 00:54:28 +00:00
briggs aba671db48 Treat drhw 118 and 119 the same for Apple ethernet cards. 1997-05-01 18:17:13 +00:00
briggs a64bc3c19c Clear the interrupts properly on an E-Machines Futura II LX and make a wild
guess at clearing them on a Futura II SX/DSP and RasterOps ColorBoard 364.
Thanks to Michel Chalufour <michelc@tiac.net> for loaning me the II LX.
1997-05-01 03:34:07 +00:00
briggs ef185efb22 Add in a couple more board types. 1997-05-01 03:31:07 +00:00
scottr 19f1b8dd3f Remove dependency on if_aereg.h for vendor constants; these are really
driver-, not architecture-specific.
1997-04-30 19:47:11 +00:00
scottr b28e1b9459 Fix typo in last change. 1997-04-30 19:32:32 +00:00
scottr 4a36cdfd19 Adjust to use16bit -> dcr_reg change in MI driver. 1997-04-30 18:10:37 +00:00
scottr 63ac9ee6e0 Use the new MI 8390 driver, and garbage collect. 1997-04-29 04:40:22 +00:00
scottr c69d32662f From Mycroft: Oops; forgot to GC the last mbuf allocated when
out of clusters.
1997-04-28 20:31:16 +00:00
scottr 70dcf0b5f6 Undo a hack added in the last overhaul (which caused an extraneous byte
to be written to the target).  Also, use the sc_min_dma_len field
to determine whether to use PDMA or PIO.
1997-04-28 15:59:20 +00:00
briggs d25f63a7bf What was I thinking? 1997-04-27 19:26:48 +00:00
briggs e861dbf8c7 A couple of performance improvements from Denny Gentry <denny1@home.com> 1997-04-25 03:40:09 +00:00
scottr 72111ae284 From Mycroft: If we fail to allocate a cluster to hold a large packet,
simply drop it rather than using a chain of tiny mbufs.
1997-04-24 16:52:05 +00:00
briggs ed74d8f653 On video devices, if we're loading non-default resource values, save the
resource ID.  Thanks to Paul Goyette <paul@pgoyette.bdt.com> for spotting
this one.
1997-04-23 13:37:43 +00:00
scottr 9784a8d3cf space vs. tab formatting, KNF 1997-04-22 21:00:04 +00:00
scottr b09a74e8b9 If we can't map SONIC register space, just print a diagnostic message and
continue.  Make formatting consistent and KNF while here.
1997-04-22 20:56:15 +00:00
scottr a653364eb1 Remove obsolete drsw diagnostic; make formatting consistent; KNF. 1997-04-22 20:32:08 +00:00
scottr 65673e5ec2 Make formatting consistent; inline -> __inline__; KNF. 1997-04-22 20:26:24 +00:00
scottr 2111f73a90 Remove obsolete drsw diagnostic 1997-04-22 20:21:59 +00:00
scottr e733e600d3 #ifdef DIAGNOSTIC, print the NuBus type fields for unrecognized boards. 1997-04-22 20:20:32 +00:00
briggs d13ebf0e72 Make sure that we unmap the space that we mapped if we can't identify the card. 1997-04-22 13:45:38 +00:00
briggs d2a4acec48 Initialize 'offset' to make gcc happy. 1997-04-22 03:04:33 +00:00
scottr 43f35682d8 April 18 update from John Wittkoski, w/space vs. tab KNFing by me. 1997-04-21 18:04:28 +00:00
briggs fc43576e8d Take care when accessing DAFB--some quadra-class machines use other video
controllers.
1997-04-21 00:57:59 +00:00
scottr 7e00ee54d8 Fix itematch() for case where fboff is not zero. From Dave Huang,
closes PR #3501.
1997-04-20 20:31:18 +00:00
scottr 19c5134870 For small writes, use PIO rather than PDMA; this increases the reliability
of the driver (considerably, on some systems/targets).
1997-04-18 17:38:08 +00:00
briggs bbc4732fd1 Fix from Denny Gentry--initialize receive seq. counter. 1997-04-18 12:04:37 +00:00
scottr 11b0f01c17 Make sure to call adbop() on Power Manager-based machines. Noted by
Takashi Hamada, who also provided the code I based this modifcation
on.
1997-04-18 05:53:41 +00:00
briggs 16865d719a Take a stab at making this more reliable. 1997-04-15 03:22:50 +00:00
scottr aae8cccb0f Use the new opt_mrg_adb.h header. 1997-04-14 16:56:26 +00:00
scottr 7793be9949 Purely cosmetic cleanup:
- Remove unused `register' modifier on declarations
  - Reverse the sense of some tests to make the code more clear
  - Type casts per KNF
  - Move a static variable into the only function that uses it (perhaps
    we can eliminate it entirely, someday?)
1997-04-14 16:28:34 +00:00
briggs 90754f0770 Capslock support from Steve Brown <sbrown@best.com> 1997-04-14 01:02:47 +00:00
briggs 13175a1a16 Use an offset parameter when loading the reg_map--some cards use the "other"
16 bits of the words.
1997-04-14 00:44:01 +00:00
briggs 6d338ace93 Oops. We do not want to unmap something that we've used bus_space_subregion
to get.
1997-04-13 16:42:34 +00:00
briggs 4a3016b6b6 Some updates based on information from Bob Nestor <rnestor@metronet.com>
about his SONIC-T LC/PDS card.
1997-04-13 14:21:09 +00:00
briggs 306e81deb2 Ignore SE/30 faux-video card. 1997-04-10 20:34:23 +00:00
briggs 0350ba7412 Some patches from Bob Nestor <rnestor@metronet.com> and myself to edge
toward support for an Apple SONIC-based ethernet card.  Some cards, like
his, were being missed and/or probed like video cards!
1997-04-10 03:28:54 +00:00
briggs b38a17b793 Comment video cards and add define for SuperMac Thunder/24. 1997-04-10 03:25:02 +00:00
briggs 6287b4096d Changes from Denny Gentry <denny1@home.com>:
Change in the way receive buffer areas are handled.  Before we gave
the chip 16 buffers, each 1536 bytes (big enough for one packet).
Now we're handing the chip 8 buffers, each 4 Kbytes, and letting
the chip fit as many packets as it can in each one.  This should
help keep it from running out of buffer space.  Also make some of
the performance-crucial routines inline.  It made no measurable
difference except to make me feel better

Changes from Bob Nestor <rnestor@metronet.com> to get closer to support
for his Apple SONIC-based nubus card.

Changes from me to try to get SONIC's MAC address from MacOS settings if
we can't read the PROM space.
1997-04-10 03:22:45 +00:00
briggs 574874a2a9 Changes from Bob Nestor to come closer to supporting his Apple SONIC-based
nubus card.
1997-04-10 03:19:46 +00:00
scottr 58d41d0f98 Fix several more instances where the volatile modifier was needed.
From Allen.
1997-04-08 06:53:28 +00:00
briggs df0a7e0440 Changes from Michael R. Zucca <mrz5149@cs.rit.edu> for 16-bit and 32-bit
console support.
1997-04-08 04:47:08 +00:00
scottr 4d9095b0b0 Updates from John Wittkoski for new ADB driver. 1997-04-08 03:19:04 +00:00
scottr 76c66a06b3 Direct-to-hardware ADB interface/driver, written by John P. Wittkoski. 1997-04-08 03:16:18 +00:00
scottr 484820c623 Power Manager interface/driver, written by Takashi Hamada. 1997-04-08 03:11:37 +00:00
scottr f65f7e9b21 Always enable SCSI IRQ interrupt; the SBC_INTR flag now controls only
the SCSI DRQ interrupt, for "blind" transfers.
1997-04-07 05:56:28 +00:00
scottr 29c981b924 Rework PDMA read/write functions based on Matthias Pfaller's pc532 ncr
driver.  Major highlights:

 - Protect with splbio(), now that interrupts from the chip might be
   enabled by default;
 - Wait for current transfer to complete before returning, rather than
   wait for previous transfer to complete before starting another;
 - Instead of logging a "timeout" message when a target disconnects,
   just return, letting the sbc_ready() and sbc_wait_not_req() print
   timeout messages if such really did occur.

With interrupt changes to sbc_obio.c, disconnect/reselect now works if
configured into the kernel.
1997-04-07 05:48:35 +00:00
briggs 28af7de8a4 Do not set DCR_SYNC for the C/Q[68]xx systems.
Thanks to Steve Brown <sbrown@best.com> for working with me to find this.
1997-04-04 14:54:44 +00:00
briggs ca0531b7f4 Add DrHW for RasterOps CB264--From Scott Reynolds--and link it in to the
proper interrupt routine.
1997-04-01 13:31:38 +00:00
briggs 71bf5ccd79 Remove tag. 1997-04-01 13:31:03 +00:00
briggs a3d5b32614 - Support DAFB machines mo' better. Actually detect if a monitor is
present and initialize a few things.  No color support, yet.
  - Properly disable interrupts for DAFB.
  - Rearrange for better nubus display card interrupt support.  Only register
    an interrupt if we know how to clear it.
  - Complain if we don't know about a given display card and can not install
    an interrupt handler.
  - Change MYSTERY stuff to cb264--still need to get the DrSW so we can
    actually call the routine to clear an interrupt from this card.
1997-04-01 05:41:59 +00:00
briggs 2606fe6cbd Some new SONIC code from Denny Gentry <denny1@home.com> with a couple of
tweaks and bug fixes by yours truly.

Here's what Denny had to say:

nubus.h:
        - add a drsw entry for my card
	[ I also added a couple of constants for more display cards ]
if_sn.c:
        - allocate sc->space using malloc (Scott wanted this).
        - make csr accesses use NIC_PUT/GET, remove sc->sc_csr.
        - add multicast and IFF_PROMISC support. multicast isn't
                well tested, but I made sure the unicast case still
                works.
        - finish the new arp interface, remove sc->sc_enaddr
if_snreg.h:
        - remove struct sonic_reg
if_snvar.h:
        - add NIC_PUT and NIC_GET macros a la if_ae
        - remove sc_txhead, it isn't used.
if_sn_nubus.c:
        - clean up support for my SE/30 card.
        - Move add_nubus_intr from if_sn.c (to keep if_sn.c MI)
if_sn_obio.c:
        - make Q610, C610, Q650, C650, Q800 use EXBUS.
        - PB500 had a "return" where "break" was intended. PB500
                probably wasn't working.
        - move add_nubus_intr from if_sn.c.
        - add an "explanation" why Apple's ethernet addr is encoded
                in token ring format in the PROM.
1997-03-30 19:51:44 +00:00
briggs e15f7fac43 Fix bug that would have prevented PB5xx series from detecting the SONIC.
Bug noticed by Denny Gentry.
1997-03-29 02:34:40 +00:00
scottr 1c9987dab4 Several minor changes:
- Indent some comments appropriately per KNF.
 - Output all diagnostics using the device name rather than a static string.
 - Fix a (mostly marmless) bug in snintr(), where loss of heartbeat wasn't
   properly ignored and could mask the `receive descriptors exhausted'
   diagnostic.
1997-03-20 17:47:51 +00:00
scottr 1c0a3c8ce7 Several more changes to move us toward MI-ness:
- Use more consistent and portable types in the softc.
 - Map registers using an array of bus_size_t offsets, and set up the
   mapping in the attach code (thanks to Jason Thorpe for suggesting
   this!).
 - Disable the ae-specific watchdog, which is no longer necessary in
   the general case.

Still remaining:  split out functions used to copy data to/from the
card, and retain a way to have a local driver name with the MI code.
1997-03-19 08:04:38 +00:00
briggs 79c7b2b3f4 Help this compile and get the nubus address into myaddr instead of
sc->sc_arpcom.ac_enaddr.
1997-03-18 00:34:31 +00:00
scottr 52348e9646 Some cards we identify as InterLAN cards do not seem to have the MAC
address in the configuration ROM.  For these, fall back to the old method
if we can't find the expected sResource record.
1997-03-17 20:26:01 +00:00
scottr 3c9709606d Clean up some missed pieces of the new ARP conversion. 1997-03-17 18:37:17 +00:00
briggs b315c448dc Flip around Takeshi Yanagisawa's name. Add back a physaccess() call that I was a bit hasty
in removing.
1997-03-17 13:11:24 +00:00
briggs 559613a9a7 *Blush* It's Denton, not Dennis, Gentry. 1997-03-17 12:26:52 +00:00
briggs e716e490a1 Make this compile again. XXX - save ethernet address in softc until multicast is supported. 1997-03-17 04:57:56 +00:00
briggs c20d7dc997 Integrate a couple of changes suggested by Scott Reynolds and Takeshi Yanagisawa. 1997-03-17 04:38:28 +00:00
is 530a88d144 On request from Allen Briggs, converted this to new ARP
system. Somebody should actually test if this compiles (and works) on
Mac68k... I only carefully checked cvs diff -u.
1997-03-16 13:41:14 +00:00
briggs 4b6b2bb9f8 SONIC driver--originally from pica. Much work done by Dennis Gentry and
Takeshi Yanagisawa to get it working.  Some minor hacking by me here and
there.
1997-03-15 20:26:35 +00:00
scottr 702735759b Defer enabling NuBus slot interrupts until all slots have been probed
and drivers attached.  This removes the need for the MAC68K_BROKEN_VIDEO
option.  From Allen Briggs.
1997-03-15 18:33:44 +00:00
is 07b064e02e New ARP system, supports IPv4 over any hardware link.
Some of the stuff (e.g., rarpd, bootpd, dhcpd etc., libsa) still will
only support Ethernet. Tcpdump itself should be ok, but libpcap needs
lot of work.

For the detailed change history, look at the commit log entries for
the is-newarp branch.
1997-03-15 18:09:08 +00:00
scottr 12098dae8a Add missing call to ae_nb_get_enaddr(), from <kei_sun@ba2.so-net.or.jp>.
Fixes PR 3312.
1997-03-10 17:55:15 +00:00
briggs a2173962b8 Copyright foo. 1997-03-05 15:19:18 +00:00
scottr fd81cf2b92 Correct offsets in the memory size probe; bus_space uses byte offsets. Fix suggested by
Ken Nakata.
1997-03-04 15:12:04 +00:00
scottr 421abedbfe Split bus-dependent autoconfig code from the driver. This allows for
the future addition of a Duo Dock front end.
1997-03-01 20:18:58 +00:00
scottr 42be6ebfa7 Fix prototype for espmatch() 1997-03-01 06:38:36 +00:00
scottr 215c0b896a Convert to generalized VIA interrupt registration 1997-02-28 15:50:50 +00:00
scottr 705c637874 Define aesetup() to return an int, so that the attach function can
determine whether there was an error (if so, we unmap the slot space
for this device).  Use this functionality to tell the attach function
that we couldn't clear the card's buffer.

Also in aesetup(), eliminate the bogus repetition of the error message
we print when the buffer clear actually fails.  Noticed by Hauke Fath.
1997-02-28 08:56:05 +00:00
scottr 0b3eb5f3f2 Remove duplicate <machine/bus.h> include that crept in. 1997-02-28 07:54:02 +00:00
scottr 17fdd597df Move the NuBus-specific watchdog function from if_ae.c to if_ae_nubus.c,
and allow the attach function to override the default watchdog.  Also,
do some minor cosmetic surgery (rename bus space tags/handles and some
KNFing I missed the first time around).
1997-02-28 07:52:44 +00:00
scottr 359101fb43 Convert to generalized VIA interrupt registration 1997-02-28 07:46:59 +00:00
briggs 868344972a mac68k-specific portion of m.i. ncr53c9x driver. 1997-02-27 14:06:25 +00:00
gwr 2de163471e Minimal changes to adapt to removal of NCR5380_PERMIT_RESELECT.
This driver should be updated to allow per-target control over
disconnect/reselect, but I will leave that to the port masters.
1997-02-26 22:29:08 +00:00
scottr a2a40938b1 Move bus-independent setup code back into if_ae.c; enable the use of
configuration flags.  For NuBus cards, attempt to find the MAC address
in the declaration ROM resources.
1997-02-25 06:36:04 +00:00
scottr f03ee128a3 Add support for the Kinetics EtherPort SE/30, from Ken Nakata. 1997-02-24 07:34:18 +00:00
scottr 965cffaf20 NUBUS_SLOT_TO_PADDR -> NUBUS_SLOT2PA 1997-02-24 06:20:04 +00:00
scottr 6b0774a865 Split out the NuBus attachment code, and convert to bus.h 1997-02-24 06:03:55 +00:00
scottr 9c91a181d6 Update copyright and license. 1997-02-24 05:47:33 +00:00
scottr db2ab09cf2 Add bus.h, in light of recent nubus_attach_args changes 1997-02-22 02:17:40 +00:00
scottr ec6725f267 Make this compile again; missed this file when fixing nubus.h errors. 1997-02-22 00:00:34 +00:00
scottr b1e5912330 We need bus.h now, due to recent nubus_attach_args change. 1997-02-20 00:23:25 +00:00
scottr c079123e89 Add a bus space tag field to nubus_attach_args 1997-02-19 06:21:49 +00:00