Commit Graph

1941 Commits

Author SHA1 Message Date
dsl 6f0f9f8763 Make almost everything #include <sys/bswap.h> instead of <machine/bswap.h>
The bswap.h and endian.h files are all rather incestuous, but I want to
get the constant folding stuff into one place - sys/bswap.h
2006-01-29 21:42:40 +00:00
bouyer bf1a4d2af5 properly use ata_channel->ch_ndrive:
- initialize it properly in the bus front-ends (all 2, exept in wdc_pcmcia.c
  for the "Sandisk CompactFlash Card" where it's set to 1)
- remplace hardcoded '2' by ata_channel->ch_ndrive in MI IDE drivers.

From Christos Zoulas in kern/32501.
2006-01-16 20:30:18 +00:00
yamt 7b826aac85 initialize necessary members of struct buf. PR/32462 from Reinoud Zandijk. 2006-01-06 09:21:44 +00:00
yamt 690d424f28 - add simple functions to allocate/free a buffer for i/o.
- make bufpool static.
2006-01-04 10:13:05 +00:00
perry 3d4ed1fbc7 __inline__ -> inline 2005-12-24 23:41:33 +00:00
perry 93124077ae Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete. 2005-12-24 20:27:29 +00:00
christos 95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
yamt aec75b1cc6 - change the way to specify a bufq strategy. (by string rather than by number)
- rather than embedding bufq_state in driver softc,
  have a pointer to the former.
- move bufq related functions from kern/subr_disk.c to kern/subr_bufq.c.
- rename method to strategy for consistency.
- move some definitions which don't need to be exposed to the rest of kernel
  from sys/bufq.h to sys/bufq_impl.h.
  (is it better to move it to kern/ or somewhere?)
- fix some obvious breakage in dev/qbus/ts.c.  (not tested)
2005-10-15 17:29:10 +00:00
drochner 69f432c06d -put gpio stuff inside #if NGPIO > 0
-kill gba_name in attach arg, specify interface attribute
2005-10-11 15:58:37 +00:00
jmcneill b8a32e9d53 Attach to gpiobus. From OpenBSD. 2005-09-27 02:56:27 +00:00
drochner 46ed4b50c4 s/locdesc_t/int/g 2005-08-26 12:42:11 +00:00
drochner ea5766898f oops, too much mechanical renaming -- clearly separate searched and
found locators
2005-08-25 20:52:02 +00:00
drochner fa3cb84d62 replace the "locdesc_t" structure carrying the number of locators
explicitely by a plain integer array
the length in now known to all relevant parties, so this avoids
duplication of information, and we can allocate that thing in
drivers without hacks
2005-08-25 18:35:38 +00:00
joff ad50acb4b6 Add toaster, tsdio, toasterlcd devices 2005-08-14 04:15:44 +00:00
joff d4bc23d662 wsdisplay device driver for the 4x40 text-mode LCD on the NetBSD/toaster 2005-08-14 04:15:18 +00:00
joff bb813453e2 Device driver that exposes the burner element, magnetic latch, and front-panel
LEDs of the TS-7200 NetBSD/toaster via sysctl.
2005-08-14 04:14:35 +00:00
joff 43b39c1131 Simple driver for Technologic Systems TS-DIO24 PC104 board. No
userland interface (yet), basically just can detect a TS-DIO24 on a ISA
bus and provide an attachment for sub-devices.

The TS-DIO24 contains 24 programmable digital input/outputs.
2005-08-14 03:50:34 +00:00
christos 2709ce754e Fix compilation with FD_DEBUG. 2005-07-30 14:49:35 +00:00
drochner 83ebaf0ea5 complete attachment if the temperature monotor was successfully awoken,
minor whitespace fixes
2005-07-29 11:25:13 +00:00
drochner 21275bf194 activate the temperature sensors if the device is in standby mode
on attach (as on Soekris boards), from Aaron Hodgen per PR kern/23598
2005-07-29 11:05:27 +00:00
christos d39684a368 make the isdn drivers compile again with -Wconst, -Wshadow 2005-07-09 02:05:09 +00:00
wiz 4082e99219 Update comment. 2005-06-28 10:16:33 +00:00
kent eabe9bbfa4 remove pss(4) driver. It has never been workable and has not been
compilable for a long time.
2005-06-28 08:36:47 +00:00
christos 2ccc3ff1e9 - add const
- avoid variable shadowing.
2005-05-30 04:32:38 +00:00
christos 57fa3798ac sprinkle const. 2005-05-29 22:12:37 +00:00
christos d675f4acb4 avoid nested variables 2005-05-29 22:12:26 +00:00
lukem 5e4045c6bb add __KERNEL_RCSID 2005-05-24 05:14:37 +00:00
christos 7cdea212c0 No 0x in front of %p... 2005-05-22 15:54:45 +00:00
christos 1a54f2152a PR/22058: Onno van der Linden: duplicate detection of isa ip.
Use some more undocumented bits to find out if the card is in pnp mode or not.
2005-05-12 18:53:08 +00:00
jdolecek fc38d3f3ac Make it possible for attachment to specify that the 16bit access shouldn't
be toggled in WE_MEM_{ENABLE|DISABLE} when receiving or transmitting packets.
Use this to switch the toggle off for MCA cards, since it causes NIC resets
there.

Fixes PR kern/26895 by Dave Barnes.
2005-04-03 10:56:59 +00:00
cube d2d1a8c05c Make pcppi(4) use attimer(4) to set the pitch of the bell.
In case you don't configure an attimer(4) device in your kernel config,
you will simply lose the ability to set the pitch.  It will still beep.
2005-03-25 23:09:00 +00:00
cube 040e3b19e5 Add attimer(4) driver, with ISA and ACPI attachments.
attimer(4) is the new body of the part of pcppi(4) that mapped the TIMER1
register to set the pitch of the bell.  It was necessary to separate them
in order to have a working ACPI attachment (as the two appear as different
devices in the ACPI structures).
2005-03-25 23:06:19 +00:00
xtraeme 3141856faf This needs <machine/bus.h> now. 2005-03-21 18:27:32 +00:00
xtraeme d1c67e4716 This needs <machine/bus.h>, needed for ACPI pcppi(4) attachment. 2005-03-21 17:16:10 +00:00
xtraeme 65f27995a2 Move the struct pcppi_softc into pcppivar.h, add in this file
pcppi_attach(), which now accepts "struct pcppi_softc";
Split ISA specific bits from pcppi_attach() into pcppi_isa_attach()
(needed by the upcoming pcppi(4) ACPI attachment).

Reviewed by christos@.
2005-03-21 14:05:18 +00:00
xtraeme a2dce2fece Use ANSI function declarations. 2005-03-21 10:51:52 +00:00
christos f048688c46 PR/29683: M. B. Buchanan: mcd driver has printf formatting compile issue
and sets the wrong field to the number of ports.
2005-03-12 22:54:48 +00:00
simonb 0467cc278e Add a missing return after an "if" that checks for something then
did nothing.
2005-02-28 05:05:02 +00:00
perry f31bd063e9 nuke trailing whitespace 2005-02-27 00:26:58 +00:00
thorpej df9803ce96 Part 1 of a cleanup pass over the SCSI subsystem. The aim is to name
everything "scsi_*", since we really are talking about the SCSI command
set, ATAPI transport not withstanding.  Improve the names of many structures,
and prepend "SCSI_" onto all SCSI command opcodes.  Place items described
by the SCSI Primary Commands document into scsi_spc.h.
2005-02-21 00:29:06 +00:00
perry 18db93c7f6 de-__P 2005-02-04 02:10:35 +00:00
drochner 12ff682534 Whitespace police. The rest remains crap. 2005-02-01 20:33:58 +00:00
gson 8de9537c69 Update printf format in debug printf to account for sample_rate now
being an unsigned int.
2005-02-01 12:07:58 +00:00
kent c9ec679311 ansify and KNF 2005-01-14 03:41:45 +00:00
kent b85368e36f ansify and KNF 2005-01-13 15:01:27 +00:00
kent d69abf4ca0 - make this compile
- style fixes
2005-01-12 17:43:19 +00:00
kent 23b5d91433 merge kent-audio1 branch, which introduces audio filter pipeline to the MI
audio framework


Summary of changes:

* struct audio_params
  - remove sw_code, factor, factor_denom, hw_sample_rate,
hw_encoding ,hw_precision, and hw_channels.  Conversion information
is conveyed by stream_filter_list_t.
  - change the type of sample_rate: u_long -> u_int
  - add `validbits,' which represents the valid data size in
precision bits.  It is required in order to distinguish 24/32bit
from 24/24bit or 32/32bit.

* audio_hw_if
 - add two parameters to set_params()
	stream_filter_list_t *pfil, stream_filter_list *rfil
   A HW driver should set filter recipes for requested formats
 - constify audio_params parameters of trigger_output() and
trigger_input().  They represent audio formats for the hardware.
 - make open() and close() optional
 - add int (AUMODE_PLAY or AUMODE_RECORD) and audio_params_t parameters
 to round_blocksize()

* sw_code is replaced with stream_filter_t.
  stream_filer_t converts audio data in an input buffer and writes
into another output buffer unlike sw_code, which converts data in
single buffer.
  converters in dev/auconv.c, dev/mulaw.c, dev/aurateconv.c,
dev/tc/bba.c, dev/ic/msm6258.c, and arch/arm/iomd/vidcaudio.c are
reimplemented as stream_filter_t

* MI audio
 - audiosetinfo() builds filter pipelines from stream_filter_list_t
filled by audio_hw_if::set_params()
 - audiosetinfo() returns with EINVAL if mmapped and set_params()
requests filters
 - audio_write(), audio_pint(), and audio_rint() invoke a filter
pipeline.
 - ioctl() for FIONREAD, AUDIO_WSEEK, AUDIO_GETIOFFS,
AUDIO_GETOOFFS, and audio_prinfo::{seek,samples} for
AUDIO_GETINFO handle values for a buffer nearest to userland.

* add `struct device *' parameter to ac97_attach()

* all of audio HW drivers follow audio_hw_if and ac97 changes
2005-01-10 22:01:36 +00:00
tsutsui a9b3f31984 Some cosmetics:
- remove __P()
- use ansi decls
- u_int8_t, u_char -> uint8_t
- use macro for debug printfs
- some KNF
2005-01-09 16:59:41 +00:00
joff 8d1a86c97d add tscs 2005-01-08 02:56:35 +00:00
joff 4b903bb725 Support for TS-ETH10 PC/104 enet isa card based on CS8900 2005-01-08 02:55:52 +00:00