Commit Graph

570 Commits

Author SHA1 Message Date
reinoud
f6a70673ba Mark a buffer busy in getnewbuf() when it came from the pool_cache since
its not on a free list.

Also change buf_init() to not automatically mark buffers `busy' since this
only makes sense for bufcache buffers.

Mark all buf_init'd buffers 'busy' on the places where they ought to be
flagged as such to not confuse the buffer cache.

Fixes PR 38923.
2008-06-17 14:53:10 +00:00
cegger
17dbee905c use device_lookup_private to get softc 2008-06-12 21:46:21 +00:00
drochner
1f0a423884 use new "defpseudodev" where appropriate, and remove dummy interface
attribute definitions which were only to trick config(8)
2008-06-10 12:49:16 +00:00
tsutsui
9499107496 Use device_lookup_private() rathter than device_private(device_lookup()). 2008-06-08 18:34:06 +00:00
yamt
bb127cf870 ata_raid_config_block_rw: getiobuf(vp, NULL) -> getiobuf(vp, false) 2008-05-06 11:07:24 +00:00
xtraeme
efa94e2017 device_t/softc split. 2008-05-04 13:59:41 +00:00
plunky
fc53820785 disk_destroy() is needed when the disk structure is no longer required,
this fixes PR kern/38131
2008-05-02 21:11:00 +00:00
martin
ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00
cegger
8bac8763ae use aprint_*_dev and device_xname 2008-04-05 22:04:36 +00:00
matt
51a43e5da8 split softc/device_t. use device_t & cfdata_t 2008-03-26 18:09:17 +00:00
ad
a9ca7a3734 Catch up with descriptor handling changes. See kern_descrip.c revision
1.173 for details.
2008-03-21 21:54:58 +00:00
cube
384b03ce27 Don't assume wd_softc embeds a struct device. 2008-03-19 23:43:41 +00:00
cube
7aa6248cdf Split device_t and softc for ATA devices, as well as wd(4). Other
cosmetic changes where appropriate.
2008-03-18 20:46:35 +00:00
bouyer
bd65ddcdb1 The Hitachi HDP725025GLA380 returns "aborted command" instead of
"id not found" when hitting the LBA48 bug, so also install the
LBA48 bug workaround on "aborted command" errors.
2008-02-29 21:51:38 +00:00
dyoung
f612df5fb6 Use PMF_FN_ARGS, PMF_FN_PROTO. 2008-02-29 06:38:28 +00:00
drochner
c0adcb9cf8 use pmf again to register the shutdown handler, instead of
shutdownhook_establish()
2008-02-28 14:40:17 +00:00
dogcow
653e53c49d As pointed out by Geoff Wing, 1.356 of wd.c needs sc_sdhook restored. 2008-02-22 06:46:46 +00:00
drochner
e4b37a874e put back the old shutdown handlers to flush the disk cache,
the pmf API can't deal with all the different suspend/resume/reboot
cases well yet, so better keep suspend/resume and reboot/halt/poweroff
clearly seperated
2008-02-21 21:52:06 +00:00
xtraeme
b2498de159 Move a debug printf into the ATA_RAID_DEBUG block. 2008-02-07 13:48:33 +00:00
mjf
b1c9a380e4 Match up some VOP_OPEN()S with VOP_CLOSE()s. This allows the root
file system to be identified properly again.
2008-02-02 16:15:01 +00:00
dyoung
92e5e1c722 Oops, remove some debug statements that slipped in there. 2008-01-10 07:48:22 +00:00
dyoung
1415c1d7aa Use device_t, device_xname(), device_private(). Add atabus_childdetached()
to clean up pointers to detached children.
2008-01-10 07:41:20 +00:00
ad
0664a0459b Start detangling lock.h from intr.h. This is likely to cause short term
breakage, but the mess of dependencies has been regularly breaking the
build recently anyhow.
2008-01-04 21:17:40 +00:00
ad
95ffd8cee1 Another driver that should use getiobuf(). 2008-01-02 21:59:45 +00:00
ad
4a780c9ae2 Merge vmlocking2 to head. 2008-01-02 11:48:20 +00:00
perry
b6a2ef7569 Convert many of the uses of __attribute__ to equivalent
__packed, __unused and __dead macros from cdefs.h
2007-12-25 18:33:32 +00:00
pooka
ce8249d73f Don't allocate DEV_BSIZE from the stack, use kmem instead. 2007-12-20 20:12:01 +00:00
joerg
0adaef6553 Restore suspend handler. Put the disc into standby on suspend and for
powerdown, but not for normal halt or reboot or panic. Fixes PR 37508.
2007-12-18 15:30:40 +00:00
lukem
38398f2570 use __KERNEL_RCSID() 2007-12-11 11:38:15 +00:00
jmcneill
f2fa8d82cf Make this compile again. 2007-12-11 02:02:31 +00:00
jmcneill
eded1e0324 Disable the wd_suspend power handler on the proper branch, workaround for
kern/37508
2007-12-11 01:52:18 +00:00
jmcneill
4c1d81b2b5 Merge jmcneill-pm branch. 2007-12-09 20:27:42 +00:00
pooka
61e8303e9d Remove the "struct lwp *" argument from all VFS and VOP interfaces.
The general trend is to remove it from all kernel interfaces and
this is a start.  In case the calling lwp is desired, curlwp should
be used.

quick consensus on tech-kern
2007-11-26 19:01:26 +00:00
christos
eb90df6853 From Marco Trillo (marcotrillo at gmail dot com):
Add Advanced power management in atactl(8)
2007-11-18 17:48:21 +00:00
itohy
cf3882284c more KNF changes 2007-11-07 08:59:03 +00:00
itohy
18f935c281 KNF or make it compile by gcc 2 2007-11-07 08:56:41 +00:00
jnemeth
a04503ddd4 PR/37251 - Brian Buhrow -- FORCE_LBA48 on seagate drives larger then 1TB 2007-10-31 09:51:20 +00:00
ad
a2a3828545 machine/{bus,cpu,intr}.h -> sys/{bus,cpu,intr}.h 2007-10-19 11:59:34 +00:00
ad
2af68666da Merge disk init changes from the vmlocking branch. These seperate init /
destroy of 'struct disk' from attach / detach.
2007-10-08 16:41:05 +00:00
bouyer
cf9d41447f Add a workaround for drives with the LBA48 bug:
if we get a "ID not found" error for a transfer crossing LBA48_THRESHOLD,
and the drive is larger than 128GB, automatically add WD_QUIRK_FORCE_LBA48
to the drive's quirks and retry the transfers.
Hopefully this will obsolete the WD_QUIRK_FORCE_LBA48 quirk list ...
2007-09-16 18:41:47 +00:00
jnemeth
2c21568896 yet more caddr_t fallout 2007-09-05 05:36:19 +00:00
bouyer
bd627359dd Improved SATA support, from Jonathan A. Kollasch in PR bin/36772:
* use full 5-bit command queue depth that SATA supports
* decode SATA bits
2007-08-21 16:53:18 +00:00
taca
324019adc6 Make it compile with WD_SOFTBADSECT option. 2007-07-30 06:59:13 +00:00
ad
eb171eaaa7 It's not a good idea for device drivers to modify b_flags, as they don't
need to understand the locking around that field. Instead of setting
B_ERROR, set b_error instead. b_error is 'owned' by whoever completes
the I/O request.
2007-07-29 12:50:17 +00:00
ad
b5a9ff06f1 Replace some uses of lockmgr(). 2007-07-21 19:51:47 +00:00
ad
88ab7da936 Merge some of the less invasive changes from the vmlocking branch:
- kthread, callout, devsw API changes
- select()/poll() improvements
- miscellaneous MT safety improvements
2007-07-09 20:51:58 +00:00
dsl
80f6eff58d Allow callers of the ATAIOCCOMMAND ioctl to request the WDCC_IDENTIFY to
specify a buffer that is less than 512 bytes.
2007-07-01 09:48:37 +00:00
dsl
5f7e78696b Remove 'else' after 'return' for clarity 2007-07-01 09:47:19 +00:00
dyoung
c81bbe837f Include opt_ata.h for ATADEBUG definition instead of #defining it
unconditionally.

Make this compile when ATADEBUG is not #defined.
2007-04-08 06:59:43 +00:00
dyoung
d424839018 Include opt_ata.h for ATADEBUG definition instead of #defining it
unconditionally.
2007-04-08 06:58:47 +00:00