diff options
author | 2011-12-25 15:28:17 +0000 | |
---|---|---|
committer | 2011-12-25 15:28:17 +0000 | |
commit | 5c66ec229d4db7f40620903a3e0219159e7f968b (patch) | |
tree | 45dd668be83fa4f3f86584800edf4c70eefdb4f9 /sys/dev/softraid_raid0.c | |
parent | Move chunk state debugging code to a more useful location. (diff) | |
download | wireguard-openbsd-5c66ec229d4db7f40620903a3e0219159e7f968b.tar.xz wireguard-openbsd-5c66ec229d4db7f40620903a3e0219159e7f968b.zip |
Initialise discipline function pointers with defaults and only override
those that are needed by a specific discipline.
Diffstat (limited to 'sys/dev/softraid_raid0.c')
-rw-r--r-- | sys/dev/softraid_raid0.c | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/sys/dev/softraid_raid0.c b/sys/dev/softraid_raid0.c index 5f2bcc0c35e..b36303eb73e 100644 --- a/sys/dev/softraid_raid0.c +++ b/sys/dev/softraid_raid0.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raid0.c,v 1.23 2011/04/05 19:52:02 krw Exp $ */ +/* $OpenBSD: softraid_raid0.c,v 1.24 2011/12/25 15:28:17 jsing Exp $ */ /* * Copyright (c) 2008 Marco Peereboom <marco@peereboom.us> * @@ -65,18 +65,11 @@ sr_raid0_discipline_init(struct sr_discipline *sd) sd->sd_capabilities = SR_CAP_SYSTEM_DISK | SR_CAP_AUTO_ASSEMBLE; sd->sd_max_wu = SR_RAID0_NOWU; - /* Setup discipline pointers. */ - sd->sd_create = sr_raid0_create; - sd->sd_assemble = sr_raid0_assemble; + /* Setup discipline specific function pointers. */ sd->sd_alloc_resources = sr_raid0_alloc_resources; + sd->sd_assemble = sr_raid0_assemble; + sd->sd_create = sr_raid0_create; sd->sd_free_resources = sr_raid0_free_resources; - sd->sd_start_discipline = NULL; - sd->sd_scsi_inquiry = sr_raid_inquiry; - sd->sd_scsi_read_cap = sr_raid_read_cap; - sd->sd_scsi_tur = sr_raid_tur; - sd->sd_scsi_req_sense = sr_raid_request_sense; - sd->sd_scsi_start_stop = sr_raid_start_stop; - sd->sd_scsi_sync = sr_raid_sync; sd->sd_scsi_rw = sr_raid0_rw; sd->sd_set_chunk_state = sr_raid0_set_chunk_state; sd->sd_set_vol_state = sr_raid0_set_vol_state; |