From c4a034ff8debecd0fd480a753564a0a2248f0436 Mon Sep 17 00:00:00 2001 From: marius Date: Thu, 30 May 2013 00:11:22 +0000 Subject: [PATCH] - Remove pointless returns. - Make cm_data a void pointer and cm_flags unsigned as appropriate. MFC after: 3 days --- sys/dev/aac/aac.c | 9 --------- sys/dev/aac/aac_cam.c | 6 ------ sys/dev/aac/aac_disk.c | 2 -- sys/dev/aac/aacvar.h | 6 +++--- 4 files changed, 3 insertions(+), 20 deletions(-) diff --git a/sys/dev/aac/aac.c b/sys/dev/aac/aac.c index d4c73836eca5..3ceda4789ac2 100644 --- a/sys/dev/aac/aac.c +++ b/sys/dev/aac/aac.c @@ -379,8 +379,6 @@ aac_add_event(struct aac_softc *sc, struct aac_event *event) event->ev_type); break; } - - return; } /* @@ -1631,8 +1629,6 @@ aac_map_command_sg(void *arg, bus_dma_segment_t *segs, int nseg, int error) aac_requeue_ready(cm); } } - - return; } /* @@ -2362,7 +2358,6 @@ aac_timeout(struct aac_softc *sc) "longer running! code= 0x%x\n", code); } } - return; } /* @@ -3372,8 +3367,6 @@ aac_handle_aif(struct aac_softc *sc, struct aac_fib *fib) /* Wakeup any poll()ers */ selwakeuppri(&sc->rcv_select, PRIBIO); mtx_unlock(&sc->aac_aifq_lock); - - return; } /* @@ -3788,6 +3781,4 @@ aac_get_bus_info(struct aac_softc *sc) if (found) bus_generic_attach(sc->aac_dev); - - return; } diff --git a/sys/dev/aac/aac_cam.c b/sys/dev/aac/aac_cam.c index f117bad2c284..8ec26aa1080e 100644 --- a/sys/dev/aac/aac_cam.c +++ b/sys/dev/aac/aac_cam.c @@ -163,8 +163,6 @@ aac_cam_event(struct aac_softc *sc, struct aac_event *event, void *arg) event->ev_type); break; } - - return; } static int @@ -515,8 +513,6 @@ aac_cam_action(struct cam_sim *sim, union ccb *ccb) aac_enqueue_ready(cm); aac_startio(cm->cm_sc); - - return; } static void @@ -625,8 +621,6 @@ aac_cam_complete(struct aac_command *cm) aac_release_command(cm); xpt_done(ccb); - - return; } static u_int32_t diff --git a/sys/dev/aac/aac_disk.c b/sys/dev/aac/aac_disk.c index 082be9b4ca71..fd89f5e573f5 100644 --- a/sys/dev/aac/aac_disk.c +++ b/sys/dev/aac/aac_disk.c @@ -167,8 +167,6 @@ aac_disk_strategy(struct bio *bp) mtx_lock(&sc->ad_controller->aac_io_lock); aac_submit_bio(bp); mtx_unlock(&sc->ad_controller->aac_io_lock); - - return; } /* diff --git a/sys/dev/aac/aacvar.h b/sys/dev/aac/aacvar.h index 6dc779507d97..f856234e270d 100644 --- a/sys/dev/aac/aacvar.h +++ b/sys/dev/aac/aacvar.h @@ -158,13 +158,13 @@ struct aac_command struct aac_fib *cm_fib; /* FIB associated with this * command */ u_int64_t cm_fibphys; /* bus address of the FIB */ - struct bio *cm_data; /* pointer to data in kernel + void *cm_data; /* pointer to data in kernel * space */ u_int32_t cm_datalen; /* data length */ bus_dmamap_t cm_datamap; /* DMA map for bio data */ struct aac_sg_table *cm_sgtable; /* pointer to s/g table in * command */ - int cm_flags; + u_int cm_flags; #define AAC_CMD_MAPPED (1<<0) /* command has had its data * mapped */ #define AAC_CMD_DATAIN (1<<1) /* command involves data moving @@ -182,7 +182,7 @@ struct aac_command #define AAC_QUEUE_FRZN (1<<9) /* Freeze the processing of * commands on the queue. */ - void (* cm_complete)(struct aac_command *cm); + void (*cm_complete)(struct aac_command *cm); void *cm_private; time_t cm_timestamp; /* command creation time */ int cm_queue;