Commit Graph

21270 Commits

Author SHA1 Message Date
bjh21 7da05dea5d There's no need to explicitly deny DMA support, and that causes compile
problems when the kernel doesn't support IDE DMA.
2006-10-01 21:50:33 +00:00
bjh21 bcef78957e Don't explicitly specify no DMA support, since that doesn't work if the kernel
doesn't support IDE DMA at all.
2006-10-01 21:34:30 +00:00
elad 65792a0340 More from Matt Fleming:
Adapt to KAUTH_DEVICE_TTY_PRIVSET and KAUTH_DEVICE_TTY_OPEN.
2006-10-01 20:31:49 +00:00
reinoud c3af0f9a94 In gcc4 structures are differently aligned compared to gcc3. Lots of
structures can thus be misaligned for DMA when declared on stack.

The current atapi code accepts the misaligned dma's only screw's them up.
This small patch disables DMA for the rare transactions that are
misaligned. Note that all bulk-transfers are aligned due to page sizes.

See PR kern/34689
2006-10-01 20:10:31 +00:00
elad bdc51baebb Adapt MD code to KAUTH_DEVICE_TTY_OPEN, batch #2 from Matt Fleming, thanks!
Also, add forgotten splx() calls in some places.
2006-10-01 19:28:43 +00:00
bjh21 a4c2f4b0d0 Add sec(4). 2006-10-01 13:05:05 +00:00
bjh21 5375dc7f10 New driver, sec(4), for the Acorn SCSI Expansion Card. Unlike asc(4), this
driver uses the board's DMA system, uses the machine-independent WD33C93
driver, works on NetBSD/acorn26, and doesn't share a name with six other
machine-dependent SCSI drivers.  Not tested on acorn32, but it seems to
work tolerably well on my A540.
2006-10-01 12:39:35 +00:00
itohy 2a96724f93 Change Id to NetBSD 2006-10-01 12:11:52 +00:00
itohy b2d7fb48f1 Use ATA timing, instead of busmaster wait, for adding waits.
Use default wait value 0x01.
2006-10-01 09:53:08 +00:00
tsutsui def8ea24fa u_int8_t -> uint8_t 2006-10-01 06:02:53 +00:00
jnemeth 51cc6c4041 PR/34654 -- Peter Szilagyi -- add support for Belkin F5D6050 802.11b dongle 2006-10-01 02:06:34 +00:00
itohy f87d591722 A little effort against kernel bloat....
Exclude ATA DMA support if no ATA DMA capable drivers are compiled in.
2006-09-30 15:56:17 +00:00
elad 5ec8c535f2 PR/34648: Nino Dehne: Kernel panic when using NFS root and configuring an
interface that needs firmware

Firmload routines were using FSCRED, which in this case would get to the
NFS code and dereferenced, resulting in a panic. Use the credentials from
the LWP instead.
2006-09-30 12:47:32 +00:00
cube 86f0ff14cc Regen. 2006-09-29 20:49:48 +00:00
cube a556b65796 Add ids of devices found in the nForce 570 chipset.
Add GeForce 6200LE.
2006-09-29 20:48:41 +00:00
tsutsui 7db79c4e79 - KNF
- u_intNN_t -> uintNN_t
- misc cosmetics
2006-09-29 18:56:29 +00:00
tsutsui 60abfbb6b9 ANSIfy. 2006-09-29 18:27:51 +00:00
tsutsui 0afee5cb99 TAB/space cleanup. 2006-09-29 18:20:02 +00:00
tsutsui ab86520375 Set a timeout only if any TX packet is actually queued. 2006-09-29 16:46:49 +00:00
tsutsui 7d6d7a0b22 rtk_intr() should return 1 only if any interrupts are actually handled. 2006-09-29 16:40:15 +00:00
tsutsui 4c0a796caa Use `SIMPLEQ_EMPTY()' rather than `SIMPLEQ_FIRST() == NULL'. 2006-09-29 16:38:16 +00:00
tsutsui a63cbd1696 Handle more wraparound case on RX ring-buffer calculation.
(it might cause problem only if RTK_RXBUFLEN < 64KB)
2006-09-29 16:33:41 +00:00
christos 4589200621 Coverity CID 3801: Plug memory leak (from Arnaud Lacombe) 2006-09-29 14:39:09 +00:00
christos 95d484d975 Coverity CID 4151: Don't forget to close the firmware file (from Arnaud Lacombe) 2006-09-29 14:38:04 +00:00
christos 13528a299f Coverity CID 3666: Remove debug to expose KASSERT's (from Arnaud Lacombe) 2006-09-29 14:33:52 +00:00
christos f6e519df16 Coverity CID 3015: Check before using (from Arnaud Lacombe) 2006-09-29 14:28:46 +00:00
tsutsui ebd0b89ad0 Pull mii_readreg fix from FreeBSD if_rl.c rev 1.81:
> When reading PHY regs over the i2c bus, the turnaround ACK bit
> is read one clock edge too late. This bit is driven low by
> slave (as any other input data bits from slave) when the clock
> is LOW. The current code did read the bit after the clock was
> driven high again.
2006-09-29 14:03:07 +00:00
tsutsui a7f43a90fe In rtk_txeof(), clear the timeout timer only if there is no pending packet. 2006-09-29 13:59:40 +00:00
tsutsui c6bfa68fcc - trim CRC off rather than setting M_HASFCS
- use appropriate types instead of `unsigned'
2006-09-29 08:49:30 +00:00
tsutsui 2f6ae33af4 In rtk_rxeof():
- discard too short packets as well as too large ones
- trim CRC off rather than setting M_HASFCS

Closes PR kern/31348.
2006-09-29 08:33:06 +00:00
joerg b12fa3d640 Regen. 2006-09-28 16:54:16 +00:00
joerg fc4a0108a7 Add IDs for Ralink RT2501USB/RT2601USB. From OpenBSD. 2006-09-28 16:53:40 +00:00
oster ed4d175ee4 Make sure the 'last configured as' field in the component labels
are updated each time the component labels are written.
2006-09-28 02:39:50 +00:00
cube 160fdb0333 Add support for 82562G. 2006-09-27 21:51:48 +00:00
cube 4775d417a1 Regen (Intel 82562G). 2006-09-27 21:50:27 +00:00
cube f9d66765dd Add Intel 82562G PHY. 2006-09-27 21:50:00 +00:00
cube f33f698361 Make fxp(4) support the PRO/100 VE variant just added to pcidevs.
Reported by rix on #NetBSD-code on freenode.
2006-09-27 21:46:15 +00:00
cube 1e05843063 Regen (Intel/0x1094). 2006-09-27 21:43:26 +00:00
cube 3d367d313e Add the Intel PRO/100 variant found on the D946GZIS motherboard. 2006-09-27 21:41:56 +00:00
sketch 83a18a4ac4 Regenerate for TI ACX changes. 2006-09-27 11:49:04 +00:00
sketch 2394aa3588 Add TI ACX100B and rename existing (unused) TI ACX100 to ACX100A. 2006-09-27 11:48:02 +00:00
macallan a2120a92a7 the chip wants all data we send with 64bit padding, no matter what padding
individual scanlines have so we send an extra 0 when we have to.
2006-09-27 06:39:38 +00:00
macallan 214a60e5cb cleanup, implement putchar() using the blitter 2006-09-27 05:19:23 +00:00
bjh21 24bcb8e38a wd33c93_minphys() doesn't exist any more, so don't declare it. 2006-09-26 23:27:36 +00:00
bjh21 334ef0cbc9 Merge my bjh21-wd33c93 branch. This improves message handling in general
and sync negotiation in particular.  Tested on sgimips (thanks to
Manuel Bouyer) and acorn26 (with my still-unfinished driver for the Acorn
SCSI Expansion Card).
2006-09-26 22:45:25 +00:00
kiyohara 58f6bfaae5 Fix device name in {fwohci,firewire}_print(). valiable aux is not string
pointer.
2006-09-26 02:50:42 +00:00
jmcneill 466af2f141 When resuming from S1 standby, don't try to release a mutex that we hadn't
previously acquired.
2006-09-26 01:50:43 +00:00
heas e8bce64b5c Regen for pcidevs 1.833 2006-09-26 00:09:42 +00:00
heas a19ef0d521 Add entries for Datum Inc. (Bancomm) & the BC635PCI_U card. 2006-09-25 23:58:23 +00:00
jmcneill 8f4e570fd3 PR# 32473: GUS PnP audio device seems to be broken in NetBSD 3.0
We now need to call isa_drq_alloc to reserve DMA channel(s) for ISA devices.
Thanks to Ben Collver for testing the patch for me!
2006-09-25 23:26:19 +00:00
jmcneill 1d83a2dea6 No need to call pci_set_powerstate from our powerhook, the bus handles this
for us now.
2006-09-25 23:11:07 +00:00
jmcneill 8e37d48dc1 Create a PCI bus powerhook to handle setting PCI D# power state transitions
on suspend/standby/resume.
2006-09-25 23:09:42 +00:00
jmcneill ce9801710e Only display "interrupt while not running ignored" if DIAGNOSTIC is set, as
whenever this happens, so many messages are spewed to the screen from the
kernel that the system is effectively useless. Hardly ignored :-)
2006-09-25 22:15:15 +00:00
jmcneill fbd43a6ddc Add powerhook for RT2560-based cardbus wireless adapters. 2006-09-25 22:14:01 +00:00
cube f6eef99476 Don't accept a compressed image that has 0 for the block size...
Fixes PR#34608.
2006-09-25 13:47:26 +00:00
peter 223213b93f Improve some debug texts. 2006-09-24 19:07:26 +00:00
briggs d9a3e24d2f Regen with new IDs for devices in the last-generation Apple PowerBook G4. 2006-09-24 18:36:40 +00:00
briggs f1e45a271e Add IDs for the devices in the last-generation PowerBook G4. 2006-09-24 18:35:34 +00:00
peter d04123ca73 Run the "power button event" hooks when the special button OFF is pressed.
Change the keycodes in the keymaps that are currently using the OFF button
to -1 so that they will still operate the same way (i.e. do nothing).

No objection on port-hpcsh & port-hpcmips.
2006-09-24 18:34:41 +00:00
christos 8b0b9e2db5 Regen 2006-09-24 17:18:49 +00:00
christos 385afe8d48 Fix whitespace inconsistencies; no functional change 2006-09-24 17:18:02 +00:00
christos da685f2130 From Claus Andersen:
- change uftdi driver to use usb_lookup
- are more devices (from FreeBSD/OpenBSD)
2006-09-24 17:17:17 +00:00
jmcneill 5396cf7fbb PR# 23620: channels are swapped 2006-09-24 14:26:50 +00:00
jmcneill e396b69764 PR# 29372: notebook with Maestro 2E sound chip panics (w/ fix) 2006-09-24 13:24:32 +00:00
plunky 4eabff54a3 utilise auconv_set_converter() to handle the filter setup, so that its
done properly.
2006-09-24 10:19:55 +00:00
plunky 75521932f7 adjust indentation 2006-09-24 10:16:21 +00:00
xtraeme 9162ad5359 Typo: WCDD_SECURITY_FREEZE -> WDCC_SECURITY_FREEZE
Noticed by Sergey Svishchev.
2006-09-24 08:32:17 +00:00
dogcow a3fae2e5b9 blah blah discard pointer qualifier blah. 2006-09-24 06:03:20 +00:00
jmcneill f135e0d607 Add "name" parameter to powerhook_establish, to aid debugging. No objections
on tech-kern@
2006-09-24 03:53:07 +00:00
jmcneill 4c8d1c711c Don't use // for comments. 2006-09-24 03:42:41 +00:00
jmcneill f6db1b6893 Use /* ... */ for comment instead of // ... 2006-09-24 03:40:49 +00:00
jmcneill 200c3c464e Formatting fixups, remove commented out code that should not have been here,
and remove a few unnecessary XXX comments.
2006-09-24 03:39:51 +00:00
manu e057d5fcd9 Tweak the twa(4) driver so that 3ware command line utility works with it.
This includes:
- fixing various structure definitions so that the ioctl parameter match
- adding a hw.twa*.driver_version sysctl
- do not refuse multiple device openings, as the management tool will do it.
  I'm not sure we are safe. FreeBSD allows multiple openings, and use the
  open flag only when an attempt to detach the device is done.
2006-09-23 22:16:35 +00:00
fvdl 5f5c640d2e In acpi_pci_link_dump, print out polarity and trigger for the link device
properties.
2006-09-23 17:05:33 +00:00
fvdl e1d75075c5 Define the "broken IRQ0 override" quirk, and add it for one type of ACPI
BIOS.
2006-09-23 17:04:26 +00:00
plunky d197e1ae6b guard against possible race conditions when detaching SCO pcb's 2006-09-23 16:11:07 +00:00
plunky 35e1b8aa38 return ENOTCONN when not connected, rather than EINVAL 2006-09-23 16:08:43 +00:00
jmcneill 9c01d5a7bc Regen for PR# 15666. 2006-09-23 15:40:16 +00:00
jmcneill e748bee1f6 PR# 15666: EDIMAX EP-4101 PCMCIA card support (patch included) 2006-09-23 15:39:51 +00:00
jmcneill 696fb7f495 Regen for PR# 27840. 2006-09-23 13:21:29 +00:00
jmcneill ee203eb22f PR# 27840: patch for IO DATA PCET/TX-R PCMCIA Ethernet card support 2006-09-23 13:21:01 +00:00
jmcneill 65876ef5bc PR# 31437: Philips Toucam Pro II is yet another 'audio' USB camera 2006-09-23 13:07:06 +00:00
elad 5425e24592 Use u_quad_t and not uint64_t (even though they might be the same),
pointed out by tsutsui@.
2006-09-23 07:54:17 +00:00
macallan 52819a126f a half done wsdisplay driver for Chips & Technologies 65550 graphics chips
So far it only uses the blitter for scrolling and rectangle filling,
characters are still drawn in software and there's no support for video
mode switching. Virtual consoles are supported via vcons.
Works fine on a PowerBook 3400c.
2006-09-23 05:12:22 +00:00
jmcneill 5b8b677431 PR# 29516: magma.c comments are wrong, also splhigh is excessive 2006-09-23 04:45:49 +00:00
jmcneill eaa9b0d13e Print "interrupt at irq <foo>" message immediately after we establish the
interrupt. Patch from PR# 33567.
2006-09-23 01:19:18 +00:00
jmcneill 96568ac6d5 Adjust comment for rnd_add_uint32() to reflect changes in rev 1.50. Fixes
PR# 34250 by Jorge Acereda Macia.
2006-09-23 01:13:08 +00:00
jmcneill 7e857903f0 Regen for PR# 23133. 2006-09-23 00:56:42 +00:00
jmcneill 1483b0e7d4 Attach ess(4) for ESS1879 devices; 2+ years late fix for PR# 23133 2006-09-23 00:56:20 +00:00
elad af7d9594a4 PR/34589: Cliff Wright: vnd(4) compress error with large files
Applied slightly different patch (u_int64_t -> uint64_t), thanks!
2006-09-23 00:53:46 +00:00
elad 9033a1369b In struct vcons_data, don't depend on DIAGNOSTIC and always include
switch_poll_count.

okay chs@
2006-09-22 15:16:03 +00:00
christos f807e82573 regen 2006-09-22 12:44:23 +00:00
christos 33bd80c320 From: Jaime A Fournier: Patch to support SMC 2262WV1 2006-09-22 12:43:52 +00:00
thorpej 1edb40635e - Define disk information, disk geometry, and disk partition dictionary
schemas.  Disk information and disk geometry are designed to replace
  information currently conveyed to user space using struct disklabel.
- Add a dk_info member to struct disk; a reference to a disk information
  dictionary.  This dictionary is to be allocated and the reference stored
  in struct disk by individual drivers.
- disk_detach0() will release dk_info if non-NULL.
- Convert the wd(4) driver to stash geometry and other disk properties
  as the "disk-info" property in its properties dictionary.  This needs
  some cleanup, but will serve as an example of what to do with other
  disk drivers.
2006-09-22 04:48:38 +00:00
thorpej 6cf1ffe998 Alter the protocol impemented by prop_kern to allow for bi-directional
plist-based messages and to eliminate looping previously required to
receive a plist from the kernel:

- prop_dictionary_copyin_ioctl() and prop_dictionary_copyout_ioctl()
  now take the cmd argument rather than the file open flag.  The
  read-ness or write-ness of an ioctl command is checked by these
  routines to ensure that information is being passed to/from the
  userland component properly.

- prop_dictionary_copyout_ioctl() now allocates the memory for the
  XML plist on behalf of the userland component by way of uvm_mmap().
  The XML plist is copied out to the newly-mapped anonymous region,
  and the pointer returned via the plistref.

- prop_dictionary_recv_ioctl() is responsible for munmap()'ing the
  region after parsing the XML plist into internal represenatation.

- A new prop_dictionary_sendrecv_ioctl() is added, allowing user space
  code to send a dictionary to the kernel and receive one back as a
  reply.


Update users of prop_kern for the API changes (Bluetooth).

This constitutes an ABI / protocol change -- but this will also be put
into NetBSD 4.0 so that the first proplib release will implement the new
scheme.
2006-09-22 04:20:23 +00:00
cube 295a511be4 Constification. 2006-09-20 05:21:37 +00:00
plunky 4b7ccf17f9 explicitly disallow changing the config # when the device is enabled. 2006-09-19 20:34:33 +00:00
plunky 661865e783 return errno instead of usbd status 2006-09-19 19:45:48 +00:00
he fc13afb3a4 Convert the NetBSD/cats port to use generic TODR.
This gets rid of the now-unneded "todclock" and "todservice" attributes
from the footbridge device files, which should allow netwinder to build
again after its conversion to generic TODR.

Resulting kernel verified to boot up OK on gxemul (after my recent
fixes of the gxemul package to emulate free-running timers).
2006-09-19 10:05:32 +00:00
reinoud 3b1c762eae Since SPDIF support fo the auixp driver is still half done disable it for
now since some chipset revisions will freak out on the aparent
half-initialisation. Even on my machine i can't seem to get the SPDIF led
to light up so something is wrong.

Also delay the setting of the DMA bits until after the codec detection but
before the enabling of interrupts. Note that the dma has to be explicitly
started when the device is opened.
2006-09-18 15:18:52 +00:00
uebayasi 3f9b6523d1 Typo in comment. 2006-09-18 07:47:13 +00:00
jmcneill 2c50610456 Call rt2560_stop() from rt2560_detach(). Fixes a panic on detach of cardbus
device on my Vaio. Fix from dyoung@.
2006-09-17 23:58:51 +00:00
plunky f811cc93d1 add bthub(4) and remove btdev(4) entries 2006-09-17 15:01:34 +00:00
gdamore 06522e0f81 Pass the filesystem time to clock drivers in the todr_chip_handle, so that
vax, and pmax can use it.
2006-09-16 00:50:52 +00:00
is 1860a0e148 Simply use the device name for the workqueue name. 2006-09-15 11:22:21 +00:00
is a2f7b2e007 aue_ioctl() for the murpose of adding/deleting multicast addresses is called
from interupt context. Defer its processing to a workqueue(9).
This fixes PR 34521.
2006-09-15 10:47:34 +00:00
reinoud d1de30eaae Fix same panic problem as with cd.c when a scsi error happends on
read/write action. It would panic on a diagnosic assertion. When a scsi
read/write command fails, the whole extent is gone bad so mark all as not
done.
2006-09-14 17:54:34 +00:00
martin 2dce1200cc Avoid duplicate collon, from Stephan 'doomwarrior' in PR kern/34518 2006-09-13 14:45:24 +00:00
gdamore cf407be292 Convert shark and ofppc to new common ofrtc and MI todr code. Tested
on shark.  Ok christos@, martin@.
2006-09-13 07:14:35 +00:00
christos d5978e20f4 - use c99 initializers
- add missing initializer
2006-09-13 01:01:20 +00:00
christos b4c0be5dc8 avoid empty if bodies. 2006-09-13 00:55:57 +00:00
christos 71aa807296 use a c99 initializer 2006-09-13 00:48:03 +00:00
plunky ad28493ad1 guard against a possible situation where the list of l2cap channels is changed
when the bluetooth code is not expecting it to be. During a disconnect, we can
detach the channel that is being disconnected, but its not really safe to detach
any others.
2006-09-12 18:18:01 +00:00
plunky 4b5125cac5 btsco.c:
- sco_getopt(..., SO_SCO_MTU, ...) expects the address of a uint16_t,
   not an int. So change sc_mtu's type to uint16_t.
 - Try a little harder to ensure btsco_round_blocksize() does not
   return zero. Prevents a subsequent panic in audio_init_ringbuffer().

	from scw@
2006-09-11 21:59:09 +00:00
rittera 26b97f3a17 Added innitialization to bs in ndis_getstate_80211. It was causing a compiler warning. Pointed out by Kulcsar Ferenc 2006-09-11 21:17:18 +00:00
reinoud 2b551264c1 Aparently i've misread, backing out change. 2006-09-11 19:43:55 +00:00
plunky ed4d8d47a0 also include service name in dictionary being sent to kernel.
(this is not used just yet, but it might be in the future and it will
be easier if we dont have to provide code to handle its absence)
2006-09-11 18:30:27 +00:00
reinoud 5411355304 Don't add one to the capacity returned of READ CAPACITY! it results in
reporting a sd* disc that is one sector too big (!) Normally not much a
problem in FFS since its clustered but other filingsystems *do* care.
2006-09-11 17:57:07 +00:00
matt b9525730ee deal with 'bool' definitions 2006-09-11 03:37:12 +00:00
riz c927ff3953 g/c unused SK_{SET,CLR}BIT macros 2006-09-10 18:39:27 +00:00
plunky 4f1cbddc12 update to bluetooth device attachment:
remove pseudo-device btdev(4) and inherent limitations

add bthub(4) which autoconfigures at bluetooth controllers as they
are enabled. bluetooth devices now attach here.

btdevctl(8) and its cache is updated to handle new semantics

etc/rc.d/btdevctl is updated to configure devices from a list
in /etc/bluetooth/btdevctl.conf
2006-09-10 15:45:55 +00:00
gavan 843ed515f0 dsrtc_settime already takes a volatile struct timeval *, also qualify
with volatile for dsrtc_gettime.
2006-09-10 14:06:54 +00:00
simonb f4ec8156e1 Add NetBSD RCS tag to top of file. 2006-09-10 11:03:14 +00:00
tsutsui c231727267 Fix a typo (settime -> gettime) so that we can get time. 2006-09-10 06:39:00 +00:00
riz 11d88bbe54 Add msk(4) info to the sk(4) manpage, and install links (from OpenBSD).
Also, add msk to DEVNAMES.
2006-09-09 23:52:27 +00:00
gdamore 7020797810 Convert to MI clock_ymdhms versions of todr calls. 2006-09-09 21:10:01 +00:00
riz d5e3d70afd Add msk(4), a driver for Marvell Yukon 2 gigabit ethernet chips,
from Mark Kettenis of OpenBSD.  There are still some outstanding
issues with this driver, namely:

 - Checksum offload is unsupported
 - There is a significant amount of code duplication from sk(4)
 - There remain some 'magic numbers'
 - Performance is not heavily tested, and likely to be lower than
   the chip is capable of in some cases.  Syncing some of the
   aforementioned 'magic numbers' with the Marvell FreeBSD driver
   should help here.

Tested on a motherboard with Marvell 88E8053 ethernet, under NetBSD/i386
and NetBSD/amd64.
2006-09-09 16:17:50 +00:00
uebayasi c1a02ec4d9 Typo. 2006-09-08 06:38:55 +00:00
reinoud 25522cfb86 Oeps! I overlooked the size argument of the SCSI call. It ought to be equal
to the number of bytes we are reading: READ_DISCINFO_BIGSIZE

sorry.
2006-09-08 00:33:18 +00:00
reinoud a5b62cb444 The size of struct scsipi_read_discinfo_data is not even due to the data[1]
pseudo array in the structure. The scsi command issued used
sizeof(scsipi_read_discinfo_data) but included thus the last byte that
wasn't going to be inspected anyway. Using the constant
READ_DISCINFO_BIGSIZE fixes the bug.

Even though SCSI adapters *should* accept odd lengths, the Sun U10
(sparc64's) crashes in bus_space_read_multi_stream_2(). That explains the
crash.

NOTE: somewhere in NetBSD/sparc64's atapibus support there is the
assumption on the even size; this needs to be fixed! (Hi Sparc64 portmaster
:-) )
2006-09-07 22:52:46 +00:00
riz bc22f236a4 Regen. 2006-09-07 21:17:32 +00:00
riz 0fcac2612f Add the SK-9Sxx Gigabit Ethernet, from OpenBSD. 2006-09-07 21:16:55 +00:00
itohy cb2fb285ec Workbit NinjaATA-32 busmastering PIO IDE controller driver (njata)
This driver supports NinjaATA-32Bi and NPATA-32 chips,
which are used for CardBus ATA interface cards and
CardBus CompactFlash adapters.
2006-09-07 14:22:07 +00:00
itohy 6119b65726 Add PIOBM (busmastering transfer using ATA PIO mode) support.
The PIOBM is used by only one driver (will be added later,
stay tuned) and intruduce an attribute "ata_piobm" so that
it will be conditionally compiled in.
The "ata_dma" (busmastering transfer using ATA DMA mode) and
"ata_udma" (busmastering transfer using ATA Ultra DMA mode)
attributes are also added for consistency, but unused for now.
2006-09-07 12:46:47 +00:00
itohy bf52851800 Regen from pcidevs rev 1.830. 2006-09-07 12:38:59 +00:00
itohy eee2a035e9 Add Workbit NinjaATA-32Bi and NPATA-32 busmastering PIO IDE controllers. 2006-09-07 12:37:49 +00:00
itohy 0a30900857 Add PIOBM (busmastering transfer using ATA PIO mode) support.
The PIOBM is used by only one driver (will be added later,
stay tuned) and intruduce an attribute "ata_piobm" so that
it will be conditionally compiled in.
The "ata_dma" (busmastering transfer using ATA DMA mode) and
"ata_udma" (busmastering transfer using ATA Ultra DMA mode)
attributes are also added for consistency, but unused for now.
2006-09-07 12:34:41 +00:00
gdamore 1a001de39f Update to new friendlier todr entry points. While here, ANSIfy. 2006-09-07 05:09:29 +00:00
gdamore a3925b6374 Updated to new clock_ymdhms support in kern_todr.
While here, ansify a few routines.
2006-09-07 05:02:16 +00:00
simonb 68c7194a9c Revert rev 1.9. As pointed out by Izumi Tsutsui, the \n is printed
by MD code.
2006-09-07 04:33:55 +00:00
gdamore 711d816d2d Switch to friendlier todr ymdhms entry points. Moved a consistency check
to common kern_todr.c while here.
2006-09-07 04:29:34 +00:00
dogcow f2d329dca0 remove more vestiges of CCITT, LLC, HDLC, NS, and NSIP. 2006-09-07 02:40:31 +00:00
uwe d9aa7ac028 Make timeval argument to todr_settime volatile to keep non-timecounter
ports happy.
2006-09-07 01:50:49 +00:00
uwe c7a7101b20 MI part of the Ricoh RS5C313 real time clock todr(9) driver.
Based on the code from landisk port.  With help from gdamore@
2006-09-07 01:12:00 +00:00
ad 5c5838e690 - Add a couple of XXX comments.
- lb->lb_cpu doesn't need to be filled in lockstat_event().
2006-09-07 01:03:02 +00:00
ad beafae096b Add the 'lockstat' driver, which collects basic information about lock events. 2006-09-07 00:20:28 +00:00
gdamore 942bfe3e30 Add support for new todr entry points for drivers- todr_gettime_ymdhms and
todr_settime_ymdhms.  This allows drivers to avoid repeated conversions, and
allows us to centralize check for Y2038 overflow.   As discussed on
tech-kern.
2006-09-07 00:10:49 +00:00
rumble cfba0d26d0 Avoid a panic on adapter check interrupts: the 'tl_restart' callout expects
a pointer to struct ifnet, not tl_softc.
2006-09-07 00:00:02 +00:00
simonb e099b5edda Add \n to end of autoconf message. 2006-09-06 06:26:54 +00:00
gdamore 50d22dfb8e Convert time.tv_sec to time_second. 2006-09-05 21:59:51 +00:00
plunky ac9c65b377 Halt the callout on detach 2006-09-05 18:14:57 +00:00
rumble d5dbfe8cbd Make this work with timecounters. 2006-09-05 17:31:31 +00:00
elad 95ed982c27 Fix two horrible bugs found during a routine audit session with Brett Lymn.
First one was incorrectly loading entries -- we were treating each file as
a mount, which resulted in huge mess. I have no excuse for how I didn't
catch this earlier.

Second, use the table name we create for the Veriexec sysctl node and not
the fixed "table0".

Both are fileassoc(9) integration fallout.
2006-09-05 13:02:16 +00:00
oster f23a530674 Per a suggestion from Manuel, make numBlocks and partitionSize
unsigned for now.  This prevents rf_reasonable_label() from rejecting
a valid label when these fields have an integer overflow.  The reality
is that these need to be 64-bit quantities, but that will come later.
2006-09-05 01:55:21 +00:00
gdamore a37acb1b52 Remove unused todr_setcal/todr_getcal and all the assorted stub
implementations.
2006-09-04 23:45:30 +00:00
dan 1860a17382 typo in debug printf 2006-09-04 22:51:42 +00:00
martin 16f200486d Add support for IO-DATA's USB-Serial adapter (USB-RSAQ3),
from Keiichi SHIMA.
2006-09-04 15:39:39 +00:00
riz 2f9f5c5846 Remove unused members of sk_softc. 2006-09-04 00:54:40 +00:00
christos 93a520d8b0 fix initializers 2006-09-03 22:17:35 +00:00
christos e82a0f88ae add missing initializer. 2006-09-03 21:45:28 +00:00
christos 77c903b90a add missing initializer 2006-09-03 21:42:55 +00:00
christos 00c11ed953 add missing initializers 2006-09-03 21:42:09 +00:00
christos c5b9d17001 add missing initializer 2006-09-03 21:38:23 +00:00
christos ad4f70a8e8 add missing initializer. 2006-09-03 21:30:24 +00:00
christos 2dfeed7693 fix initializers. 2006-09-03 21:28:03 +00:00
christos b231088be0 add missing initializer 2006-09-03 21:16:09 +00:00
christos 3088ae53a7 - add missing initializer
- remove stray semicolon that prevented an ioctl from working.
2006-09-03 21:09:46 +00:00
christos 40be650c67 add missing initializers. 2006-09-03 21:05:01 +00:00
christos 224c7c746b add missing initializer. 2006-09-03 21:03:11 +00:00
christos c35f9741bc add missing initializer. 2006-09-03 21:00:01 +00:00
christos 4e0d743b9e add missing initializers 2006-09-03 20:59:18 +00:00
bouyer 2aee9a0f50 Back out rev 1.149.
From various discussion about vndstrategy (see
http://mail-index.netbsd.org/tech-kern/2005/03/29/0034.html
http://mail-index.netbsd.org/tech-kern/2005/03/23/0015.html)
it's not correct to tsleep() in a strategy routine, which may be called from
interrupt context.
Unfortunably this reopens PR/10731, PR/12189, PR/20296, PR/34293

As for what the correct fix it, this needs to be analysed deeper. I suspect
throttling the caller in vnd only hides the problem; the same caller writing
to some other device could exaust all buffers as well. If this driver doesn't
need to allocate buffer this won't cause a deadlock, but it's bad for
performances on systems with e.g. multiple drives. Also, others stacked
block device drivers may also have this issue.
2006-09-03 19:49:34 +00:00
bouyer bedc649eed stop attaching when a bus_dma operation fails, instead of using bogus
addresses.
Remplace vtophys() with proper bus_dma(9) use.
This driver now works properly on Xen
2006-09-03 19:06:32 +00:00
martin 452f35b603 Regen 2006-09-03 18:30:54 +00:00
xtraeme 44522b1f90 * Add support for ICH8 and ICH8M SATA/RAID controllers.
* If the controller is in AHCI, ask for SATA IDE mode of operation.

jsg@openbsd says:

"X60/T60 Thinkpads are shipped in AHCI configuration by default,
 this makes them work without changing a BIOS option."

Tested by eye of the beholder. From OpenBSD.

Ok'ed tls.
2006-09-03 18:30:35 +00:00
martin 1b5905d05b Add RASQ3 variant of PL2303 serial 2006-09-03 18:30:23 +00:00
bjh21 dacb75acff All ports that use the file do so through files.pckbport, so there's no
need to be cautious about including "pckbd.h".  This has the side-effect
that ports using pckbd but not defining __HAVE_NWSCONS will now get pckbd
attached as console if they call pckbport_cnattach(), but I don't think
any such ports exist.
2006-09-03 13:23:15 +00:00
xtraeme 02fa0947d7 Add support for PDC40519 and PDC40779... from obsd. 2006-09-03 12:18:03 +00:00
xtraeme 4769f26cd2 regen 2006-09-03 12:14:32 +00:00
xtraeme 3a3373ee8e Add missing PDC20265 device... removed accidentally in previous. 2006-09-03 12:13:56 +00:00
xtraeme 5a91328568 regen 2006-09-03 12:02:53 +00:00
xtraeme 4e23c01c3f Add some missing devices from Promise and sort them. 2006-09-03 12:02:30 +00:00
xtraeme f42bb991ca regen 2006-09-03 10:20:13 +00:00
xtraeme af16e7909e Add some ICH8 devices... from obsd. 2006-09-03 10:19:26 +00:00
xtraeme fdcb59bf6d Add support for nvidia MCP61/65 IDE/SATA Controllers. 2006-09-03 08:42:32 +00:00
xtraeme bbdb91feca regen 2006-09-03 08:39:15 +00:00
xtraeme 316d722a4c Erm forgot to add MCP61/65 SATA Controllers and sort them. 2006-09-03 08:38:52 +00:00
xtraeme 7465ee1052 regen 2006-09-03 08:10:47 +00:00
xtraeme 4b06824243 - Add all pciids for nvidia MCP61/65 controllers, from obsd.
- Improve description in all them.
2006-09-03 08:10:18 +00:00
xtraeme ea4f30c7b7 Add support for MCP61/65 controllers... from obsd. 2006-09-03 07:42:04 +00:00
xtraeme 3a6aed3622 regen 2006-09-03 07:36:34 +00:00
xtraeme e85b72eeee - Add nForce MCP61/65 LAN controllers... from obsd.
- Improve description in some nForce controllers as well.
2006-09-03 07:36:10 +00:00
christos 92a6344549 add missing initializer 2006-09-03 07:14:47 +00:00
christos 08a78fe175 use c99 initializers 2006-09-03 07:13:46 +00:00
christos 6e6fde1336 add missing initializer 2006-09-03 07:07:20 +00:00
christos db87199efc use c99 initializers 2006-09-03 07:06:39 +00:00
christos 80d7cf4588 - add missing initializer
- add missing function decl
2006-09-03 07:05:16 +00:00
christos bbf2deb35f - add missing initializer
- inline comes first
2006-09-03 07:02:54 +00:00
christos 0c58aff5f5 add missing initializers 2006-09-03 06:46:22 +00:00
christos 328ed75351 add missing decl 2006-09-03 06:42:44 +00:00
christos 05bd5641dd add missing initializers 2006-09-03 06:41:38 +00:00
christos 48c3e87853 add missing initializer 2006-09-03 06:26:27 +00:00
christos 01edefa570 comment out unreachable code 2006-09-03 06:23:27 +00:00
christos 996634386c comment out unreachable code. 2006-09-03 06:22:05 +00:00
christos 4905e82e29 add missing initializer 2006-09-03 05:30:48 +00:00
christos c11c8c78df add missing initializers 2006-09-03 05:29:46 +00:00
christos b3d983dd18 add missing initializer 2006-09-03 05:24:47 +00:00
christos 5b7c1e90d5 add missing decl. 2006-09-03 05:23:59 +00:00
christos 4ac9cd5ebe add missing initializer 2006-09-03 05:20:21 +00:00
christos 7ed28205b6 - add missing initializer
- comment out impossible comparison
2006-09-03 05:19:38 +00:00
christos 144543fb61 add missing initializer 2006-09-03 05:18:03 +00:00
christos 60dfc6ed9c add missing initializers 2006-09-03 05:16:01 +00:00
christos eb7cb3e07d - add missing initializers
- remove impossible comparison
2006-09-03 05:12:54 +00:00
christos 624d950194 add missing initializer 2006-09-03 05:11:30 +00:00
christos 26733bed2e - comment out impossible comparisons
- remove superfluous if statement
2006-09-03 05:10:24 +00:00
christos 7de21598de - add missing initializer
- correct function decl.
2006-09-03 05:04:57 +00:00
christos 93582079db add missing initializer 2006-09-03 05:02:21 +00:00
christos 309d51fb22 add missing initializers 2006-09-03 04:56:33 +00:00
christos 2ef37e3f61 use c99 initializers 2006-09-03 04:52:14 +00:00
christos a96f0dc641 avoid empty if statements 2006-09-03 04:27:11 +00:00
christos 3cd45450e8 redo with c99 initializers 2006-09-02 18:59:46 +00:00
christos bd4bd1bf9d - comment out impossible comparison
- add missing initializer
2006-09-02 18:58:02 +00:00
christos 5ec7f32544 add missing initializers 2006-09-02 17:02:57 +00:00
xtraeme 05670fe773 Remove unused variable to make this build again. 2006-09-02 09:26:47 +00:00
christos b6994507c5 add missing initializer 2006-09-02 07:23:53 +00:00
christos faec8658c7 - fix incomplete initializer
- static goes first
2006-09-02 07:10:51 +00:00
christos 0668b0a2e0 static goes first 2006-09-02 07:08:39 +00:00
christos 7d1781d944 - fix incomplete initializer
- static goes first
2006-09-02 07:07:33 +00:00
christos b5da945622 comment out unreachable code 2006-09-02 07:06:03 +00:00
christos a91b63349c add missing initializer 2006-09-02 07:04:46 +00:00
christos a569a4d291 add missing initializer 2006-09-02 07:01:20 +00:00
christos 9f681d6f65 comment out impossible code 2006-09-02 07:00:23 +00:00
christos 489fe1e988 add missing initializers 2006-09-02 06:56:30 +00:00
christos b819e0b190 Add missing initializer 2006-09-02 06:54:18 +00:00
uwe ff25c8d7b7 s/dreamcast/sh3/ to cover landisk. 2006-09-01 20:28:14 +00:00
matt 49b2425f19 Use an unsigned int for the blksize on read_cd_capacity. 2006-09-01 03:29:32 +00:00
dyoung 013444d78c Remove the declaration of an unused local variable 'reg'. 2006-09-01 03:24:58 +00:00
reinoud 0b228f5987 Fix panic on reading/writing to a (raw) CD device and encountering an
error. It now correctly sets bp->b_resid to the full size of the buffer.
The failed SCSI read/write command allways contains the complete buffer.

When encountering a read (or write) error, the scsipi stack sets the
xs->resid to zero since the command has been accepted by the drive. The
scsi command set does not allow a partial read or write to be performed and
will signal a success or an error.
2006-08-31 21:32:42 +00:00
reinoud e3b1c755c2 Remove two spurious empty lines in functions 2006-08-31 20:22:34 +00:00
reinoud 055cdf5d13 Fix fencing bug on CD disk size; the comment was wrong, its the *length* of
the device and since we count from zero its equal to the number of sectors
and thus one higher than the last sector.

This fixes the read/write problems on the (raw) device where the last
sector was not readable/writable.
2006-08-31 19:46:54 +00:00
dyoung 8cd106d3d2 Per discussion on tech-kern and tech-userlevel, move the bit-twiddling
macros, __BIT, __BITS, SHIFTIN, SHIFTOUT, and __arraycount() from
lib/libkern/libkern.h to sys/cdefs.h.  Add a __-prefix to SHIFTIN
and SHIFTOUT, and add a manual page for the bit-twiddling macros,
bits(3).

Make the __BIT and __BITS macros "widthless," as best I can, by
changing their type to uintmax_t from uint32_t.  XXX The manual
page lags this change by a bit.

Define __PRIxBIT and __PRIxBITS printf(3) format strings.
2006-08-31 19:24:37 +00:00
matt 3d36667ef9 Appease GCC4 by making /* NOTREACHED */ code return 0. 2006-08-31 18:31:59 +00:00
rumble cc8a477ce5 Add quirks for the Phobos GIO Fast Ethernet boards. 2006-08-30 23:32:07 +00:00
rumble e980865174 Phobos boards (my G130 at least) have a non-standard srom layout. Try to
identify it and pull out the enaddr.
2006-08-30 23:31:08 +00:00
rumble 75e28cc7ed Make this compile again when TLDEBUG is defined. 2006-08-30 23:29:01 +00:00
plunky 999bb1e465 It seems that EHCI at least will complete a empty transfer with
status == NORMAL_COMPLETION.

Guard against that.
2006-08-30 19:42:37 +00:00
christos 738af19b41 fix initializers. 2006-08-30 19:25:46 +00:00
christos a2b752877c fix incomplete initializer. 2006-08-30 19:16:03 +00:00
christos e6aa223b06 - fix initializers
- comment out dead code.
2006-08-30 17:07:33 +00:00
christos 514b3fccd7 fix initializer 2006-08-30 17:00:15 +00:00