diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2007-03-19 22:33:16 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2007-03-19 22:33:16 +0000 |
commit | 3b3a02b67165b90081d3c812486a8031a57d4e28 (patch) | |
tree | 9f67bdbef85194414b97c8d73c1928f89b4d6b6f /sys | |
parent | 6959a55360e2b6bae717308b4589fa5ddfda3bf1 (diff) |
the autoconf glue funcs (match/attach/etc) are only used inside softraid.c,
so prototype them there rather than in softraidvar.h.
shuffle these funcs a little bit while here to make it look more like
everything else.
ok marco@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/softraid.c | 38 | ||||
-rw-r--r-- | sys/dev/softraidvar.h | 7 |
2 files changed, 21 insertions, 24 deletions
diff --git a/sys/dev/softraid.c b/sys/dev/softraid.c index 298989f19a1..8e7fa40bc8e 100644 --- a/sys/dev/softraid.c +++ b/sys/dev/softraid.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid.c,v 1.3 2007/03/19 15:00:08 mk Exp $ */ +/* $OpenBSD: softraid.c,v 1.4 2007/03/19 22:33:15 dlg Exp $ */ /* * Copyright (c) 2007 Marco Peereboom <marco@peereboom.us> * @@ -59,11 +59,13 @@ uint32_t sr_debug = 0 ; #endif +int sr_match(struct device *, void *, void *); +void sr_attach(struct device *, struct device *, void *); +int sr_detach(struct device *, int); +int sr_activate(struct device *, enum devact); + struct cfattach softraid_ca = { - sizeof(struct sr_softc), - sr_probe, - sr_attach, - sr_detach, + sizeof(struct sr_softc), sr_match, sr_attach, sr_detach, sr_activate }; @@ -120,19 +122,7 @@ struct scsi_device sr_dev = { }; int -sr_probe(struct device *parent, void *match, void *aux) -{ - return (1); -} - -int -sr_detach(struct device *self, int flags) -{ - return (0); -} - -int -sr_activate(struct device *self, enum devact act) +sr_match(struct device *parent, void *match, void *aux) { return (1); } @@ -154,6 +144,18 @@ sr_attach(struct device *parent, struct device *self, void *aux) printf("\n"); } +int +sr_detach(struct device *self, int flags) +{ + return (0); +} + +int +sr_activate(struct device *self, enum devact act) +{ + return (1); +} + void sr_minphys(struct buf *bp) { diff --git a/sys/dev/softraidvar.h b/sys/dev/softraidvar.h index b87e6eaea82..313f28b5b19 100644 --- a/sys/dev/softraidvar.h +++ b/sys/dev/softraidvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: softraidvar.h,v 1.2 2007/03/19 14:33:28 dlg Exp $ */ +/* $OpenBSD: softraidvar.h,v 1.3 2007/03/19 22:33:15 dlg Exp $ */ /* * Copyright (c) 2006 Marco Peereboom <sro@peereboom.us> * @@ -252,8 +252,3 @@ struct sr_softc { #define SR_MAXSCSIBUS 256 struct sr_discipline *sc_dis[SR_MAXSCSIBUS]; /* scsibus is u_int8_t */ }; - -int sr_probe(struct device *, void *, void *); -void sr_attach(struct device *, struct device *, void *); -int sr_detach(struct device *, int); -int sr_activate(struct device *, enum devact); |