Commit Graph

380 Commits

Author SHA1 Message Date
isaki
4fc2ffd701 Correct rev1.11.
Fix panic reported by Yasushi Oshima.
2010-05-08 02:48:31 +00:00
tsutsui
8f7c20ed4f Put several fixes to ne(4) driver for better 8 bit mode support,
especially on RTL8019AS which is also used for non-ISA local bus of
embedded controllers and some m68k machines like atari and x68k.

 * move RTL8019 probe and attach code from each bus attachment
   to MI ne2000_detect() and ne2000_attach()
 * change a method for backend and attachment to specify 8 bit mode
   to use a new sc->sc_quirk member, instead of sc->sc_dmawidth
 * handle more NE2000 8 bit mode specific settings, including
   bus_space(9) access width and available size of buffer memory
 * add a function to detect NE2000 8 bit mode
   (disabled by default, but enalbed by options NE2000_DETECT_8BIT
    to avoid possible regression on various ISA clones)
 * fix ipkdb attachment accordingly (untested)

Tested on two NE2000 ISA variants (RTL8019AS and another clone named UL0001)
in both 8 bit and 16 bit mode on i386. "Looks good" from nonaka@.

See my post on tech-kern for details:
http://mail-index.NetBSD.org/tech-kern/2010/02/26/msg007423.html
2010-03-03 13:39:57 +00:00
pooka
10fe49d72c Redefine bpf linkage through an always present op vector, i.e.
#if NBPFILTER is no longer required in the client.  This change
doesn't yet add support for loading bpf as a module, since drivers
can register before bpf is attached.  However, callers of bpf can
now be modularized.

Dynamically loadable bpf could probably be done fairly easily with
coordination from the stub driver and the real driver by registering
attachments in the stub before the real driver is loaded and doing
a handoff.  ... and I'm not going to ponder the depths of unload
here.

Tested with i386/MONOLITHIC, modified MONOLITHIC without bpf and rump.
2010-01-19 22:06:18 +00:00
isaki
8cf7d2d787 Make compile with DEBUG. 2010-01-09 09:16:32 +00:00
isaki
bdc7b127e2 Correct return value of ne_*_match().
It's attach priority, not ne2000 model.
2009-11-28 03:10:09 +00:00
rmind
3dc24f5a91 Use lwp_getpcb() on m68k ports, clean from struct user usage. 2009-11-23 00:11:42 +00:00
snj
886d7f6c39 Drop 3rd and 4th clauses on this TNF-copyrighted file. 2009-11-07 19:54:17 +00:00
isaki
34b7dffc11 - malloc() + memset(0) -> malloc(M_ZERO).
- remove temporary variable.
2009-01-18 05:00:39 +00:00
isaki
0a5ccf5143 Delete 10 years old #if 0'd comments in intio.c, locore.s.
According to the old comment, the interrupt handler via intiotrap
should set his interrupt level again, but it's not right.  And
don't set it again by interrupt hander.
2009-01-18 04:48:53 +00:00
isaki
8ca78cfb4e Clean up header files. 2009-01-18 02:40:05 +00:00
isaki
60e2f02631 Split device_t/softc, use aprint*(). 2009-01-17 10:02:23 +00:00
isaki
cbd07c5ca6 Purge x68k_config_found() to simplify consinit routine.
config_console() calls initialization of grf, ite, mfp
directly, instead of tracing special device tree with an
emulated 'struct device'.
2009-01-17 09:20:46 +00:00
isaki
691579f364 Use firm_gettime() (in dev/sun/vuid_event.h) to adapt
changes in chiristos-time_t.
2009-01-17 03:26:31 +00:00
yamt
70de973662 g/c BUFQ_FOO() macros and use bufq_foo() directly. 2009-01-13 13:33:58 +00:00
isaki
917e1cad29 Clean up messages.
- fdcintr: remove duplicated status message.
- fdioctl: make it easy to track ioctl.
2009-01-10 06:45:06 +00:00
isaki
9c9d081d26 fdc->sc_dev is not necessary. 2009-01-10 06:41:06 +00:00
isaki
8cb1e6831d rtclockinit() and range_test*() were removed in rtclock.c,v 1.19. 2009-01-03 09:32:13 +00:00
isaki
aea81d8a0f struct device * -> device_t. 2008-12-31 09:50:21 +00:00
isaki
7563f448e7 Search all of mfp(4)'s children automatically, instead of
attaching hard-coded children.  mfp(4) was trying to attach
pow(4) though pow(4) was a pseudo-device for a long time.
2008-12-31 08:00:31 +00:00
isaki
06cefe4345 Make sram(4) a hardware device.
# I wrote this in 2001 :-)
2008-12-21 09:01:19 +00:00
isaki
cf59801230 x68k pow(4) now uses MI sysmon_pswitch framework. suggested by tsutsui@.
- Make MD poffd(8) retire, and use MI powerd(8) instead of it.
- Make /dev/pow1 retire, because nobody holds /dev/pow0 any longer.
  Use /dev/pow0 for pow(4) ioctl.
- POWIOCSSIGNAL ioctl which is for poffd(8) is also obsoleted.
2008-12-20 13:20:58 +00:00
isaki
c238dc3262 Make pow(4) a hardware device.
Now pow(4) uses intio_intr_establish() which is a common interrupt
routine, but not powtrap which is a device specific routine.
2008-12-20 01:05:46 +00:00
isaki
3b878f898f Sync with other m68k ports.
- Remove PHYS_IODEV, PHYS_INTIODEV. These are real copy of INTIOBASE.
- Define IIOV() (and IIOP()) and use it, rather than INTIO_ADDR().
2008-12-18 05:56:42 +00:00
isaki
ae6ae44eaf Move external decl. of intiobase: dev/intiovar.h -> include/cpu.h
Move definition of intiobase: x68k/pmap_bootstrap.c -> x68k/locore.s
These synchronize code with other m68k ports.
2008-12-18 05:24:03 +00:00
isaki
dc21f7bf9b Make it compilable again. 2008-12-18 03:18:27 +00:00
isaki
b3f443b573 Remove intr_reset(), which has disabled device interrupt just
after start in locore.s.  Initializing interrupt should be done
by each device driver.
2008-12-18 02:27:41 +00:00
christos
9a5d3f2817 replace bitmask_snprintf(9) with snprintb(3) 2008-12-16 22:35:21 +00:00
isaki
5b2d4637e6 Use intio_set_*() macros to purge macros by the name of sysport, ioctlr. 2008-12-14 02:16:51 +00:00
isaki
1c83a96ebb Use mfp_{set,clear}_*() macros to purge macros by the name of 'mfp'. 2008-12-14 02:05:54 +00:00
isaki
b3a08741f8 Fix a broken 'Front power switch' signal.
Use softint(9), instead of using psignal(9) in
hardware interrupt.  Thanks to soda-san.
2008-12-13 02:49:10 +00:00
isaki
3cffa23a3e Use TAILQ_* macros. 2008-12-05 13:14:42 +00:00
isaki
74a27b3322 Rename variables to avoid confusing. forgotten in previous commit. 2008-11-29 06:16:49 +00:00
isaki
03f059cb18 Split device_t/softc. Use aprint*() and device_xname().
Not tested. I cannot test now...
2008-11-29 06:02:52 +00:00
isaki
b823d19d77 Split device_t/softc. Use aprint*() and device_xname().
Not tested. I don't have its hardware and no response in port-x68k.
2008-11-29 05:59:40 +00:00
isaki
7379f550c7 Make it compilable even if FDDEBUG was defined. 2008-06-29 09:44:11 +00:00
isaki
b50b2ac3ed Split device_t/softc for dmac_*_xfer().
Rename some variables to avoid confusing.
2008-06-25 13:30:24 +00:00
isaki
2b1a1a9c7f Link to device_t. I had forgotten it in previous commit. 2008-06-25 12:56:40 +00:00
isaki
7afa6fc259 struct cfdata -> cfdata_t. 2008-06-25 08:19:37 +00:00
isaki
2830b81add Split device_t/softc. Use aprint*() and device_xname(). 2008-06-25 08:14:59 +00:00
isaki
af8a8d9630 Make intio_intr_establish() use evcnt(9),
instead of dynamic allocation of intrnames/intrcnt.
2008-06-23 08:33:38 +00:00
isaki
661719fa0e Fix compile errors. 2008-06-14 13:36:24 +00:00
cegger
61f21080d9 use device_lookup_private to get softc 2008-06-13 13:57:58 +00:00
tsutsui
40b72ee81a Use device_private() and device_lookup_private() to get softc. 2008-06-08 16:39:11 +00:00
ad
b18c28f549 PR kern/38763 "hanging in tty" bugfix breaks the build for vax (and
probably others)
2008-05-27 14:13:41 +00:00
isaki
5fc34baa9d Catch up with device_t/device_xname changes on MI USB part. 2008-05-23 13:27:40 +00:00
martin
b46765907d Minor typo in license 2008-05-10 11:49:37 +00:00
isaki
007dbd3e78 Make it retire, because no one refers.
arch/x68k/dev/spc.c includes <dev/ic/mb89352reg.h> instead of
this, since 1999.
2008-05-10 10:37:38 +00:00
tsutsui
dba35d8b76 CFATTACH_DECL() -> CFATTACH_DECL_NEW(), botched in rev 1.14. 2008-05-09 10:09:27 +00:00
martin
673523f500 Move to standard TNF 2 clause license 2008-05-04 00:35:37 +00:00
martin
ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00