Age | Commit message (Collapse) | Author | |
---|---|---|---|
2019-11-09 | Fix SCSIDEBUG compile. Missed a %lx -> %x. | Kenneth R Westerback | |
2019-11-08 | The u_long fields in struct disk_parms (secsize, heads, cyls, sectors) | Kenneth R Westerback | |
are always initializd to u_int32_t values. And are then copied into u_int32_t fields in the disklabel. Switch them to u_int32_t. Cluebats and ok deraadt@ jca@ | |||
2019-11-07 | sd_size() is a wrapper around sd_read_cap_10() and sd_read_cap_16() so | Kenneth R Westerback | |
rename it sd_read_cap(). Reduces possible confusion with the unrelated sdsize(). | |||
2019-10-23 | There used to be three possible return values from sd_get_parms(), but | Kenneth R Westerback | |
for some years it's been a succeed/fail function. So switch to using 0/-1 as return values and nuke SDGP_RESULT_OFFLINE and SDGP_RESULT_OK #defines. Shake out logic inside sd_get_parms() to take account of the change, making it clearer. Removes a possible panic(). | |||
2019-10-22 | No need to always pass the same thing to sd_get_parms(). One less | Kenneth R Westerback | |
parameter to worry about. | |||
2019-10-19 | Use !ISSET() for unset flag checks. | Kenneth R Westerback | |
2019-10-19 | Use ISSET() for the easier flag checks. | Kenneth R Westerback | |
2019-10-19 | Fix typo in previous, link->flag is link->flags. | Kenneth R Westerback | |
2019-10-19 | Resolve mix of '&=' and CLR() usage in favour of CLR(). | Kenneth R Westerback | |
2019-10-19 | Resolve mix of '|=' and SET() usage in favour of SET(). | Kenneth R Westerback | |
2019-09-30 | SC_DEBUGN is not spelled SCSI_DEBUGN. | Kenneth R Westerback | |
2019-09-29 | Restore SC_DEBUGN() as it was used outside sys/scsi. Some things are | Kenneth R Westerback | |
not compiled on amd64! | |||
2019-09-29 | Introduce SC_DEBUG_SENSE() and simplify code by eliminating a bunch | Kenneth R Westerback | |
of three line SCSIDEBUG chunks. | |||
2019-09-29 | Continue SCSIDEBUG cleanup by nuking pointles SC_DEBUGN() #define. | Kenneth R Westerback | |
2019-09-29 | Move some logic inside scsi_show_xs() instead of surrounding the | Kenneth R Westerback | |
single invocation of the same. Clearer. | |||
2019-09-29 | Tweak some whitespace to make autoindenter happy. Use consistent naming ↵ | Kenneth R Westerback | |
idiom for the debug functions. | |||
2019-09-27 | Use consistent idiom/naming convention for the the #include | Kenneth R Westerback | |
guards. Spelunkers using grep are easily confused. | |||
2019-09-27 | Add/tweak #endif comments to make spelunking via grep more rewarding. | Kenneth R Westerback | |
2019-09-27 | Shuffle and consolidate SCSIDEBUG declarations into fewer sections in | Kenneth R Westerback | |
more intuitive locations. | |||
2019-09-24 | Use consistent names for unused flags/quirks when printing same under | Kenneth R Westerback | |
SCSIDEBUG. | |||
2019-09-23 | When printing the scsi_link info under SCSIDEBUG show state, luns, | Kenneth R Westerback | |
openings, flags and quirks. | |||
2019-09-21 | Expand scsi_inquiry_data to 96 bytes to include new fields. If the | Kenneth R Westerback | |
device claims to have more than the 36 bytes of SCSI2 data, issue a 2nd INQUIRY (under SCSIDEBUG!) to get up to 96 bytes of data. Add some length sanity checks to debug output. Print VPD data under SCSIDEBUG. | |||
2019-09-20 | Print inquiry and read capacity (10 and 16) data under SCSIDEBUG. | Kenneth R Westerback | |
2019-09-19 | Introduce and use convenience SID_REPOONSE_FORMAT() define. | Kenneth R Westerback | |
2019-09-19 | Add new (a.k.a SBC-4) flags/fields to struct scsi_read_cap_16. Adopt | Kenneth R Westerback | |
more concise nameing convention roughly adopted from FreeBSD as tweaked by SBC-4. Keep older names when they are currently in use elsewhere. | |||
2019-09-18 | Update struct inquiry_data with latest flags and remove flags that we didn't ↵ | Kenneth R Westerback | |
use and are now (SPC-4+) marked as "reserved" instead of just "obsolete". Whitespace tweaks to line stuff up. Mostly following FreeBSD. | |||
2019-09-16 | Update list of device types with combination of FreeBSD and | Kenneth R Westerback | |
SPC-5. Add/Fix comments. | |||
2019-09-15 | With the recent fixes to SCSI version detection we reproduced a | Kenneth R Westerback | |
problem encountered by FreeBSD and Linux when they started to try issuing READ CAPACITY 16 commands to 'newer' devices. i.e. some USB devices return bad data instead of an error when they can't handle the command. Reproduce the FreeBSD solution (r233746 by mav@) by issuing READ CAPACITY 16 commands only to devices that claim to be REALLY new (a.k.a. newer than SPC-2, a.k.a. newer than SCSI-3), or which indicate they really are bigger than can be reported via READ CAPACITY 10. Should fix some USB devices claiming to have 71,776,119,061,217,281 or 33,601,071,049,867,265 sectors. | |||
2019-09-14 | Typo in comment. scsi_size() is actually sd_size(). | Kenneth R Westerback | |
2019-09-10 | Shuffle a couple of lines to make the device -> st_softc dances look | Kenneth R Westerback | |
the same. | |||
2019-09-10 | No need to check for ST_MOUNTED before calling st_mount_tape() AND in | Kenneth R Westerback | |
st_mount_tape(). Just keep the latter. st_mount_tape() is called from inside stopen() which has already found the relevant st_softc(), incremented the device reference count, and checked if it is dying. No need to repeast that in st_mount_tape(). Just pass the st_softc. | |||
2019-09-10 | return is not a funciton call. Avoid pointless parenthesis. | Kenneth R Westerback | |
2019-09-10 | Explicitly check error results against 0. | Kenneth R Westerback | |
2019-09-10 | Some stray bit twiddles that were using yet another idiom. | Kenneth R Westerback | |
2019-09-10 | check pointer against NULL and error values against 0. | Kenneth R Westerback | |
2019-09-10 | Last (?) small bit twiddling modernization. | Kenneth R Westerback | |
2019-09-10 | !ISSET() for various flags. | Kenneth R Westerback | |
2019-09-10 | SET/CLR/ISSET all at once for st->quirks, and a few other rare flags. | Kenneth R Westerback | |
2019-09-09 | SET/CLR/ISSET all at once for the far less numerous link->flags. | Kenneth R Westerback | |
2019-09-09 | Continue bit twiddling tweaks. Use SET() with st->flags. | Kenneth R Westerback | |
2019-09-09 | Lots of st->flags bit clearing in a mix of old school and CLR() makes | Kenneth R Westerback | |
code harder to read. Switch to CLR(). No change to executable. | |||
2019-09-09 | Lots of st->flags checking in a mix of old school and ISSET() makes | Kenneth R Westerback | |
code harder to read. Switch to ISSET() where obvious. No change to executable. | |||
2019-09-09 | Tweak some comments to be useful. Sort switch cases into | Kenneth R Westerback | |
numerical order. Move bit of logic before calling st_unmount() into st_unmount(). | |||
2019-09-07 | Fold st_identify_drive() into stattach(). | Kenneth R Westerback | |
2019-09-07 | Tweak some comments and code layout to make MTSETBSIZE and MTSETDENSITY | Kenneth R Westerback | |
cases look the same. | |||
2019-09-07 | ST_USER_BLKSIZE and ST_QUIRK_BLKSIZE are only tested as an or'd pair. | Kenneth R Westerback | |
Ditto for ST_USER_DENSITY and ST_QUIRK_DENSITY. Thus the origin of the value stored in the mode is irrelevant. Just use two flags (ST_MODE_BLKSIZE and ST_MODE_DENSITY) instead of the existing four. | |||
2019-09-07 | ST_Q_FORCE_BLKSIZE is superfluous since it is only used in combination with | Kenneth R Westerback | |
a non-zero value of blksize in the quirkdata. So just check for non-zero value of blksize, as is already done for density. | |||
2019-09-07 | Nuke unused flag ST_BLOCK_SET. | Kenneth R Westerback | |
2019-09-07 | Various struct/variables "modes" -> "mode" since there is only one. | Kenneth R Westerback | |
2019-09-05 | Nuke some 25+year old comments that the oracles at delphi would have | Kenneth R Westerback | |
found obscure. Repair a broken WangTEK 5150ES quirks entry that apparently suffered some damage when imported in 1995. It never made NetBSD/FreeBSD quirk lists at all. Some whitespace tweaking to make everything line up. |