aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/twe
diff options
context:
space:
mode:
authorMateusz Guzik <mjg@FreeBSD.org>2020-09-01 21:31:50 +0000
committerMateusz Guzik <mjg@FreeBSD.org>2020-09-01 21:31:50 +0000
commitb4492420b6bf2a3672f561a57c17fb17e44bf900 (patch)
treefeebd6a50e4f9665ec8ac2e3c9433bf9ed87c84a /sys/dev/twe
parent8644bfdbfa4d9be6d6610c29137b06d72ce4e547 (diff)
downloadsrc-b4492420b6bf2a3672f561a57c17fb17e44bf900.tar.gz
src-b4492420b6bf2a3672f561a57c17fb17e44bf900.zip
twe: clean up empty lines in .c and .h files
Notes
Notes: svn path=/head/; revision=365093
Diffstat (limited to 'sys/dev/twe')
-rw-r--r--sys/dev/twe/twe.c19
-rw-r--r--sys/dev/twe/twe_freebsd.c5
-rw-r--r--sys/dev/twe/tweio.h1
-rw-r--r--sys/dev/twe/twereg.h1
-rw-r--r--sys/dev/twe/twevar.h3
5 files changed, 9 insertions, 20 deletions
diff --git a/sys/dev/twe/twe.c b/sys/dev/twe/twe.c
index 97778ad839b8..389c4c4ac4c4 100644
--- a/sys/dev/twe/twe.c
+++ b/sys/dev/twe/twe.c
@@ -184,10 +184,9 @@ twe_setup(struct twe_softc *sc)
* check for errors, drain the response queue.
*/
for (i = 0; i < TWE_MAX_RESET_TRIES; i++) {
-
if (i > 0)
twe_printf(sc, "reset %d failed, trying again\n", i);
-
+
if (!twe_soft_reset(sc))
break; /* reset process complete */
}
@@ -413,7 +412,6 @@ twe_startio(struct twe_softc *sc)
/* spin until something prevents us from doing any work */
for (;;) {
-
/* try to get a command that's already ready to go */
tr = twe_dequeue_ready(sc);
@@ -447,18 +445,18 @@ twe_startio(struct twe_softc *sc)
biofinish(bp, NULL, EOPNOTSUPP);
break;
}
-
+
/* build a suitable I/O command (assumes 512-byte rounded transfers) */
cmd->io.size = 3;
cmd->io.unit = *(int *)(bp->bio_driver1);
cmd->io.block_count = (tr->tr_length + TWE_BLOCK_SIZE - 1) / TWE_BLOCK_SIZE;
cmd->io.lba = bp->bio_pblkno;
}
-
+
/* did we find something to do? */
if (tr == NULL)
break;
-
+
/* try to map and submit the command to controller */
error = twe_map_request(tr);
@@ -578,7 +576,7 @@ twe_ioctl(struct twe_softc *sc, u_long ioctlcmd, void *addr)
/* copy the command out again */
bcopy(cmd, &tu->tu_command, sizeof(TWE_Command));
-
+
/* if there was a data buffer, copy it out */
if (tr->tr_length > 0)
error = copyout(tr->tr_data, tu->tu_data, tu->tu_size);
@@ -1024,7 +1022,6 @@ twe_completeio(struct twe_request *tr)
debug_called(4);
if (tr->tr_status == TWE_CMD_COMPLETE) {
-
if (cmd->generic.status)
if (twe_report_request(tr)) {
bp->bio_error = EIO;
@@ -1065,10 +1062,9 @@ twe_reset(struct twe_softc *sc)
* Try to soft-reset the controller.
*/
for (i = 0; i < TWE_MAX_RESET_TRIES; i++) {
-
if (i > 0)
twe_printf(sc, "reset %d failed, trying again\n", i);
-
+
if (!twe_soft_reset(sc))
break; /* reset process complete */
}
@@ -1132,7 +1128,6 @@ twe_start(struct twe_request *tr)
* and let the command be rescheduled.
*/
for (i = 100000; (i > 0); i--) {
-
/* check to see if we can post a command */
status_reg = TWE_STATUS(sc);
twe_check_bits(sc, status_reg);
@@ -1541,7 +1536,6 @@ twe_find_aen(struct twe_softc *sc, u_int16_t aen)
return(missing);
}
-
#if 0 /* currently unused */
/********************************************************************************
* Sleep waiting for at least (timeout) seconds until we see (aen) as
@@ -1809,7 +1803,6 @@ twe_format_aen(struct twe_softc *sc, u_int16_t aen)
TWE_AEN_UNIT(aen), msg);
return(sc->twe_aen_buf);
-
case 'x':
default:
break;
diff --git a/sys/dev/twe/twe_freebsd.c b/sys/dev/twe/twe_freebsd.c
index 4886262012a8..ad793eb906f4 100644
--- a/sys/dev/twe/twe_freebsd.c
+++ b/sys/dev/twe/twe_freebsd.c
@@ -709,7 +709,7 @@ twed_open(struct disk *dp)
struct twed_softc *sc = (struct twed_softc *)dp->d_drv1;
debug_called(4);
-
+
if (sc == NULL)
return (ENXIO);
@@ -1065,7 +1065,6 @@ twe_map_request(struct twe_request *tr)
* If the command involves data, map that too.
*/
if (tr->tr_data != NULL && ((tr->tr_flags & TWE_CMD_MAPPED) == 0)) {
-
/*
* Data must be 64-byte aligned; allocate a fixup buffer if it's not.
*/
@@ -1079,7 +1078,7 @@ twe_map_request(struct twe_request *tr)
return(ENOMEM);
}
}
-
+
/*
* Map the data buffer into bus space and build the s/g list.
*/
diff --git a/sys/dev/twe/tweio.h b/sys/dev/twe/tweio.h
index 5946360073d6..e2fa72932501 100644
--- a/sys/dev/twe/tweio.h
+++ b/sys/dev/twe/tweio.h
@@ -31,7 +31,6 @@
* $FreeBSD$
*/
-
/*
* User-space command
*
diff --git a/sys/dev/twe/twereg.h b/sys/dev/twe/twereg.h
index 5397ad92e7d8..d07135f5a83e 100644
--- a/sys/dev/twe/twereg.h
+++ b/sys/dev/twe/twereg.h
@@ -494,4 +494,3 @@ typedef struct
u_int8_t parameter_size_bytes;
u_int8_t data[0];
} __packed TWE_Param;
-
diff --git a/sys/dev/twe/twevar.h b/sys/dev/twe/twevar.h
index 9512f7921e15..bb7c28e874e5 100644
--- a/sys/dev/twe/twevar.h
+++ b/sys/dev/twe/twevar.h
@@ -108,7 +108,7 @@ struct twe_request
((tr)->tr_tag * sizeof(TWE_Command)))
#define TWE_FIND_COMMANDPHYS(tr) ((tr)->tr_sc->twe_cmdphys + \
((tr)->tr_tag * sizeof(TWE_Command)))
-
+
/*
* Per-controller state.
*/
@@ -202,7 +202,6 @@ extern void twe_unmap_request(struct twe_request *tr); /* cleanup after transfer
sc->twe_qstat[qname].q_min = 0xFFFFFFFF; \
} while(0)
-
#define TWEQ_REQUEST_QUEUE(name, index) \
static __inline void \
twe_initq_ ## name (struct twe_softc *sc) \