summaryrefslogtreecommitdiffstats
path: root/sys/i4b
Commit message (Collapse)AuthorAgeFilesLines
* Since DELAY() was moved, most <machine/clock.h> #includes have beenphk2006-05-168-8/+0
| | | | unnecessary.
* PR: kern/76611hm2006-05-131-8/+8
| | | | | | Submitted by: Mauritz Sundell and Sergio de Souza Prallon Reviewed by: hm@ fix several constants for the Tiger320 ISDN chip
* Fix -Wundef warnings found when compiling i386 LINT, GENERIC andru2005-12-054-8/+8
| | | | custom kernels.
* Propagate rename of IFF_OACTIVE and IFF_RUNNING to IFF_DRV_OACTIVE andrwatson2005-08-092-5/+6
| | | | | | | | | | | | | | IFF_DRV_RUNNING, as well as the move from ifnet.if_flags to ifnet.if_drv_flags. Device drivers are now responsible for synchronizing access to these flags, as they are in if_drv_flags. This helps prevent races between the network stack and device driver in maintaining the interface flags field. Many __FreeBSD__ and __FreeBSD_version checks maintained and continued; some less so. Reviewed by: pjd, bz MFC after: 7 days
* Fix some long standing bugs in writing to the BPF device attached todwmalone2005-06-261-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | a DLT_NULL interface. In particular: 1) Consistently use type u_int32_t for the header of a DLT_NULL device - it continues to represent the address family as always. 2) In the DLT_NULL case get bpf_movein to store the u_int32_t in a sockaddr rather than in the mbuf, to be consistent with all the DLT types. 3) Consequently fix a bug in bpf_movein/bpfwrite which only permitted packets up to 4 bytes less than the MTU to be written. 4) Fix all DLT_NULL devices to have the code required to allow writing to their bpf devices. 5) Move the code to allow writing to if_lo from if_simloop to looutput, because it only applies to DLT_NULL devices but was being applied to other devices that use if_simloop possibly incorrectly. PR: 82157 Submitted by: Matthew Luckie <mjl@luckie.org.nz> Approved by: re (scottl)
* Fix a number of now bogus casts I missed the first time around (I mustbrooks2005-06-171-8/+7
| | | | | | | have failed to grep this file properly). Reported by: Hans Petter Selasky <hselasky at c2i dot net> Approved by: re (ifnet blanket)
* Refer to the correct file/function in panic messages.brooks2005-06-171-2/+2
| | | | | Reported by: Hans Petter Selasky <hselasky at c2i dot net> Approved by: re (ifnet blanket)
* Stop embedding struct ifnet at the top of driver softcs. Instead thebrooks2005-06-102-151/+149
| | | | | | | | | | | | | | | | | | | | struct ifnet or the layer 2 common structure it was embedded in have been replaced with a struct ifnet pointer to be filled by a call to the new function, if_alloc(). The layer 2 common structure is also allocated via if_alloc() based on the interface type. It is hung off the new struct ifnet member, if_l2com. This change removes the size of these structures from the kernel ABI and will allow us to better manage them as interfaces come and go. Other changes of note: - Struct arpcom is no longer referenced in normal interface code. Instead the Ethernet address is accessed via the IFP2ENADDR() macro. To enforce this ac_enaddr has been renamed to _ac_enaddr. - The second argument to ether_ifattach is now always the mac address from driver private storage rather than sometimes being ac_enaddr. Reviewed by: sobomax, sam
* Remove bus_{mem,p}io.h and related code for a micro-optimization on i386nyan2005-05-291-1/+0
| | | | | | and amd64. The optimization is a trivial on recent machines. Reviewed by: -arch (imp, marcel, dfr)
* Don't use 'i386/include' directly.nyan2005-04-081-2/+2
|
* Add device ID for Planet IA 128P-STD card.murray2005-03-191-0/+2
| | | | | | PR: kern/71923 Submitted by: Vassily Kiryanov <admin@assist.berezniki.ru> MFC after: 1 week
* /* -> /*- for copyright notices, minor format tweaks as necessaryimp2005-01-06126-374/+498
|
* Mark i4b IPR and SPPP drivers as NET_NEEDS_GIANT(), as they bothrwatson2004-10-122-0/+4
| | | | | | | | interface with the network stack but are not yet sufficiently synchronized to run without the Giant lock. It migh be possible to mark the interfaces as IFF_NEEDSGIANT, but I'm unable to test that configuration and am unfamiliar with the architecture of i4b.
* Kill count device support from config. I've changed the last fewpeter2004-08-308-19/+6
| | | | | | | | | | | | | | | | | remaining consumers to have the count passed as an option. This is i4b, pc98/wdc, and coda. Bump configvers.h from 500013 to 600000. Remove heuristics that tried to parse "device ed5" as 5 units of the ed device. This broke things like the snd_emu10k1 device, which required quotes to make it parse right. The no-longer-needed quotes have been removed from NOTES, GENERIC etc. eg, I've removed the quotes from: device snd_maestro device "snd_maestro3" device snd_mss I believe everything will still compile and work after this.
* Apply error and success logic consistently to the function netisr_queue() andandre2004-08-271-5/+1
| | | | | | | | | | | | | | | | | | its users. netisr_queue() now returns (0) on success and ERRNO on failure. At the moment ENXIO (netisr queue not functional) and ENOBUFS (netisr queue full) are supported. Previously it would return (1) on success but the return value of IF_HANDOFF() was interpreted wrongly and (0) was actually returned on success. Due to this schednetisr() was never called to kick the scheduling of the isr. However this was masked by other normal packets coming through netisr_dispatch() causing the dequeueing of waiting packets. PR: kern/70988 Found by: MOROHOSHI Akihiko <moro@remus.dti.ne.jp> MFC after: 3 days
* Fix a possible hang which apparently occurs during a warm boot (cold bootgj2004-07-181-0/+8
| | | | | | | | | | | does not display the symptom). Evidently the ifpi2 controller needs to be massaged more than it was. Note that this does not close the PR since it was filed against 4.9. MFC: 5 days PR: kern/68756 Submitted by: Ari Suutari <ari.suutari@syncrontech.com>
* Do a pass over all modules in the kernel and make them return EOPNOTSUPPphk2004-07-151-0/+2
| | | | | | | | for unknown events. A number of modules return EINVAL in this instance, and I have left those alone for now and instead taught MOD_QUIESCE to accept this as "didn't do anything".
* Catch up with the new world order of Netgraph metas.ru2004-07-061-15/+3
| | | | | | (This one was the last, according to grep(1).) Submitted by: Gleb Smirnoff
* Add another ifdef...imp2004-07-051-0/+2
|
* meta_p is a void *, so a variable that's of type void * can't beimp2004-07-041-1/+4
| | | | | | | | | | | | dereferenced directly. Toss an ifdef around it for the moment and allow this to compile. This likely means that priority packets aren't queued to the special high priority queue. The maintainer of this should look into the problem. This is likely fallout from the netgraph migration to using a more generic meta tag from the mbug recently. Fixes: pc98 tinerbox
* Be BURN_BRIDGES compliantphk2004-06-211-1/+1
|
* Do the dreaded s/dev_t/struct cdev */phk2004-06-165-26/+26
| | | | Bump __FreeBSD_version accordingly.
* Link ALTQ to the build and break with ABI for struct ifnet. Please recompilemlaier2004-06-131-1/+1
| | | | | | | | | | | | your (network) modules as well as any userland that might make sense of sizeof(struct ifnet). This does not change the queueing yet. These changes will follow in a seperate commit. Same with the driver changes, which need case by case evaluation. __FreeBSD_version bump will follow. Tested-by: (i386)LINT
* add missing #include <sys/module.h>phk2004-05-303-0/+3
|
* Switch to using C99 sparse initialisers for the type methods array.julian2004-05-291-12/+10
| | | | | | | | Should make no binary difference. Submitted by: Gleb Smirnoff <glebius@cell.sick.ru> Reviewed by: Harti Brandt <harti@freebsd.org> MFC after: 1 week
* Convert callers to the new bus_alloc_resource_any(9) API.njl2004-03-1719-142/+135
| | | | | Submitted by: Mark Santcroos <marks@ripe.net> Reviewed by: imp, dfr, bde
* Device megapatch 4/6:phk2004-02-215-0/+10
| | | | | | | | Introduce d_version field in struct cdevsw, this must always be initialized to D_VERSION. Flip sense of D_NOGIANT flag to D_NEEDGIANT, this involves removing four D_NOGIANT flags and adding 145 D_NEEDGIANT flags.
* Device megapatch 1/6:phk2004-02-215-10/+0
| | | | | | | Free approx 86 major numbers with a mostly automatically generated patch. A number of strategic drivers have been left behind by caution, and a few because they still (ab)use their major number.
* Based on an excellent suggestion from tanimura@ define I4BPRI and use itgj2003-11-105-47/+22
| | | | in place of TTIPRI.
* Fix breakage cuased by the selwakeuppri commit by defining TTIPRI forgj2003-11-104-0/+28
| | | | recent versions of FreeBSD (based on __FreeBSD_version check).
* - Implement selwakeuppri() which allows raising the priority of atanimura2003-11-093-10/+10
| | | | | | | | | | | | | thread being waken up. The thread waken up can run at a priority as high as after tsleep(). - Replace selwakeup()s with selwakeuppri()s and pass appropriate priorities. - Add cv_broadcastpri() which raises the priority of the broadcast threads. Used by selwakeuppri() if collision occurs. Not objected in: -arch, -current
* Replace the if_name and if_unit members of struct ifnet with new membersbrooks2003-10-312-10/+10
| | | | | | | | | | | | | if_xname, if_dname, and if_dunit. if_xname is the name of the interface and if_dname/unit are the driver name and instance. This change paves the way for interface renaming and enhanced pseudo device creation and configuration symantics. Approved By: re (in principle) Reviewed By: njl, imp Tested On: i386, amd64, sparc64 Obtained From: NetBSD (if_xname)
* Initialize if_softc and use it in favor of &ipr_softc[ifp->if_unit] tobrooks2003-10-311-3/+4
| | | | get the softc.
* Use PCIR_BAR(x) instead of PCIR_MAPS.jhb2003-09-025-18/+15
| | | | | Glanced over by: imp, gibbs Tested by: i386 LINT
* Prefer new location of pci include files (which have only been in theimp2003-08-226-12/+12
| | | | | tree for two or more years now), except in a few places where there's code to be compatible with older versions of FreeBSD.
* Undo agressive inlining which GCC previously wisely ignored.phk2003-07-232-152/+169
| | | | | The this eliminates 67% of the text segment (relative to respected inline requests).
* Mega busdma API commit.scottl2003-07-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Add two new arguments to bus_dma_tag_create(): lockfunc and lockfuncarg. Lockfunc allows a driver to provide a function for managing its locking semantics while using busdma. At the moment, this is used for the asynchronous busdma_swi and callback mechanism. Two lockfunc implementations are provided: busdma_lock_mutex() performs standard mutex operations on the mutex that is specified from lockfuncarg. dftl_lock() is a panic implementation and is defaulted to when NULL, NULL are passed to bus_dma_tag_create(). The only time that NULL, NULL should ever be used is when the driver ensures that bus_dmamap_load() will not be deferred. Drivers that do not provide their own locking can pass busdma_lock_mutex,&Giant args in order to preserve the former behaviour. sparc64 and powerpc do not provide real busdma_swi functions, so this is largely a noop on those platforms. The busdma_swi on is64 is not properly locked yet, so warnings will be emitted on this platform when busdma callback deferrals happen. If anyone gets panics or warnings from dflt_lock() being called, please let me know right away. Reviewed by: tmm, gibbs
* Use __FBSDID().obrien2003-06-1120-60/+60
|
* Use __FBSDID().obrien2003-06-1033-111/+100
|
* Use __FBSDID().obrien2003-06-107-32/+21
|
* Use __FBSDID().obrien2003-06-1025-86/+76
|
* Fix off-by-one errors in range checks of state machine states & events.phk2003-05-312-8/+8
| | | | Found by: FlexeLint
* Fix systematic off-by-one errors in unit number range checks.phk2003-05-316-11/+11
| | | | Found by: FlexeLint
* Rename BUS_DMAMEM_NOSYNC to BUS_DMA_COHERENT.hmp2003-05-301-2/+2
| | | | | | | | | | | | | | | | | The current name is confusing, because it indicates to the client that a bus_dmamap_sync() operation is not necessary when the flag is specified, which is wrong. The main purpose of this flag is to hint the underlying architecture that DMA memory should be mapped in a coherent way, but the architecture can ignore it. But if the architecture does supports coherent mapping of memory, then it makes bus_dmamap_sync() calls cheap. This flag is the same as the one in NetBSD's Bus DMA. Reviewed by: gibbs, scottl, des (implicitly) Approved by: re@ (jhb)
* - Add vm_paddr_t, a physical address type. This is required for systemsjake2003-03-252-2/+2
| | | | | | | | | | | | | | | where physical addresses larger than virtual addresses, such as i386s with PAE. - Use this to represent physical addresses in the MI vm system and in the i386 pmap code. This also changes the paddr parameter to d_mmap_t. - Fix printf formats to handle physical addresses >4G in the i386 memory detection code, and due to kvtop returning vm_paddr_t instead of u_long. Note that this is a name change only; vm_paddr_t is still the same as vm_offset_t on all currently supported platforms. Sponsored by: DARPA, Network Associates Laboratories Discussed with: re, phk (cdevsw change)
* Update netisr handling; Each SWI now registers its queue, and all queuejlemon2003-03-041-1/+1
| | | | | | | | | | drain routines are done by swi_net, which allows for better queue control at some future point. Packets may also be directly dispatched to a netisr instead of queued, this may be of interest at some installations, but currently defaults to off. Reviewed by: hsu, silby, jayanth, sam Sponsored by: DARPA, NAI Labs
* Gigacommit to improve device-driver source compatibility betweenphk2003-03-035-65/+36
| | | | | | | | | | | | | branches: Initialize struct cdevsw using C99 sparse initializtion and remove all initializations to default values. This patch is automatically generated and has been tested by compiling LINT with all the fields in struct cdevsw in reverse order on alpha, sparc64 and i386. Approved by: re(scottl)
* More low-hanging fruit: kill caddr_t in calls to wakeup(9) / [mt]sleep(9).des2003-03-024-28/+28
|
* NODEVFS cleanup:phk2003-02-265-76/+0
| | | | | Don't call cdevsw_{add,remove}() Remove remnants of the previous DEVFS.
* Back out M_* changes, per decision of the TRB.imp2003-02-194-11/+11
| | | | Approved by: trb
OpenPOWER on IntegriCloud