summaryrefslogtreecommitdiffstats
path: root/sys/cam
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>1999-05-30 16:53:49 +0000
committerphk <phk@FreeBSD.org>1999-05-30 16:53:49 +0000
commit7e4a9dced9acd97789b37c32063ee7a8aa133f6d (patch)
tree407469b3581129f6442306683b28d6b54126baad /sys/cam
parentdfa3967ffa4d84ed0b1691fac89ba3e73b8544e0 (diff)
downloadFreeBSD-src-7e4a9dced9acd97789b37c32063ee7a8aa133f6d.zip
FreeBSD-src-7e4a9dced9acd97789b37c32063ee7a8aa133f6d.tar.gz
This commit should be a extensive NO-OP:
Reformat and initialize correctly all "struct cdevsw". Initialize the d_maj and d_bmaj fields. The d_reset field was not removed, although it is never used. I used a program to do most of this, so all the files now use the same consistent format. Please keep it that way. Vinum and i4b not modified, patches emailed to respective authors.
Diffstat (limited to 'sys/cam')
-rw-r--r--sys/cam/cam_xpt.c43
-rw-r--r--sys/cam/scsi/scsi_cd.c43
-rw-r--r--sys/cam/scsi/scsi_ch.c43
-rw-r--r--sys/cam/scsi/scsi_da.c43
-rw-r--r--sys/cam/scsi/scsi_pass.c43
-rw-r--r--sys/cam/scsi/scsi_pt.c43
-rw-r--r--sys/cam/scsi/scsi_sa.c43
-rw-r--r--sys/cam/scsi/scsi_target.c40
8 files changed, 167 insertions, 174 deletions
diff --git a/sys/cam/cam_xpt.c b/sys/cam/cam_xpt.c
index 3fc748d..2ae2b3f 100644
--- a/sys/cam/cam_xpt.c
+++ b/sys/cam/cam_xpt.c
@@ -26,7 +26,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: cam_xpt.c,v 1.60 1999/05/23 18:57:29 gibbs Exp $
+ * $Id: cam_xpt.c,v 1.61 1999/05/25 20:17:29 gibbs Exp $
*/
#include <sys/param.h>
#include <sys/systm.h>
@@ -553,27 +553,26 @@ static d_open_t xptopen;
static d_close_t xptclose;
static d_ioctl_t xptioctl;
-static struct cdevsw xpt_cdevsw =
-{
- /*d_open*/ xptopen,
- /*d_close*/ xptclose,
- /*d_read*/ noread,
- /*d_write*/ nowrite,
- /*d_ioctl*/ xptioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ NULL,
- /*d_mmap*/ nommap,
- /*d_strategy*/ nostrategy,
- /*d_name*/ "xpt",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ nodump,
- /*d_psize*/ nopsize,
- /*d_flags*/ 0,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+static struct cdevsw xpt_cdevsw = {
+ /* open */ xptopen,
+ /* close */ xptclose,
+ /* read */ noread,
+ /* write */ nowrite,
+ /* ioctl */ xptioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ nopoll,
+ /* mmap */ nommap,
+ /* strategy */ nostrategy,
+ /* name */ "xpt",
+ /* parms */ noparms,
+ /* maj */ XPT_CDEV_MAJOR,
+ /* dump */ nodump,
+ /* psize */ nopsize,
+ /* flags */ 0,
+ /* maxio */ 0,
+ /* bmaj */ -1
};
static struct intr_config_hook *xpt_config_hook;
diff --git a/sys/cam/scsi/scsi_cd.c b/sys/cam/scsi/scsi_cd.c
index d7d96cc..730d97f 100644
--- a/sys/cam/scsi/scsi_cd.c
+++ b/sys/cam/scsi/scsi_cd.c
@@ -24,7 +24,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: scsi_cd.c,v 1.20 1999/05/09 01:25:24 ken Exp $
+ * $Id: scsi_cd.c,v 1.21 1999/05/22 22:00:18 gibbs Exp $
*/
/*
* Portions of this driver taken from the original FreeBSD cd driver.
@@ -243,27 +243,26 @@ DATA_SET(periphdriver_set, cddriver);
#ifndef D_DISK
#define D_DISK 0
#endif
-static struct cdevsw cd_cdevsw =
-{
- /*d_open*/ cdopen,
- /*d_close*/ cdclose,
- /*d_read*/ physread,
- /*d_write*/ nowrite,
- /*d_ioctl*/ cdioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ seltrue,
- /*d_mmap*/ nommap,
- /*d_strategy*/ cdstrategy,
- /*d_name*/ "cd",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ nodump,
- /*d_psize*/ nopsize,
- /*d_flags*/ D_DISK,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+static struct cdevsw cd_cdevsw = {
+ /* open */ cdopen,
+ /* close */ cdclose,
+ /* read */ physread,
+ /* write */ nowrite,
+ /* ioctl */ cdioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ nopoll,
+ /* mmap */ nommap,
+ /* strategy */ cdstrategy,
+ /* name */ "cd",
+ /* parms */ noparms,
+ /* maj */ CD_CDEV_MAJOR,
+ /* dump */ nodump,
+ /* psize */ nopsize,
+ /* flags */ D_DISK,
+ /* maxio */ 0,
+ /* bmaj */ CD_BDEV_MAJOR
};
static struct extend_array *cdperiphs;
diff --git a/sys/cam/scsi/scsi_ch.c b/sys/cam/scsi/scsi_ch.c
index 3e5ec38..6fd7aee 100644
--- a/sys/cam/scsi/scsi_ch.c
+++ b/sys/cam/scsi/scsi_ch.c
@@ -24,7 +24,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: scsi_ch.c,v 1.11 1999/05/09 01:25:26 ken Exp $
+ * $Id: scsi_ch.c,v 1.12 1999/05/22 22:00:19 gibbs Exp $
*/
/*
* Derived from the NetBSD SCSI changer driver.
@@ -214,27 +214,26 @@ static struct periph_driver chdriver =
DATA_SET(periphdriver_set, chdriver);
-static struct cdevsw ch_cdevsw =
-{
- /*d_open*/ chopen,
- /*d_close*/ chclose,
- /*d_read*/ noread,
- /*d_write*/ nowrite,
- /*d_ioctl*/ chioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ seltrue,
- /*d_mmap*/ nommap,
- /*d_strategy*/ nostrategy,
- /*d_name*/ "ch",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ nodump,
- /*d_psize*/ nopsize,
- /*d_flags*/ 0,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+static struct cdevsw ch_cdevsw = {
+ /* open */ chopen,
+ /* close */ chclose,
+ /* read */ noread,
+ /* write */ nowrite,
+ /* ioctl */ chioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ nopoll,
+ /* mmap */ nommap,
+ /* strategy */ nostrategy,
+ /* name */ "ch",
+ /* parms */ noparms,
+ /* maj */ CH_CDEV_MAJOR,
+ /* dump */ nodump,
+ /* psize */ nopsize,
+ /* flags */ 0,
+ /* maxio */ 0,
+ /* bmaj */ -1
};
static struct extend_array *chperiphs;
diff --git a/sys/cam/scsi/scsi_da.c b/sys/cam/scsi/scsi_da.c
index 4a5e000..598a054 100644
--- a/sys/cam/scsi/scsi_da.c
+++ b/sys/cam/scsi/scsi_da.c
@@ -25,7 +25,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: scsi_da.c,v 1.24 1999/05/09 01:25:28 ken Exp $
+ * $Id: scsi_da.c,v 1.25 1999/05/22 22:00:20 gibbs Exp $
*/
#include "opt_hw_wdog.h"
@@ -236,27 +236,26 @@ DATA_SET(periphdriver_set, dadriver);
#define D_DISK 0
#endif
-static struct cdevsw da_cdevsw =
-{
- /*d_open*/ daopen,
- /*d_close*/ daclose,
- /*d_read*/ physread,
- /*d_write*/ physwrite,
- /*d_ioctl*/ daioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ seltrue,
- /*d_mmap*/ nommap,
- /*d_strategy*/ dastrategy,
- /*d_name*/ "da",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ dadump,
- /*d_psize*/ dasize,
- /*d_flags*/ D_DISK,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+static struct cdevsw da_cdevsw = {
+ /* open */ daopen,
+ /* close */ daclose,
+ /* read */ physread,
+ /* write */ physwrite,
+ /* ioctl */ daioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ nopoll,
+ /* mmap */ nommap,
+ /* strategy */ dastrategy,
+ /* name */ "da",
+ /* parms */ noparms,
+ /* maj */ DA_CDEV_MAJOR,
+ /* dump */ dadump,
+ /* psize */ dasize,
+ /* flags */ D_DISK,
+ /* maxio */ 0,
+ /* bmaj */ DA_BDEV_MAJOR
};
static SLIST_HEAD(,da_softc) softc_list;
diff --git a/sys/cam/scsi/scsi_pass.c b/sys/cam/scsi/scsi_pass.c
index 37cdd55..a350c8e 100644
--- a/sys/cam/scsi/scsi_pass.c
+++ b/sys/cam/scsi/scsi_pass.c
@@ -24,7 +24,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: scsi_pass.c,v 1.9 1999/05/09 01:25:30 ken Exp $
+ * $Id: scsi_pass.c,v 1.10 1999/05/22 22:00:21 gibbs Exp $
*/
#include <sys/param.h>
@@ -121,27 +121,26 @@ static struct periph_driver passdriver =
DATA_SET(periphdriver_set, passdriver);
-static struct cdevsw pass_cdevsw =
-{
- /*d_open*/ passopen,
- /*d_close*/ passclose,
- /*d_read*/ physread,
- /*d_write*/ physwrite,
- /*d_ioctl*/ passioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ seltrue,
- /*d_mmap*/ nommap,
- /*d_strategy*/ passstrategy,
- /*d_name*/ "pass",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ nodump,
- /*d_psize*/ nopsize,
- /*d_flags*/ 0,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+static struct cdevsw pass_cdevsw = {
+ /* open */ passopen,
+ /* close */ passclose,
+ /* read */ physread,
+ /* write */ physwrite,
+ /* ioctl */ passioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ nopoll,
+ /* mmap */ nommap,
+ /* strategy */ passstrategy,
+ /* name */ "pass",
+ /* parms */ noparms,
+ /* maj */ PASS_CDEV_MAJOR,
+ /* dump */ nodump,
+ /* psize */ nopsize,
+ /* flags */ 0,
+ /* maxio */ 0,
+ /* bmaj */ -1
};
static struct extend_array *passperiphs;
diff --git a/sys/cam/scsi/scsi_pt.c b/sys/cam/scsi/scsi_pt.c
index f6bba3b..3041591 100644
--- a/sys/cam/scsi/scsi_pt.c
+++ b/sys/cam/scsi/scsi_pt.c
@@ -25,7 +25,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: scsi_pt.c,v 1.7 1999/05/09 01:25:32 ken Exp $
+ * $Id: scsi_pt.c,v 1.8 1999/05/22 22:00:22 gibbs Exp $
*/
#include <sys/param.h>
@@ -112,27 +112,26 @@ DATA_SET(periphdriver_set, ptdriver);
#define PT_CDEV_MAJOR 61
-static struct cdevsw pt_cdevsw =
-{
- /*d_open*/ ptopen,
- /*d_close*/ ptclose,
- /*d_read*/ physread,
- /*d_write*/ physwrite,
- /*d_ioctl*/ noioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ seltrue,
- /*d_mmap*/ nommap,
- /*d_strategy*/ ptstrategy,
- /*d_name*/ "pt",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ nodump,
- /*d_psize*/ nopsize,
- /*d_flags*/ 0,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+static struct cdevsw pt_cdevsw = {
+ /* open */ ptopen,
+ /* close */ ptclose,
+ /* read */ physread,
+ /* write */ physwrite,
+ /* ioctl */ noioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ nopoll,
+ /* mmap */ nommap,
+ /* strategy */ ptstrategy,
+ /* name */ "pt",
+ /* parms */ noparms,
+ /* maj */ PT_CDEV_MAJOR,
+ /* dump */ nodump,
+ /* psize */ nopsize,
+ /* flags */ 0,
+ /* maxio */ 0,
+ /* bmaj */ -1
};
static struct extend_array *ptperiphs;
diff --git a/sys/cam/scsi/scsi_sa.c b/sys/cam/scsi/scsi_sa.c
index 40acfc1..1761055 100644
--- a/sys/cam/scsi/scsi_sa.c
+++ b/sys/cam/scsi/scsi_sa.c
@@ -1,5 +1,5 @@
/*
- * $Id: scsi_sa.c,v 1.25 1999/05/22 22:00:23 gibbs Exp $
+ * $Id: scsi_sa.c,v 1.26 1999/05/25 23:10:54 mjacob Exp $
*
* Implementation of SCSI Sequential Access Peripheral driver for CAM.
*
@@ -340,27 +340,26 @@ DATA_SET(periphdriver_set, sadriver);
#define SA_CDEV_MAJOR 14
#define SA_BDEV_MAJOR 5
-static struct cdevsw sa_cdevsw =
-{
- /*d_open*/ saopen,
- /*d_close*/ saclose,
- /*d_read*/ physread,
- /*d_write*/ physwrite,
- /*d_ioctl*/ saioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ seltrue,
- /*d_mmap*/ nommap,
- /*d_strategy*/ sastrategy,
- /*d_name*/ "sa",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ nodump,
- /*d_psize*/ nopsize,
- /*d_flags*/ D_TAPE,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+static struct cdevsw sa_cdevsw = {
+ /* open */ saopen,
+ /* close */ saclose,
+ /* read */ physread,
+ /* write */ physwrite,
+ /* ioctl */ saioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ nopoll,
+ /* mmap */ nommap,
+ /* strategy */ sastrategy,
+ /* name */ "sa",
+ /* parms */ noparms,
+ /* maj */ SA_CDEV_MAJOR,
+ /* dump */ nodump,
+ /* psize */ nopsize,
+ /* flags */ D_TAPE,
+ /* maxio */ 0,
+ /* bmaj */ SA_BDEV_MAJOR
};
static struct extend_array *saperiphs;
diff --git a/sys/cam/scsi/scsi_target.c b/sys/cam/scsi/scsi_target.c
index 191a991..302e23f 100644
--- a/sys/cam/scsi/scsi_target.c
+++ b/sys/cam/scsi/scsi_target.c
@@ -25,7 +25,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: scsi_target.c,v 1.11 1999/05/07 07:03:03 phk Exp $
+ * $Id: scsi_target.c,v 1.12 1999/05/22 22:00:24 gibbs Exp $
*/
#include <stddef.h> /* For offsetof */
@@ -136,25 +136,25 @@ static d_strategy_t targstrategy;
#define TARG_CDEV_MAJOR 65
static struct cdevsw targ_cdevsw = {
- /*d_open*/ targopen,
- /*d_close*/ targclose,
- /*d_read*/ targread,
- /*d_write*/ targwrite,
- /*d_ioctl*/ targioctl,
- /*d_stop*/ nostop,
- /*d_reset*/ noreset,
- /*d_devtotty*/ nodevtotty,
- /*d_poll*/ targpoll,
- /*d_mmap*/ nommap,
- /*d_strategy*/ targstrategy,
- /*d_name*/ "targ",
- /*d_spare*/ NULL,
- /*d_maj*/ -1,
- /*d_dump*/ nodump,
- /*d_psize*/ nopsize,
- /*d_flags*/ 0,
- /*d_maxio*/ 0,
- /*b_maj*/ -1
+ /* open */ targopen,
+ /* close */ targclose,
+ /* read */ targread,
+ /* write */ targwrite,
+ /* ioctl */ targioctl,
+ /* stop */ nostop,
+ /* reset */ noreset,
+ /* devtotty */ nodevtotty,
+ /* poll */ targpoll,
+ /* mmap */ nommap,
+ /* strategy */ targstrategy,
+ /* name */ "targ",
+ /* parms */ noparms,
+ /* maj */ TARG_CDEV_MAJOR,
+ /* dump */ nodump,
+ /* psize */ nopsize,
+ /* flags */ 0,
+ /* maxio */ 0,
+ /* bmaj */ -1
};
static int targsendccb(struct cam_periph *periph, union ccb *ccb,
OpenPOWER on IntegriCloud