summaryrefslogtreecommitdiffstats
path: root/sys/geom/geom_pc98.c
Commit message (Collapse)AuthorAgeFilesLines
* Don't pass error value pointer to g_read_data(9) at all if we don'tsobomax2005-11-301-1/+1
| | | | | | have any use of it. Suggested by: pjd
* Check for g_read_data(9) errors properly:sobomax2005-11-301-1/+1
| | | | | | | | | | o The only indication of error condition is NULL value returned by the function; o value pointed to by error argument is undefined in the case when operation completes successfully. Discussed with: phk
* Merged from geom_mbr.c revisions 1.62 and 1.66.nyan2005-07-151-6/+68
| | | | - Implement a gctl handler and the verb "write MBR".
* Remove geometry translations here.nyan2005-03-301-23/+0
|
* Pass the file->flags down to geom ioctl handlers.phk2004-12-121-1/+4
| | | | | | | | Reject certain ioctls if write permission is not indicated. Bump geom API version. Reported by: Ruben de Groot <mail25@bzerk.org>
* Add observations of the Linux98 and Grub/98 boot loaders. Theseimp2004-11-301-5/+15
| | | | | | | | | observations lead me to believe that the convetion for pc98 boot loaders is to have a jump unstruction, followed by a string, followed by code. The jump usually doesn't have a nop after it and usually the string is NUL terminated, but Grub/98 breaks both of these rules. # I looked for, but failed to find the Minux boot blocks for PC-9801 port.
* Reject tasting of this provider if the sector size isn't a multiple ofimp2004-11-301-3/+6
| | | | | | | | | | | | | | | | | | | 512. If I had an audio cdrom in my cd player when I booted my system, I'd get a panic from geom because you can't read 8192 bytes from an audio cdrom. Remove XXX comment about IPL1 and replace it with some information from my soon to be published web page on the pc98 disk layout. The IPL1 test was the result of an observation of a disk with FreeBSD's boot0 program. It was testing part of an area what appears to be reserved for a boot loader name, which comes after a jump over this area. I don't yet know if it is required to be any specific jump instruction, or if the destination has to be location 11. [1] [1] FreeBSD Press No. 13, page 115, poorly translated by myself. The picture there shows offset 8 as the destination of the jump, but FreeBSD's boot0 program has three padding NULs after the IPL1 name and uses a 16-bit 'jmp' instruction.
* Only do the geometry translations on ad* devices, other devices seems tosos2004-10-081-18/+22
| | | | | have their own way of life. Those other devices translations should be moved here as well.
* Move the PC98 specific geometry "gunk" to geom_pc98.c where it belongs.sos2004-10-071-0/+19
| | | | | | | | This also adds support for bigger disks on the controller I have access to, and maybe others if I understood the adhoc methods used on those. Those with more PC98 bigdrive controllers it is hereby invited to add/fix support for those in geom_pc98.c and not using #ifdef PC98 all over the place.
* Tag all geom classes in the tree with a version number.phk2004-08-081-0/+1
|
* Use default method initialization on geoms.phk2004-08-081-2/+2
|
* Remove the absolute count g_access_abs() function since experience hasphk2004-02-121-1/+1
| | | | | | | | | | | | shown that it is not useful. Rename the relative count g_access_rel() function to g_access(), only the name has changed. Change all g_access_rel() calls in our CVS tree to call g_access() instead. Add an #ifndef BURN_BRIDGES #define of g_access_rel() for source code compatibility.
* Re-arrange and consolidate some random debugging stuffscottl2003-12-071-1/+1
|
* Simplify the ioctl handling in GEOM.phk2003-09-011-51/+21
| | | | | | | | | | | | | | | This replaces the current ioctl processing with a direct call path from geom_dev() where the ioctl arrives (from SPECFS) to any directly connected GEOM class. The inverse of the above is no longer supported. This is the situation were you have one or more intervening GEOM classes, for instance a BSDlabel on top of a MBR or PC98. If you want to issue MBR or PC98 specific ioctls, you will need to issue them on a MBR or PC98 providers. This paves the way for inviting CD's, FD's and other special cases inside GEOM.
* Use __FBSDID().obrien2003-06-111-2/+3
| | | | Approved by: phk
* Remove unused variable.phk2003-05-311-4/+0
| | | | | | Remove unneeded return; Found by: FlexeLint
* Remove the G_CLASS_INITIALIZER, we do not need it anymore.phk2003-05-311-1/+0
|
* Use g_slice_spoiled() not g_std_spoiled()phk2003-05-021-1/+1
|
* Remove DIOCGPC98 ioctl.nyan2003-05-011-5/+0
|
* - Move decoding pc98_partition function into geom_pc98_enc.c.nyan2003-05-011-24/+2
| | | | - Add encoding pc98_partition function.
* Rename g_call_me() to g_post_event(), and give it a flagphk2003-04-231-1/+1
| | | | argument to determine if we can M_WAITOK in malloc.
* Time has run from the "run GEOM in userland" harness, and the new regressionphk2003-04-131-8/+0
| | | | | | | test is built to test GEOM as running in the kernel. This commit is basically "unifdef -D_KERNEL" to remove the mainly #include related code to support the userland-harness.
* Retire the "frontstuff" record keeping, it was no match for thephk2003-04-121-1/+0
| | | | in-band meta-data of BSD labels and a more complex solution will be needed.
* With the magic sequence checks removed this class is downright dangerousphk2003-04-091-6/+11
| | | | | | | | to have in your kernel since it indiscriminately attaches to anything it is offered with a range of bogus partitions. Stop this from happening by rejecting any label with negative numbers in it.
* Style issue: use do {...} while(0); for multi-exit section.phk2003-04-091-2/+2
|
* #include <sys/endian.h> as needed.phk2003-04-031-0/+1
|
* Use <sys/endian.h> instead of geom_enc.c for endianess-agnostification.phk2003-04-031-3/+3
|
* Add handling for cancelled events in the g_call_me() methods.phk2003-04-021-2/+5
|
* Change events to have an array of "void *" references, and give thephk2003-04-021-2/+2
| | | | | | | | | | | event posting functions varargs to fill these. Attribute g_call_me() to appropriate g_geom's where necessary. Add a flag argument to g_call_me() methods which will be used to signal cancellation of events in the future. This commit should be a no-op.
* Premptively change initializations of struct g_class to use C99phk2003-03-241-3/+2
| | | | | sparse struct initializations before we extend the struct with new OAM related member functions.
* In userland case include <errno.h>, not <err.h>. This is needed to makephk2003-01-061-1/+1
| | | | the src/tools/regression/geom stuff compile.
* Rename the dos_partition structure for pc98 to pc98_partition.nyan2003-01-041-8/+8
|
* MFMBR: Add ioctls for writing an IPL and a boot menu.nyan2003-01-031-70/+160
|
* Don't mangle geometry for pc98, this will happen in the ata driver.phk2002-12-171-4/+0
|
* Get rid of g_slice_addslice() and use g_slice_config() instead.phk2002-12-161-9/+6
| | | | Tested with: i386 + src/tools/regression/geom
* Constification and some s/int/u_int/ changes.phk2002-12-161-8/+8
|
* Add support for the PC98 platform to the ATA driver.sos2002-12-031-0/+4
| | | | | | | | | | | | | | | | This mostly consists of functionality to serialize accesses to the two ATA channels (which can also be used to "fix" certain PCI based controllers). Add support for Acard controllers. Enable the ATA driver in PC98 GENERIC, and add device hints. Update man page with latest support. The PC98 core team has kindly provided me with a PC98 machine that made this all possible, thanks to all that contributed to that effort, without that this would probably newer have been possible.. Approved by: re@
* Save a slice name on the disk and print it at g_pc98_dumpconf().nyan2002-11-171-14/+26
|
* Fix to support pc98.nyan2002-11-071-52/+115
| | | | | | It is mostly merged from MBR specific part. Reviewed by: phk
* Reject slices where begin == end.phk2002-11-041-11/+11
| | | | | | Remove clause 3 from the license with NAI Labs consent. Sponsored by: DARPA & NAI Labs
* Don't truncate on large disks.phk2002-10-271-1/+6
|
* Make geom_mbr.c optional on PC98, use GEOM_MBR option to include it.phk2002-10-261-0/+6
| | | | | Disable check for supposedly magic "IPL1" string for PC98 labels, its thaumaturgical power is in doubt.
* Reduce the GEOM verbosity under bootverbose to something more sufferable.phk2002-10-251-1/+0
| | | | | | | This is not quite the set of information I would want, but the tree where I have the "correct" version is messed up with conflicts. Sponsored by: DARPA & NAI Labs.
* Now that the sectorsize and mediasize are properties of the provider,phk2002-10-201-12/+4
| | | | | | | | | | | don't take the detour over the I/O path to discover them using getattr(), we can just pick them out directly. Do note though, that for now they are only valid after the first open of the underlying disk device due compatibility with the old disk_create() API. This will change in the future so they will always be valid. Sponsored by: DARPA & NAI Labs.
* Make the sectorsize a property of providers so we can include it in the XMLphk2002-10-201-0/+1
| | | | | | output. Sponsored by: DARPA & NAI Labs
* Use %jd instead of %lld now that we have it.phk2002-10-201-2/+3
|
* Style, whitespace and lint fixes.phk2002-09-281-1/+0
| | | | Sponsored by: DARPA & NAI Labs.
* Add the new g_slice_config() call, which can add/delete/change a slice,phk2002-09-271-3/+2
| | | | | | | | | with support for trying, doing and forcing. This will eventually replace g_slice_addslice() which gets changed from grabbing topology to requing it in this commit as well. Sponsored by: DARPA & NAI Labs.
* Correctly calculate size of PC98 slices.phk2002-09-271-1/+1
| | | | Sponsored by: DARPA & NAI Labs.
* "Fix" printf format issues by using %jphk2002-09-131-2/+3
| | | | Sponsored by: DARPA & NAI Labs.
OpenPOWER on IntegriCloud