Commit Graph

88 Commits

Author SHA1 Message Date
martin 0db68b667b Now that we have all pieces in place (and enough granularity to specify
B-channel and D-channel drivers separately) split the Fritz!PCI card
driver out of the isic driver.

The new device is called "ifpci" and uses the same D-channel driver as the
isic devices, but has it's own B-channel driver.
2002-03-25 16:39:52 +00:00
martin 909e313a80 Remove a leftover from the BRI registry at layer 2.
Initialize layer 2's idea of it's BRI id after attaching.
2002-03-25 14:44:46 +00:00
martin 963ecd396e Plug a memory hole when detaching ISDN controllers. 2002-03-25 14:25:06 +00:00
martin a994533d0a Make pcmcia cards detach properly.
Notify userland of attaching/detaching cards.
This partly fixes PR 15951.
2002-03-25 12:07:33 +00:00
martin 0bc69b6498 Now that we have all the pieces of the puzzle available start to unriddle
and move them in their proper places.

Move the BRI registry from layer 2 (duh!) to layer 4, so active cards
(which don't have layer 3 or layer 2 in their driver). Remove all remaining
hard coded controller and driver types. Remove any arbitrary hard coded
limits, at least those that show up in the internal API.

This fixes PR 15950.
2002-03-24 20:35:43 +00:00
martin 9cea4a0ab0 Bring the daic driver into the new ISDN world order.
Enable active card support in the ISDN subsystem. (Had been disabled since
it couldn't be tested before.)
2002-03-22 09:54:15 +00:00
martin 4a7710e8d9 Fix a long standing confusion between n_mgm_command and mph_command_req
by removing the former completely.
This makes isdntrace work again.
2002-03-19 20:10:45 +00:00
martin af693ebcf6 Wakeup sleeping processes when the ISDN connection gets established
or disestablished. Hint from Matthias Drochner.
2002-03-18 23:28:03 +00:00
martin b07c2da1c9 Fix an uninitialized use of a variable by removing it completely. 2002-03-18 22:15:28 +00:00
martin e2c42aeaa8 Remove all knowledge about specific application (layer 4) drivers from
the generic layer 4 and layer 3 management system.

This should make the layer 4 driver API LKM clean - finaly.

Make the Fritz!PCI driver work again after resent changes (oops!),
noted by Frank Kardel (PR 15948) and Matthias Scheeler.
2002-03-17 20:54:04 +00:00
martin 14a03255ac Remove the hard coded layer 4 driver coding from the accounting data
and functions, use the call ID instead.
2002-03-17 11:08:31 +00:00
martin 1e802e7eba Clean up the application (layer 4) driver vs. B channel driver interface.
One step further on the way to make layer 4 drivers LKMable.
2002-03-17 09:45:58 +00:00
martin 94881fb123 Rename ISDN devices, per discussion on tech-kern. The network devices
become ippp (ISDN ppp) and irip (ISDN raw IP). The character device now
are called: /dev/isdn (isdnd <-> kernel communication), /dev/isdnctl (dialing
and other control), /dev/isdntrc* (tracing), /dev/isdnbchan* (raw B channel
access, i.e. for user land PPP) and /dev/isdntel* (telephone devices, i.e.
for answering machines).
2002-03-16 16:55:51 +00:00
drochner c651007643 until the B-channel bookkeeping is fixed, do at least as much as necessary
to get rid of bogus error messages
2002-02-14 16:46:23 +00:00
drochner 29cc8db414 until the B-channel bookkeeping is fixed, do at least as much as necessary
to get rid of bogus error messages
2002-02-14 16:20:47 +00:00
drochner 3131bb3941 Reduce the "unknown protocol discriminator" message from "error" to
"information". On my mixed Euro-ISDN/1TR6 line I get fooded otherwise.
2002-02-14 16:17:05 +00:00
martin 046f73ccbb More ALTQ gotchas from Thomas Klausner:
Use IFQ_SET_MAXLEN instead of accesing opaque queue members directly.
Don't forget to IFQ_SET_READY the queue.
2002-02-10 15:29:58 +00:00
martin 7942602380 Don't crash when trying to read phone data while there is no ISDN
connection. From FreeBSD, via Matthias Drochner.
2002-01-27 11:42:13 +00:00
martin a585d748dc Duplicate include protection. 2002-01-21 11:38:16 +00:00
martin f1c55df387 Now that the sppp driver has a payload based timestamp, use that to calculate
ISDN timeouts as well. Now LCP echo request/replies won't keep the connection
open any more.
2002-01-06 20:18:19 +00:00
martin cd66b662e5 Slight stylistic cleanup, no functional change. 2002-01-06 13:26:46 +00:00
martin 99772f59c4 Move net/if_sppp.h to net/if_spppvar.h, create a new net/if_sppp.h
containing the userland visible thinks (i.e. ioctl definitions).

Remove all (both) old ioctls, as they had a brain dead API and made keeping
binary compatibility more or less impossible.

Replace by several new ioctls. While there, remove any arbitrary limits
(resulting from the old, broken ioctls) and allow any length of names
and passwords.
2002-01-04 12:21:24 +00:00
lukem 2565646230 don't need <sys/types.h> when including <sys/param.h> 2001-11-15 09:47:59 +00:00
lukem 4f2ad95259 add RCSIDs 2001-11-13 00:56:55 +00:00
martin 5eb2c7d064 Install i4b_rbch_ioctl.h, it is needed i.e. for userland PPP.
Requested by Brian Somers.
2001-10-21 17:02:06 +00:00
wiz 456dff6cb8 Spell 'occurred' with two 'r's. 2001-09-16 16:34:23 +00:00
wiz 1e378c4c12 precede, not preceed. 2001-08-20 12:00:46 +00:00
jdolecek 47849859a8 Don't allow the size of active diagnostics parameter be bigger than
newly added I4B_ACTIVE_DIAGNOSTIC_MAXPARAMLEN (currently 64KB).
2001-08-05 11:16:56 +00:00
martin 125af1e024 bcopy -> memcpy; Nuke bogus local compatibility defines for it. 2001-07-08 10:33:58 +00:00
itojun 4d51fe368b change the meaning of ifnet.if_lastchange to meet RFC1573 ifLastChange.
follows BSD/OS practice and ucd-snmp code (FreeBSD does it for specific
interfaces only).

was: if_lastchange get updated on every packet transmission/receipt.
now: if_lastchange get updated when IFF_UP is changed.
2001-06-14 05:44:23 +00:00
martin 83930a016c Demangle an #ifdef mess and make all ioctl routines take an u_long
as the command argument. Before we were subject to subtle sign extension
differences depending on char being signed or unsigned.
2001-04-21 07:23:41 +00:00
martin 3caa4d3f4c Specify the size of the framing added to packets (in this case: zero), so
if_sppsubr.c can calculate correct statistics.
2001-04-09 19:35:46 +00:00
martin 5171d409a5 First step to cleanup the hardware driver <-> upper layers interface.
This now provides slightly more functionality than the FreeBSD layer1-newbus
interface. It was meant to be a simple change to one header and a few
c files, but the change rippled all through various stuff.

To prevent a change to the kernel<->userland interface right now the kernel
is now lying about card types to userland (but who cares). This will be fixed
when the userland interface changes, after layer 3 <-> layer 4 has been
fixed.

Functional changes:

Provide a clean interface for hardware drivers to attach to the upper
layers. This will need another small change in the B-channel handling
when a similar change to the layer 3 <-> layer 4 interface happens.

Avoid passing indices into global arrays of pointers around, instead pass
the pointers itself. Don't code hardware driver types by predefined magic
numbers (think LKM). Prepare for detachable drivers (think pcmcia).

While there remove some sets of function pointers always pointing to the
same function (meant to be the configurable set of D channel protocol
handlers). It is unlikely another supported D-channel protocol will fit into
that (maximal layer interface) abstraction. When we get support for another
protocol, we will need to come up with a workable interface. Besides, the
old implementation was, uhm, strange.
2001-03-24 12:40:29 +00:00
martin 4ea2a81ad5 Fix my incomplete attempt to ALTQify this so it now actually works.
Thanks to Ignatios for pointing out the problem and to Jason for spotting
the main error.
2001-02-03 18:43:45 +00:00
martin 0f589a40df Nuke all uses of splimp() in the isdn subsystem, replace by splnet(). 2001-01-19 12:44:44 +00:00
thorpej fc5dafc79b Fix a rather annoying problem where the sockaddr_dl which holds
the link level name for the interface (ifp->if_sadl) is allocated
before ifp->if_addrlen is initialized, which could lead to allocating
too little space for the link level address.

Do this by splitting allocation of the link level name out of
if_attach() and into if_alloc_sadl(), which is normally called
by functions like ether_ifattach().  Network interfaces which
don't have a link-specific attach routine must call if_alloc_sadl()
themselves (example: gif).

Link level names are freed by if_free_sadl(), which can be called
from e.g. ether_ifdetach().  Drivers never need call if_free_sadl()
themselves as if_detach() will do it if it is not already done.

While here, add the ability to pass an AF_LINK address to
SIOCSIFADDR in ether_ioctl() (this is what caused me to notice
the problem that the above fixes).
2001-01-17 00:30:49 +00:00
martin 6b82e7fe42 64bit police.
Rumors say there are archs without ISA busses, so avoid including
(uneccesarily) isa bus headers in MI files.
XXX this is the minimal solution, layer interface calls will have
XXX to be revisited later
2001-01-07 21:47:24 +00:00
martin c3cb638bca Initial import of ISDN4BSD release 0.96 2001-01-05 12:49:52 +00:00