]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - include/sys/sunldi.h
Go through and add a header with the proper UCRL number.
[FreeBSD/FreeBSD.git] / include / sys / sunldi.h
1 /*
2  *  This file is part of the SPL: Solaris Porting Layer.
3  *
4  *  Copyright (c) 2008 Lawrence Livermore National Security, LLC.
5  *  Produced at Lawrence Livermore National Laboratory
6  *  Written by:
7  *          Brian Behlendorf <behlendorf1@llnl.gov>,
8  *          Herb Wartens <wartens2@llnl.gov>,
9  *          Jim Garlick <garlick@llnl.gov>
10  *  UCRL-CODE-235197
11  *
12  *  This is free software; you can redistribute it and/or modify it
13  *  under the terms of the GNU General Public License as published by
14  *  the Free Software Foundation; either version 2 of the License, or
15  *  (at your option) any later version.
16  *
17  *  This is distributed in the hope that it will be useful, but WITHOUT
18  *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
19  *  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
20  *  for more details.
21  *
22  *  You should have received a copy of the GNU General Public License along
23  *  with this program; if not, write to the Free Software Foundation, Inc.,
24  *  51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA.
25  */
26
27 #ifndef _SPL_SUNLDI_H
28 #define _SPL_SUNLDI_H
29
30 #include <sys/types.h>
31 #include <linux/fs.h>
32 #include <linux/genhd.h>
33 #include <linux/hdreg.h>
34 #include <linux/bio.h>
35
36 #define SECTOR_SIZE 512
37
38 typedef struct modlinkage {
39         int ml_rev;
40         struct modlfs *ml_modlfs;
41         struct modldrv *ml_modldrv;
42         major_t ml_major;
43         unsigned ml_minors;
44         void *pad1;
45 } modlinkage_t;
46
47 typedef struct ldi_ident {
48         char li_modname[MAXNAMELEN];
49         dev_t li_dev;
50 } *ldi_ident_t;
51
52 typedef struct block_device *ldi_handle_t;
53
54 extern int ldi_ident_from_mod(struct modlinkage *modlp, ldi_ident_t *lip);
55 extern void ldi_ident_release(ldi_ident_t li);
56
57 #endif /* SPL_SUNLDI_H */