History log of /freebsd-10.0-release/sys/geom/geom_pc98.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 259065 07-Dec-2013 gjb

- Copy stable/10 (r259064) to releng/10.0 as part of the
10.0-RELEASE cycle.
- Update __FreeBSD_version [1]
- Set branch name to -RC1

[1] 10.0-CURRENT __FreeBSD_version value ended at '55', so
start releng/10.0 at '100' so the branch is started with
a value ending in zero.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 254015 06-Aug-2013 marcel

Change <sys/diskpc98.h> to not redefine the same symbols that are
being defined in <sys/diskmbr.h>. Instead give the symbols here a
"PC98_" prefix. This way, both <sys/diskmbr.h> and <sys/diskpc98.h>
can be included in the same C source file.

The renaming is trivial. The only gotcha is that DOSBBSECTOR is
also redefined from 0 to 1. This because DOSBBSECTOR was always
used in conjunction with an addition of 1. The PC98_BBSECTOR symbol
is defined as 1 and the expression is simplified.

Note: it is not believed that ports are seriously impacted; or at
all for that matter.

Approved by: nyan@


# 230643 28-Jan-2012 attilio

Avoid to check the same cache line/variable from all the locking
primitives by breaking stop_scheduler into a per-thread variable.
Also, store the new td_stopsched very close to td_*locks members as
they will be accessed mostly in the same codepaths as td_stopsched and
this results in avoiding a further cache-line pollution, possibly.

STOP_SCHEDULER() was pondered to use a new 'thread' argument, in order to
take advantage of already cached curthread, but in the end there should
not really be a performance benefit, while introducing a KPI breakage.

In collabouration with: flo
Reviewed by: avg
MFC after: 3 months (or never)
X-MFC: r228424


# 223921 11-Jul-2011 ae

Include sys/sbuf.h directly.

Reviewed by: pjd


# 219029 25-Feb-2011 netchild

Add some FEATURE macros for various GEOM classes.

No FreeBSD version bump, the userland application to query the features will
be committed last and can serve as an indication of the availablility if
needed.

Sponsored by: Google Summer of Code 2010
Submitted by: kibab
Reviewed by: silence on geom@ during 2 weeks
X-MFC after: to be determined in last commit with code from this project


# 152971 30-Nov-2005 sobomax

Don't pass error value pointer to g_read_data(9) at all if we don't
have any use of it.

Suggested by: pjd


# 152967 30-Nov-2005 sobomax

Check for g_read_data(9) errors properly:

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


# 148061 15-Jul-2005 nyan

Merged from geom_mbr.c revisions 1.62 and 1.66.
- Implement a gctl handler and the verb "write MBR".


# 144333 30-Mar-2005 nyan

Remove geometry translations here.


# 138732 12-Dec-2004 phk

Pass the file->flags down to geom ioctl handlers.

Reject certain ioctls if write permission is not indicated.

Bump geom API version.

Reported by: Ruben de Groot <mail25@bzerk.org>


# 138221 30-Nov-2004 imp

Add observations of the Linux98 and Grub/98 boot loaders. These
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.


# 138219 30-Nov-2004 imp

Reject tasting of this provider if the sector size isn't a multiple of
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.


# 136284 08-Oct-2004 sos

Only do the geometry translations on ad* devices, other devices seems to
have their own way of life.
Those other devices translations should be moved here as well.


# 136233 07-Oct-2004 sos

Move the PC98 specific geometry "gunk" to geom_pc98.c where it belongs.
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.


# 133318 08-Aug-2004 phk

Tag all geom classes in the tree with a version number.


# 133314 08-Aug-2004 phk

Use default method initialization on geoms.


# 125755 12-Feb-2004 phk

Remove the absolute count g_access_abs() function since experience has
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.


# 123215 07-Dec-2003 scottl

Re-arrange and consolidate some random debugging stuff


# 119660 01-Sep-2003 phk

Simplify the ioctl handling in GEOM.

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.


# 116196 11-Jun-2003 obrien

Use __FBSDID().

Approved by: phk


# 115517 31-May-2003 phk

Remove unused variable.
Remove unneeded return;

Found by: FlexeLint


# 115468 31-May-2003 phk

Remove the G_CLASS_INITIALIZER, we do not need it anymore.


# 114507 02-May-2003 phk

Use g_slice_spoiled() not g_std_spoiled()


# 114421 01-May-2003 nyan

Remove DIOCGPC98 ioctl.


# 114414 01-May-2003 nyan

- Move decoding pc98_partition function into geom_pc98_enc.c.
- Add encoding pc98_partition function.


# 113937 23-Apr-2003 phk

Rename g_call_me() to g_post_event(), and give it a flag
argument to determine if we can M_WAITOK in malloc.


# 113432 13-Apr-2003 phk

Time has run from the "run GEOM in userland" harness, and the new regression
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.


# 113390 12-Apr-2003 phk

Retire the "frontstuff" record keeping, it was no match for the
in-band meta-data of BSD labels and a more complex solution will be needed.


# 113292 09-Apr-2003 phk

With the magic sequence checks removed this class is downright dangerous
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.


# 113285 09-Apr-2003 phk

Style issue: use do {...} while(0); for multi-exit section.


# 113013 03-Apr-2003 phk

#include <sys/endian.h> as needed.


# 113011 03-Apr-2003 phk

Use <sys/endian.h> instead of geom_enc.c for endianess-agnostification.


# 112989 02-Apr-2003 phk

Add handling for cancelled events in the g_call_me() methods.


# 112988 02-Apr-2003 phk

Change events to have an array of "void *" references, and give the
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.


# 112552 24-Mar-2003 phk

Premptively change initializations of struct g_class to use C99
sparse struct initializations before we extend the struct with
new OAM related member functions.


# 108817 06-Jan-2003 phk

In userland case include <errno.h>, not <err.h>. This is needed to make
the src/tools/regression/geom stuff compile.


# 108650 04-Jan-2003 nyan

Rename the dos_partition structure for pc98 to pc98_partition.


# 108591 03-Jan-2003 nyan

MFMBR: Add ioctls for writing an IPL and a boot menu.


# 107970 17-Dec-2002 phk

Don't mangle geometry for pc98, this will happen in the ata driver.


# 107956 16-Dec-2002 phk

Get rid of g_slice_addslice() and use g_slice_config() instead.

Tested with: i386 + src/tools/regression/geom


# 107953 16-Dec-2002 phk

Constification and some s/int/u_int/ changes.


# 107562 03-Dec-2002 sos

Add support for the PC98 platform to the ATA driver.
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@


# 107012 17-Nov-2002 nyan

Save a slice name on the disk and print it at g_pc98_dumpconf().


# 106559 07-Nov-2002 nyan

Fix to support pc98.
It is mostly merged from MBR specific part.

Reviewed by: phk


# 106398 04-Nov-2002 phk

Reject slices where begin == end.
Remove clause 3 from the license with NAI Labs consent.

Sponsored by: DARPA & NAI Labs


# 106030 27-Oct-2002 phk

Don't truncate on large disks.


# 106001 26-Oct-2002 phk

Make geom_mbr.c optional on PC98, use GEOM_MBR option to include it.

Disable check for supposedly magic "IPL1" string for PC98 labels, its
thaumaturgical power is in doubt.


# 105957 25-Oct-2002 phk

Reduce the GEOM verbosity under bootverbose to something more sufferable.
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.


# 105551 20-Oct-2002 phk

Now that the sectorsize and mediasize are properties of the provider,
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.


# 105542 20-Oct-2002 phk

Make the sectorsize a property of providers so we can include it in the XML
output.

Sponsored by: DARPA & NAI Labs


# 105540 20-Oct-2002 phk

Use %jd instead of %lld now that we have it.


# 104087 28-Sep-2002 phk

Style, whitespace and lint fixes.

Sponsored by: DARPA & NAI Labs.


# 104064 27-Sep-2002 phk

Add the new g_slice_config() call, which can add/delete/change a slice,
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.


# 104059 27-Sep-2002 phk

Correctly calculate size of PC98 slices.

Sponsored by: DARPA & NAI Labs.


# 103284 13-Sep-2002 phk

"Fix" printf format issues by using %j

Sponsored by: DARPA & NAI Labs.


# 98066 09-Jun-2002 phk

Improve some on the naming.

Submitted by: iedowse


# 97075 21-May-2002 phk

Remove the "-class" suffix from classes, they will not be ambiguous.

Sponsored by: DARPA & NAI Labs.


# 94287 09-Apr-2002 phk

Implement DIOCGFRONTSTUFF ioctl which reports how many bytes from the start
of the device magic stuff might occupy.

Sponsored by: DARPA & NAI Labs.


# 94285 09-Apr-2002 phk

Various stylistic nit picking.

Sponsored by: DARPA & NAI Labs.


# 93776 04-Apr-2002 phk

Move access and orphan member functions from class to geom.

Sponsored by: DARPA & NAI Labs


# 93354 28-Mar-2002 phk

Add preliminary PC98 class to GEOM.

I have not been able to find very much information about the PC98
extended partition layout so this is gleaned from the source in
our pc98 architecture. Corrections and patched very welcome.

Sponsored by: DARPA and NAI Labs.