summaryrefslogtreecommitdiff
path: root/sys/kern/subr_disk.c
AgeCommit message (Expand)Author
2022-01-02Stop writing big-endian checksums into the little-endian GPTKenneth R Westerback
2021-12-22While malloc sleeps, the disk list could change during sysctl. ThenAlexander Bluhm
2021-10-24use NULL not 0 for pointer values in kernJonathan Gray
2021-06-13Back off a couple of the more paranoid checks while spoofing GPTKenneth R Westerback
2021-06-02Use the same logic in all copies of gpt_chk_mbr(), relaxing theKenneth R Westerback
2021-06-01Make spoofed disklabel boundstart and boundend default to the boundsKenneth R Westerback
2021-05-27Relax criteria for recognizing GPT formatted media by allowing theKenneth R Westerback
2021-05-14Whitespace tweaks and a couple of stray u_int* in gpt_chk_mbr().Kenneth R Westerback
2021-05-14Tweak the two copies of gpt_chk_mbr() to return the index of the MBRKenneth R Westerback
2021-05-08Spoof GPT partitions of type 21686148-6449-6e6f-744e-656564454649 (a.k.a.Kenneth R Westerback
2021-01-19kern/subr_disk.c: convert ifunit() to if_unit(9)mvs
2020-05-29dev/rndvar.h no longer has statistical interfaces (removed during variousTheo de Raadt
2020-03-13Simplify logic, the "netboot" interface is always related to `bootdv'.Martin Pieuchot
2019-12-26tsleep -> tsleep_nsec(9) in setroot()kn
2018-04-28replace add_*_randomness with enqueue_randomness()Jasper Lievisse Adriaanse
2018-03-05fix a memory leak in readdoslabel()Jonathan Gray
2017-08-07Turns out gcc complains about %02hhx. So simply use %02x instead. This isMark Kettenis
2017-08-06Use %hhx instead of %hx to print u_char. Silences clang warning.Mark Kettenis
2017-05-04Also pass the blk offset to disk_unbusy(), so that it can pass it toTheo de Raadt
2017-04-20Tweak lock inits to make the system runnable with witness(4)Visa Hankala
2016-09-02Don't bother with 'ghpartnum' in gpt_chk_hdr(); it's not usedTom Cosgrove
2016-05-21Fix logic bug in DUID generation - we want to generate DUIDs until we haveJoel Sing
2016-05-21Cleanup some of the DUID code and refactor for readability.Joel Sing
2016-05-20Remove dead assignment/unused variable.Joel Sing
2016-05-19Let setroot() pick the boot disk based on the DUID provided in bootduid ifMark Kettenis
2016-02-08"exceeds past the end" -> "extends past the end" in comment.Kenneth R Westerback
2015-12-24Make gpt_chk_mbr() instances even more identicaller by alwaysKenneth R Westerback
2015-12-24Make all instances of gpt_chk_mbr() identical (bar static vsKenneth R Westerback
2015-09-25Don't immediately try to checksum the GPT header using the sizeKenneth R Westerback
2015-09-24Move declaration of readdisksector() to disklabel.h. This makes itKenneth R Westerback
2015-09-24A couple of missing letoh32() conversions of GPT header fields inKenneth R Westerback
2015-09-15Unbeak boot from GPT partition. Reported by Henrik Friedrichsen.YASUOKA Masahiko
2015-09-13Move prototype for spoofgptlabel() from disklabel.h to subr_disk.c.Kenneth R Westerback
2015-09-13Rename readgptlabel() to spoofgptlabel() because that's what weKenneth R Westerback
2015-09-11Hoist all the GPT header checks into gpt_chk_header(). Tweak remainingKenneth R Westerback
2015-09-11Move all prototypes of gpt helper functions to top of file. RenameKenneth R Westerback
2015-09-11Shuffle some variables around, add a couple, and eliminate hordesKenneth R Westerback
2015-09-11Move initialization of count of spoofed GPT partitions closerKenneth R Westerback
2015-09-11GPT partitions cannot start at offset 0. Eliminate the variableKenneth R Westerback
2015-09-11KNF shuffling of local declarations in readgptlabel().Kenneth R Westerback
2015-09-11readgptlabel() is called from readdoslabel() so there is no needKenneth R Westerback
2015-09-11Spoof EFI SYSTEM GPT partitions as MSDOS partitions. As is doneKenneth R Westerback
2015-09-11Eliminate use-once variable in readgptlabel() and just use theKenneth R Westerback
2015-09-11Don't spoof GPT OpenBSD partitions. Simply record and use the first oneKenneth R Westerback
2015-09-10Now that the GPT code tries really hard not to get in the way andKenneth R Westerback
2015-09-10Call readgptlabel() from readdoslabel() instead of MD readdisklabel().Kenneth R Westerback
2015-09-10Don't stop spoofing GPT partitions when the OpenBSD partition isKenneth R Westerback
2015-09-09No need to set d_npartitions in readdoslabel() or readgptlabel().Kenneth R Westerback
2015-09-01a white space krw could not seeTheo de Raadt
2015-09-01'bogous' is bogus spelling of 'bogus' in debug message.Kenneth R Westerback