diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/sys/diskslice.h | 32 |
1 files changed, 31 insertions, 1 deletions
diff --git a/sys/sys/diskslice.h b/sys/sys/diskslice.h index c7059c7..c219832 100644 --- a/sys/sys/diskslice.h +++ b/sys/sys/diskslice.h @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: diskslice.h,v 1.6 1995/04/24 17:07:08 bde Exp $ + * $Id: diskslice.h,v 1.7 1995/04/30 15:13:55 bde Exp $ */ #ifndef _SYS_DISKSLICE_H_ @@ -38,6 +38,8 @@ #define MAX_SLICES 32 #define WHOLE_DISK_SLICE 1 +/* upcoming change from julian.. early warning of probable form */ +#if 1 struct diskslice { u_long ds_offset; /* starting sector */ u_long ds_size; /* number of sectors */ @@ -50,6 +52,34 @@ struct diskslice { u_char ds_wlabel; /* nonzero if label is writable */ }; +#else +/* switch table for slice handlers (sample only) */ +struct slice_switch ( + int (*slice_load)(); + int (*slice_check(); + int (*slice_gone)(); + /* + * etc. + * each routine is called with the address of the private data + * and the minor number.. + * Other arguments as needed + */ +}; + +struct diskslice { + u_long ds_offset; /* starting sector */ + u_long ds_size; /* number of sectors */ + int ds_type; /* (foreign) slice type */ + struct dkbad_intern *ds_bad; /* bad sector table, if any */ + void *ds_date; /* Slice type specific data */ + struct slice_switch *switch; /* switch table for type handler */ + u_char ds_bopenmask; /* bdevs open */ + u_char ds_copenmask; /* cdevs open */ + u_char ds_openmask; /* [bc]devs open */ + u_char ds_wlabel; /* nonzero if label is writable */ +}; +#endif + struct diskslices { int dss_first_bsd_slice; /* COMPATIBILTY_SLICE is mapped here */ u_int dss_nslices; /* actual dimension of dss_slices[] */ |