summaryrefslogtreecommitdiff
path: root/sys/arch/hp300/dev/hd.c
AgeCommit message (Collapse)Author
2009-08-24- fix format strings for values that are daddr64_tJasper Lievisse Adriaanse
ok otto@, agreed by deraadt@
2009-08-16Update to cope with new readdisklabel() return value.Miod Vallat
2009-06-13Needs <sys/malloc.h> nowMiod Vallat
2009-06-04Add DIOCRLDINFO to those drivers previously deprived.Kenneth R Westerback
Noticed by & ok deraadt@
2009-01-25If hdattach() aborts early because the disk is not in good shape, alwaysMiod Vallat
fail hdopen().
2008-10-15Second pass of simple timeout_add -> timeout_add_sec conversionsBret Lambert
This should take care of the simpler ones (i.e., timeout values of integer multiples of hz). ok krw@, art@
2007-06-21Brace got lost in rev 1.51.Miod Vallat
2007-06-20These drivers were abusing b_cylinder to store device-specific informationMiod Vallat
in strategy(), and were reusing it in start(). I first considered introducing a b_rawblkno field in struct buf, as has been done in NetBSD, to stop this abuse. However, it does not cost more to simply move the device-specific ``was-b_cylinder'' computation to the start() routine. Plus we get type fixes (daddr64_t) for free, although this does not really matter for these pedro-sized devices. Thus we do not need to grow struct buf for these devices which really ought to live in your Attic (and my machineroom, of course). hp300 HP-IB tested, vax mfm not, but the logic is the same.
2007-06-20b_cylinder does not need to be set on the callpath down into drivers.Theo de Raadt
cpu_disklabel can go away, since nothing anymore needs to use it; ok miod
2007-06-08all drivers should spoof version 1 labelsTheo de Raadt
2007-06-06now that all partition size/offsets are potentially 64-bit, change theTheo de Raadt
type of all variables to daddr64_t. this includes the APIs for XXsize() and XXdump(), all range checks inside bio drivers, internal variables for disklabel handling, and even uvm's swap offsets. re-read numerous times by otto, miod, krw, thib to look for errors
2007-06-05use six new macros to access & store the 48-bit disklabel fields relatedTheo de Raadt
to size. tested on almost all machines, double checked by miod and krw next comes the type handling surrounding these values
2007-06-01Don't initialize d_partitions[RAW_DISK] just before callingKenneth R Westerback
readdisklabel(), since all readdisklabel()'s do that already. ok deraadt@
2007-04-30HDUNIT/etc -> DISKUNIT/etc. No functional change.Kenneth R Westerback
"Looks right" millert@ "toss 'em in" deraadt@
2007-02-28Use diskerr() to print error messages.Miod Vallat
2007-02-22Comment out the errmsg printf in hdgetdisklabel() again.Miod Vallat
2007-02-21Long awaiting modernization:Miod Vallat
- reset the drive and fetch its identification strings during probe, and do not attach if they don't look good. - do not store synchronous command blocks (used by hdreset) in the softc, since they are not processed asynchronously. The stack will do. - cleanup the disklabel retrieval code. - use disk_{,un}lock instead of rolling our own equivalent. - use bounds_check_with_label() in hdstrategy() instead of a stripped-down inline version of it. Tested on 7957A.
2007-02-21remove part of buf abuse and store errcnt in softc (instead of b_errcnt); ↵Michael Shalayeff
more work can be done to lower buf abuse even more; miod@ testing and ok
2006-08-12Setting d_secsize to DEV_BSIZE (or 1 << DEV_BSHIFT, or 512) and thenKenneth R Westerback
setting RAW_PART's p_size to d_secperunit * (d_secsize / DEV_BSIZE) is a waste of a few ops. And p_size should be in sectors anyway. Just set RAW_PART's p_size to d_secperunit to make usage consistant across the tree. Should be a no-op.
2006-03-15Nuke dk_establish(), no longer used.Miod Vallat
2006-01-22b_cylin -> b_cylinder; no functional change.Miod Vallat
2006-01-20b_un.b_addr -> b_data; no functional change.Miod Vallat
2005-11-18Protect biodone() with splbio().Miod Vallat
2005-11-18Define the CS/80 identify structure only once and correctly, instead ofMiod Vallat
duplicating it in every CS/80 driver and using an hardcoded number for its size. No functional change.
2005-11-16Overhaul the way HP-IB devices are probed. We will now do an exhaustiveMiod Vallat
probe of the (slave, punit) tuple space, since this is the only way we can get a dual disk or dual tape enclosure to attach two devices of the same kind. This allows us to get rid of the hpibbus resource map and related functions.
2005-11-15Only two `h' in threshold.Miod Vallat
2005-11-15More typos (especially indicies -> indices), checked with jmc@Miod Vallat
2005-11-14Make HDWAITC and HDRETRY overridable in the kernel configuration file;Miod Vallat
while there, constify option DEBUG message tables.
2005-11-14constuct -> constructMiod Vallat
2005-11-14hz is defined in <sys/kernel.h>Miod Vallat
2005-11-13Better error message layout.Miod Vallat
2005-11-12Constify, and simplify hdgetinfo() which only gets called for known disks.Miod Vallat
2005-11-12Print HP-IB disk geometry the same way we print SCSI disk geometriesMiod Vallat
(especially, with the size in MB).
2005-09-06anomoly -> anomalyMiod Vallat
2005-01-15Kill whitespace at EOL.Miod Vallat
2004-02-15sneaky disk_unbusy()'s tried to hideTed Unangst
2003-06-02Remove the advertising clause in the UCB license which BerkeleyTodd C. Miller
rescinded 22 July 1999. Proofed by myself and Theo.
2003-04-06Some easy strcpy elimination.Kenneth R Westerback
a) strcpy -> strncpy for copies into disklabel fields d_packname and d_typename. b) '16' -> 'sizeof d_packname' or 'sizeof d_typename' in existing strncpy's. ok millert@
2003-04-06The disklabel fields d_packname and d_typename are not null terminated stringsKenneth R Westerback
and should not be created or used as such. This fixes some instances of both behaviours, and sets the stage for some strcpy -> strncpy fixup. ok tdeval@ millert@ deraadt@
2002-12-25Turn xxUNIT, xxPARt, xxLABELDEV macro names into uppercase.Miod Vallat
2002-12-10interupt->interruptMiod Vallat
2002-06-09convert sleep() calls to tsleep().Miod Vallat
2002-06-09fix the use of "cuz" in the tree; these are all in commentsJason Peel
noticed by aaron@, recommended by deraadt@
2002-05-30protect biodone with splbio.Artur Grabowski
miod@ ok.
2002-03-14First round of __P removal in sysTodd C. Miller
2001-09-20occured->occurredMike Pechkin
idea from deraadt@ via NetBSD millert@ ok
2001-08-26Nuke annoying defopt, by popular demand. Plus you get two typos fixedMiod Vallat
for free.
2001-05-01convert to new timeoutsTodd C. Miller
1998-10-04Add DIOCGPDINFO supportTodd C. Miller
1998-10-03Add a "spoofonly" argument to readdisklabel() which will be used toTodd C. Miller
implement an ioctl to get a spoofed label even for disks that have a label on them.