summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/usb/ehci.c274
-rw-r--r--sys/dev/usb/hid.c6
-rw-r--r--sys/dev/usb/if_aue.c144
-rw-r--r--sys/dev/usb/if_axe.c108
-rw-r--r--sys/dev/usb/if_cdce.c50
-rw-r--r--sys/dev/usb/if_cue.c96
-rw-r--r--sys/dev/usb/if_kue.c76
-rw-r--r--sys/dev/usb/if_ral.c196
-rw-r--r--sys/dev/usb/if_rum.c202
-rw-r--r--sys/dev/usb/if_uath.c194
-rw-r--r--sys/dev/usb/if_udav.c130
-rw-r--r--sys/dev/usb/if_upl.c66
-rw-r--r--sys/dev/usb/if_url.c130
-rw-r--r--sys/dev/usb/moscom.c22
-rw-r--r--sys/dev/usb/ohci.c256
-rw-r--r--sys/dev/usb/uark.c18
-rw-r--r--sys/dev/usb/uaudio.c244
-rw-r--r--sys/dev/usb/uberry.c6
-rw-r--r--sys/dev/usb/ubsa.c66
-rw-r--r--sys/dev/usb/ucom.c64
-rw-r--r--sys/dev/usb/ucycom.c34
-rw-r--r--sys/dev/usb/udsbr.c16
-rw-r--r--sys/dev/usb/ueagle.c108
-rw-r--r--sys/dev/usb/uftdi.c30
-rw-r--r--sys/dev/usb/ugen.c56
-rw-r--r--sys/dev/usb/uhci.c206
-rw-r--r--sys/dev/usb/uhid.c22
-rw-r--r--sys/dev/usb/uhidev.c12
-rw-r--r--sys/dev/usb/uhub.c6
-rw-r--r--sys/dev/usb/uipaq.c10
-rw-r--r--sys/dev/usb/ukbd.c26
-rw-r--r--sys/dev/usb/umass.c70
-rw-r--r--sys/dev/usb/umass_quirks.c20
-rw-r--r--sys/dev/usb/umct.c30
-rw-r--r--sys/dev/usb/umodem.c38
-rw-r--r--sys/dev/usb/ums.c16
-rw-r--r--sys/dev/usb/uow.c54
-rw-r--r--sys/dev/usb/uplcom.c32
-rw-r--r--sys/dev/usb/usb.c44
-rw-r--r--sys/dev/usb/usb_mem.c16
-rw-r--r--sys/dev/usb/usb_port.h4
-rw-r--r--sys/dev/usb/usb_quirks.c4
-rw-r--r--sys/dev/usb/usb_subr.c30
-rw-r--r--sys/dev/usb/usbdi.c14
-rw-r--r--sys/dev/usb/usbdi_util.c10
-rw-r--r--sys/dev/usb/uscanner.c18
-rw-r--r--sys/dev/usb/uslcom.c22
-rw-r--r--sys/dev/usb/usscanner.c44
-rw-r--r--sys/dev/usb/uts.c20
-rw-r--r--sys/dev/usb/uvisor.c6
-rw-r--r--sys/dev/usb/uvscom.c64
51 files changed, 1714 insertions, 1716 deletions
diff --git a/sys/dev/usb/ehci.c b/sys/dev/usb/ehci.c
index d0eb775b314..5b1c325871d 100644
--- a/sys/dev/usb/ehci.c
+++ b/sys/dev/usb/ehci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ehci.c,v 1.70 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: ehci.c,v 1.71 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: ehci.c,v 1.66 2004/06/30 03:11:56 mycroft Exp $ */
/*
@@ -129,108 +129,108 @@ struct ehci_pipe {
} u;
};
-Static u_int8_t ehci_reverse_bits(u_int8_t, int);
-
-Static void ehci_power(int, void *);
-
-Static usbd_status ehci_open(usbd_pipe_handle);
-Static void ehci_poll(struct usbd_bus *);
-Static void ehci_softintr(void *);
-Static int ehci_intr1(ehci_softc_t *);
-Static void ehci_waitintr(ehci_softc_t *, usbd_xfer_handle);
-Static void ehci_check_intr(ehci_softc_t *, struct ehci_xfer *);
-Static void ehci_idone(struct ehci_xfer *);
-Static void ehci_timeout(void *);
-Static void ehci_timeout_task(void *);
-Static void ehci_intrlist_timeout(void *);
-
-Static usbd_status ehci_allocm(struct usbd_bus *, usb_dma_t *, u_int32_t);
-Static void ehci_freem(struct usbd_bus *, usb_dma_t *);
-
-Static usbd_xfer_handle ehci_allocx(struct usbd_bus *);
-Static void ehci_freex(struct usbd_bus *, usbd_xfer_handle);
-
-Static usbd_status ehci_root_ctrl_transfer(usbd_xfer_handle);
-Static usbd_status ehci_root_ctrl_start(usbd_xfer_handle);
-Static void ehci_root_ctrl_abort(usbd_xfer_handle);
-Static void ehci_root_ctrl_close(usbd_pipe_handle);
-Static void ehci_root_ctrl_done(usbd_xfer_handle);
-
-Static usbd_status ehci_root_intr_transfer(usbd_xfer_handle);
-Static usbd_status ehci_root_intr_start(usbd_xfer_handle);
-Static void ehci_root_intr_abort(usbd_xfer_handle);
-Static void ehci_root_intr_close(usbd_pipe_handle);
-Static void ehci_root_intr_done(usbd_xfer_handle);
-
-Static usbd_status ehci_device_ctrl_transfer(usbd_xfer_handle);
-Static usbd_status ehci_device_ctrl_start(usbd_xfer_handle);
-Static void ehci_device_ctrl_abort(usbd_xfer_handle);
-Static void ehci_device_ctrl_close(usbd_pipe_handle);
-Static void ehci_device_ctrl_done(usbd_xfer_handle);
-
-Static usbd_status ehci_device_bulk_transfer(usbd_xfer_handle);
-Static usbd_status ehci_device_bulk_start(usbd_xfer_handle);
-Static void ehci_device_bulk_abort(usbd_xfer_handle);
-Static void ehci_device_bulk_close(usbd_pipe_handle);
-Static void ehci_device_bulk_done(usbd_xfer_handle);
-
-Static usbd_status ehci_device_intr_transfer(usbd_xfer_handle);
-Static usbd_status ehci_device_intr_start(usbd_xfer_handle);
-Static void ehci_device_intr_abort(usbd_xfer_handle);
-Static void ehci_device_intr_close(usbd_pipe_handle);
-Static void ehci_device_intr_done(usbd_xfer_handle);
-
-Static usbd_status ehci_device_isoc_transfer(usbd_xfer_handle);
-Static usbd_status ehci_device_isoc_start(usbd_xfer_handle);
-Static void ehci_device_isoc_abort(usbd_xfer_handle);
-Static void ehci_device_isoc_close(usbd_pipe_handle);
-Static void ehci_device_isoc_done(usbd_xfer_handle);
-
-Static void ehci_device_clear_toggle(usbd_pipe_handle pipe);
-Static void ehci_noop(usbd_pipe_handle pipe);
-
-Static int ehci_str(usb_string_descriptor_t *, int, const char *);
-Static void ehci_pcd(ehci_softc_t *, usbd_xfer_handle);
-Static void ehci_pcd_able(ehci_softc_t *, int);
-Static void ehci_pcd_enable(void *);
-Static void ehci_disown(ehci_softc_t *, int, int);
-
-Static ehci_soft_qh_t *ehci_alloc_sqh(ehci_softc_t *);
-Static void ehci_free_sqh(ehci_softc_t *, ehci_soft_qh_t *);
-
-Static ehci_soft_qtd_t *ehci_alloc_sqtd(ehci_softc_t *);
-Static void ehci_free_sqtd(ehci_softc_t *, ehci_soft_qtd_t *);
-Static usbd_status ehci_alloc_sqtd_chain(struct ehci_pipe *,
+u_int8_t ehci_reverse_bits(u_int8_t, int);
+
+void ehci_power(int, void *);
+
+usbd_status ehci_open(usbd_pipe_handle);
+void ehci_poll(struct usbd_bus *);
+void ehci_softintr(void *);
+int ehci_intr1(ehci_softc_t *);
+void ehci_waitintr(ehci_softc_t *, usbd_xfer_handle);
+void ehci_check_intr(ehci_softc_t *, struct ehci_xfer *);
+void ehci_idone(struct ehci_xfer *);
+void ehci_timeout(void *);
+void ehci_timeout_task(void *);
+void ehci_intrlist_timeout(void *);
+
+usbd_status ehci_allocm(struct usbd_bus *, usb_dma_t *, u_int32_t);
+void ehci_freem(struct usbd_bus *, usb_dma_t *);
+
+usbd_xfer_handle ehci_allocx(struct usbd_bus *);
+void ehci_freex(struct usbd_bus *, usbd_xfer_handle);
+
+usbd_status ehci_root_ctrl_transfer(usbd_xfer_handle);
+usbd_status ehci_root_ctrl_start(usbd_xfer_handle);
+void ehci_root_ctrl_abort(usbd_xfer_handle);
+void ehci_root_ctrl_close(usbd_pipe_handle);
+void ehci_root_ctrl_done(usbd_xfer_handle);
+
+usbd_status ehci_root_intr_transfer(usbd_xfer_handle);
+usbd_status ehci_root_intr_start(usbd_xfer_handle);
+void ehci_root_intr_abort(usbd_xfer_handle);
+void ehci_root_intr_close(usbd_pipe_handle);
+void ehci_root_intr_done(usbd_xfer_handle);
+
+usbd_status ehci_device_ctrl_transfer(usbd_xfer_handle);
+usbd_status ehci_device_ctrl_start(usbd_xfer_handle);
+void ehci_device_ctrl_abort(usbd_xfer_handle);
+void ehci_device_ctrl_close(usbd_pipe_handle);
+void ehci_device_ctrl_done(usbd_xfer_handle);
+
+usbd_status ehci_device_bulk_transfer(usbd_xfer_handle);
+usbd_status ehci_device_bulk_start(usbd_xfer_handle);
+void ehci_device_bulk_abort(usbd_xfer_handle);
+void ehci_device_bulk_close(usbd_pipe_handle);
+void ehci_device_bulk_done(usbd_xfer_handle);
+
+usbd_status ehci_device_intr_transfer(usbd_xfer_handle);
+usbd_status ehci_device_intr_start(usbd_xfer_handle);
+void ehci_device_intr_abort(usbd_xfer_handle);
+void ehci_device_intr_close(usbd_pipe_handle);
+void ehci_device_intr_done(usbd_xfer_handle);
+
+usbd_status ehci_device_isoc_transfer(usbd_xfer_handle);
+usbd_status ehci_device_isoc_start(usbd_xfer_handle);
+void ehci_device_isoc_abort(usbd_xfer_handle);
+void ehci_device_isoc_close(usbd_pipe_handle);
+void ehci_device_isoc_done(usbd_xfer_handle);
+
+void ehci_device_clear_toggle(usbd_pipe_handle pipe);
+void ehci_noop(usbd_pipe_handle pipe);
+
+int ehci_str(usb_string_descriptor_t *, int, const char *);
+void ehci_pcd(ehci_softc_t *, usbd_xfer_handle);
+void ehci_pcd_able(ehci_softc_t *, int);
+void ehci_pcd_enable(void *);
+void ehci_disown(ehci_softc_t *, int, int);
+
+ehci_soft_qh_t *ehci_alloc_sqh(ehci_softc_t *);
+void ehci_free_sqh(ehci_softc_t *, ehci_soft_qh_t *);
+
+ehci_soft_qtd_t *ehci_alloc_sqtd(ehci_softc_t *);
+void ehci_free_sqtd(ehci_softc_t *, ehci_soft_qtd_t *);
+usbd_status ehci_alloc_sqtd_chain(struct ehci_pipe *,
ehci_softc_t *, int, int, usbd_xfer_handle,
ehci_soft_qtd_t **, ehci_soft_qtd_t **);
-Static void ehci_free_sqtd_chain(ehci_softc_t *, ehci_soft_qtd_t *,
+void ehci_free_sqtd_chain(ehci_softc_t *, ehci_soft_qtd_t *,
ehci_soft_qtd_t *);
-Static usbd_status ehci_device_request(usbd_xfer_handle xfer);
+usbd_status ehci_device_request(usbd_xfer_handle xfer);
-Static usbd_status ehci_device_setintr(ehci_softc_t *, ehci_soft_qh_t *,
+usbd_status ehci_device_setintr(ehci_softc_t *, ehci_soft_qh_t *,
int ival);
-Static void ehci_add_qh(ehci_soft_qh_t *, ehci_soft_qh_t *);
-Static void ehci_rem_qh(ehci_softc_t *, ehci_soft_qh_t *,
+void ehci_add_qh(ehci_soft_qh_t *, ehci_soft_qh_t *);
+void ehci_rem_qh(ehci_softc_t *, ehci_soft_qh_t *,
ehci_soft_qh_t *);
-Static void ehci_set_qh_qtd(ehci_soft_qh_t *, ehci_soft_qtd_t *);
-Static void ehci_sync_hc(ehci_softc_t *);
+void ehci_set_qh_qtd(ehci_soft_qh_t *, ehci_soft_qtd_t *);
+void ehci_sync_hc(ehci_softc_t *);
-Static void ehci_close_pipe(usbd_pipe_handle, ehci_soft_qh_t *);
-Static void ehci_abort_xfer(usbd_xfer_handle, usbd_status);
+void ehci_close_pipe(usbd_pipe_handle, ehci_soft_qh_t *);
+void ehci_abort_xfer(usbd_xfer_handle, usbd_status);
#ifdef EHCI_DEBUG
-Static void ehci_dump_regs(ehci_softc_t *);
-Static void ehci_dump(void);
-Static ehci_softc_t *theehci;
-Static void ehci_dump_link(ehci_link_t, int);
-Static void ehci_dump_sqtds(ehci_soft_qtd_t *);
-Static void ehci_dump_sqtd(ehci_soft_qtd_t *);
-Static void ehci_dump_qtd(ehci_qtd_t *);
-Static void ehci_dump_sqh(ehci_soft_qh_t *);
+void ehci_dump_regs(ehci_softc_t *);
+void ehci_dump(void);
+ehci_softc_t *theehci;
+void ehci_dump_link(ehci_link_t, int);
+void ehci_dump_sqtds(ehci_soft_qtd_t *);
+void ehci_dump_sqtd(ehci_soft_qtd_t *);
+void ehci_dump_qtd(ehci_qtd_t *);
+void ehci_dump_sqh(ehci_soft_qh_t *);
#ifdef DIAGNOSTIC
-Static void ehci_dump_exfer(struct ehci_xfer *);
+void ehci_dump_exfer(struct ehci_xfer *);
#endif
#endif
@@ -247,7 +247,7 @@ Static void ehci_dump_exfer(struct ehci_xfer *);
} while (0)
#define ehci_active_intr_list(ex) ((ex)->inext.le_prev != NULL)
-Static struct usbd_bus_methods ehci_bus_methods = {
+struct usbd_bus_methods ehci_bus_methods = {
ehci_open,
ehci_softintr,
ehci_poll,
@@ -257,7 +257,7 @@ Static struct usbd_bus_methods ehci_bus_methods = {
ehci_freex,
};
-Static struct usbd_pipe_methods ehci_root_ctrl_methods = {
+struct usbd_pipe_methods ehci_root_ctrl_methods = {
ehci_root_ctrl_transfer,
ehci_root_ctrl_start,
ehci_root_ctrl_abort,
@@ -266,7 +266,7 @@ Static struct usbd_pipe_methods ehci_root_ctrl_methods = {
ehci_root_ctrl_done,
};
-Static struct usbd_pipe_methods ehci_root_intr_methods = {
+struct usbd_pipe_methods ehci_root_intr_methods = {
ehci_root_intr_transfer,
ehci_root_intr_start,
ehci_root_intr_abort,
@@ -275,7 +275,7 @@ Static struct usbd_pipe_methods ehci_root_intr_methods = {
ehci_root_intr_done,
};
-Static struct usbd_pipe_methods ehci_device_ctrl_methods = {
+struct usbd_pipe_methods ehci_device_ctrl_methods = {
ehci_device_ctrl_transfer,
ehci_device_ctrl_start,
ehci_device_ctrl_abort,
@@ -284,7 +284,7 @@ Static struct usbd_pipe_methods ehci_device_ctrl_methods = {
ehci_device_ctrl_done,
};
-Static struct usbd_pipe_methods ehci_device_intr_methods = {
+struct usbd_pipe_methods ehci_device_intr_methods = {
ehci_device_intr_transfer,
ehci_device_intr_start,
ehci_device_intr_abort,
@@ -293,7 +293,7 @@ Static struct usbd_pipe_methods ehci_device_intr_methods = {
ehci_device_intr_done,
};
-Static struct usbd_pipe_methods ehci_device_bulk_methods = {
+struct usbd_pipe_methods ehci_device_bulk_methods = {
ehci_device_bulk_transfer,
ehci_device_bulk_start,
ehci_device_bulk_abort,
@@ -302,7 +302,7 @@ Static struct usbd_pipe_methods ehci_device_bulk_methods = {
ehci_device_bulk_done,
};
-Static struct usbd_pipe_methods ehci_device_isoc_methods = {
+struct usbd_pipe_methods ehci_device_isoc_methods = {
ehci_device_isoc_transfer,
ehci_device_isoc_start,
ehci_device_isoc_abort,
@@ -316,7 +316,7 @@ Static struct usbd_pipe_methods ehci_device_isoc_methods = {
* interrupt heads in the periodic schedule.
* Suitable for use with EHCI_IPOLLRATES <= 9.
*/
-Static u_int8_t
+u_int8_t
ehci_reverse_bits(u_int8_t c, int nbits)
{
c = ((c >> 1) & 0x55) | ((c << 1) & 0xaa);
@@ -531,7 +531,7 @@ ehci_intr(void *v)
return (ehci_intr1(sc));
}
-Static int
+int
ehci_intr1(ehci_softc_t *sc)
{
u_int32_t intrs, eintrs;
@@ -1144,7 +1144,7 @@ ehci_freex(struct usbd_bus *bus, usbd_xfer_handle xfer)
SIMPLEQ_INSERT_HEAD(&sc->sc_free_xfers, xfer, next);
}
-Static void
+void
ehci_device_clear_toggle(usbd_pipe_handle pipe)
{
struct ehci_pipe *epipe = (struct ehci_pipe *)pipe;
@@ -1162,7 +1162,7 @@ ehci_device_clear_toggle(usbd_pipe_handle pipe)
epipe->sqh->qh.qh_qtd.qtd_status &= htole32(~EHCI_QTD_TOGGLE_MASK);
}
-Static void
+void
ehci_noop(usbd_pipe_handle pipe)
{
}
@@ -1291,7 +1291,7 @@ ehci_dump_sqh(ehci_soft_qh_t *sqh)
}
#ifdef DIAGNOSTIC
-Static void
+void
ehci_dump_exfer(struct ehci_xfer *ex)
{
printf("ehci_dump_exfer: ex=%p\n", ex);
@@ -1539,7 +1539,7 @@ ehci_sync_hc(ehci_softc_t *sc)
/*
* Data structures and routines to emulate the root hub.
*/
-Static usb_device_descriptor_t ehci_devd = {
+usb_device_descriptor_t ehci_devd = {
USB_DEVICE_DESCRIPTOR_SIZE,
UDESC_DEVICE, /* type */
{0x00, 0x02}, /* USB version */
@@ -1552,7 +1552,7 @@ Static usb_device_descriptor_t ehci_devd = {
1 /* # of configurations */
};
-Static usb_device_qualifier_t ehci_odevd = {
+usb_device_qualifier_t ehci_odevd = {
USB_DEVICE_DESCRIPTOR_SIZE,
UDESC_DEVICE_QUALIFIER, /* type */
{0x00, 0x02}, /* USB version */
@@ -1564,7 +1564,7 @@ Static usb_device_qualifier_t ehci_odevd = {
0
};
-Static usb_config_descriptor_t ehci_confd = {
+usb_config_descriptor_t ehci_confd = {
USB_CONFIG_DESCRIPTOR_SIZE,
UDESC_CONFIG,
{USB_CONFIG_DESCRIPTOR_SIZE +
@@ -1577,7 +1577,7 @@ Static usb_config_descriptor_t ehci_confd = {
0 /* max power */
};
-Static usb_interface_descriptor_t ehci_ifcd = {
+usb_interface_descriptor_t ehci_ifcd = {
USB_INTERFACE_DESCRIPTOR_SIZE,
UDESC_INTERFACE,
0,
@@ -1589,7 +1589,7 @@ Static usb_interface_descriptor_t ehci_ifcd = {
0
};
-Static usb_endpoint_descriptor_t ehci_endpd = {
+usb_endpoint_descriptor_t ehci_endpd = {
USB_ENDPOINT_DESCRIPTOR_SIZE,
UDESC_ENDPOINT,
UE_DIR_IN | EHCI_INTR_ENDPT,
@@ -1598,7 +1598,7 @@ Static usb_endpoint_descriptor_t ehci_endpd = {
255
};
-Static usb_hub_descriptor_t ehci_hubd = {
+usb_hub_descriptor_t ehci_hubd = {
USB_HUB_DESCRIPTOR_SIZE,
UDESC_HUB,
0,
@@ -1608,7 +1608,7 @@ Static usb_hub_descriptor_t ehci_hubd = {
{0},
};
-Static int
+int
ehci_str(usb_string_descriptor_t *p, int l, const char *s)
{
int i;
@@ -1628,7 +1628,7 @@ ehci_str(usb_string_descriptor_t *p, int l, const char *s)
/*
* Simulate a hardware hub by handling all the necessary requests.
*/
-Static usbd_status
+usbd_status
ehci_root_ctrl_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -1642,7 +1642,7 @@ ehci_root_ctrl_transfer(usbd_xfer_handle xfer)
return (ehci_root_ctrl_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ehci_root_ctrl_start(usbd_xfer_handle xfer)
{
ehci_softc_t *sc = (ehci_softc_t *)xfer->pipe->device->bus;
@@ -2043,14 +2043,14 @@ ehci_disown(ehci_softc_t *sc, int index, int lowspeed)
}
/* Abort a root control request. */
-Static void
+void
ehci_root_ctrl_abort(usbd_xfer_handle xfer)
{
/* Nothing to do, all transfers are synchronous. */
}
/* Close the root pipe. */
-Static void
+void
ehci_root_ctrl_close(usbd_pipe_handle pipe)
{
DPRINTF(("ehci_root_ctrl_close\n"));
@@ -2062,7 +2062,7 @@ ehci_root_intr_done(usbd_xfer_handle xfer)
{
}
-Static usbd_status
+usbd_status
ehci_root_intr_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2076,7 +2076,7 @@ ehci_root_intr_transfer(usbd_xfer_handle xfer)
return (ehci_root_intr_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ehci_root_intr_start(usbd_xfer_handle xfer)
{
usbd_pipe_handle pipe = xfer->pipe;
@@ -2091,7 +2091,7 @@ ehci_root_intr_start(usbd_xfer_handle xfer)
}
/* Abort a root interrupt request. */
-Static void
+void
ehci_root_intr_abort(usbd_xfer_handle xfer)
{
int s;
@@ -2107,7 +2107,7 @@ ehci_root_intr_abort(usbd_xfer_handle xfer)
}
/* Close the root pipe. */
-Static void
+void
ehci_root_intr_close(usbd_pipe_handle pipe)
{
ehci_softc_t *sc = (ehci_softc_t *)pipe->device->bus;
@@ -2357,7 +2357,7 @@ ehci_alloc_sqtd_chain(struct ehci_pipe *epipe, ehci_softc_t *sc, int alen,
return (USBD_NOMEM);
}
-Static void
+void
ehci_free_sqtd_chain(ehci_softc_t *sc, ehci_soft_qtd_t *sqtd,
ehci_soft_qtd_t *sqtdend)
{
@@ -2661,7 +2661,7 @@ ehci_intrlist_timeout(void *arg)
/************************/
-Static usbd_status
+usbd_status
ehci_device_ctrl_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2675,7 +2675,7 @@ ehci_device_ctrl_transfer(usbd_xfer_handle xfer)
return (ehci_device_ctrl_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ehci_device_ctrl_start(usbd_xfer_handle xfer)
{
ehci_softc_t *sc = (ehci_softc_t *)xfer->pipe->device->bus;
@@ -2725,7 +2725,7 @@ ehci_device_ctrl_done(usbd_xfer_handle xfer)
}
/* Abort a device control request. */
-Static void
+void
ehci_device_ctrl_abort(usbd_xfer_handle xfer)
{
DPRINTF(("ehci_device_ctrl_abort: xfer=%p\n", xfer));
@@ -2733,7 +2733,7 @@ ehci_device_ctrl_abort(usbd_xfer_handle xfer)
}
/* Close a device control pipe. */
-Static void
+void
ehci_device_ctrl_close(usbd_pipe_handle pipe)
{
ehci_softc_t *sc = (ehci_softc_t *)pipe->device->bus;
@@ -2894,7 +2894,7 @@ ehci_device_request(usbd_xfer_handle xfer)
/************************/
-Static usbd_status
+usbd_status
ehci_device_bulk_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2999,7 +2999,7 @@ ehci_device_bulk_start(usbd_xfer_handle xfer)
#undef exfer
}
-Static void
+void
ehci_device_bulk_abort(usbd_xfer_handle xfer)
{
DPRINTF(("ehci_device_bulk_abort: xfer=%p\n", xfer));
@@ -3009,7 +3009,7 @@ ehci_device_bulk_abort(usbd_xfer_handle xfer)
/*
* Close a device bulk pipe.
*/
-Static void
+void
ehci_device_bulk_close(usbd_pipe_handle pipe)
{
ehci_softc_t *sc = (ehci_softc_t *)pipe->device->bus;
@@ -3038,7 +3038,7 @@ ehci_device_bulk_done(usbd_xfer_handle xfer)
/************************/
-Static usbd_status
+usbd_status
ehci_device_setintr(ehci_softc_t *sc, ehci_soft_qh_t *sqh, int ival)
{
struct ehci_soft_islot *isp;
@@ -3065,7 +3065,7 @@ ehci_device_setintr(ehci_softc_t *sc, ehci_soft_qh_t *sqh, int ival)
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
ehci_device_intr_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -3082,7 +3082,7 @@ ehci_device_intr_transfer(usbd_xfer_handle xfer)
return (ehci_device_intr_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ehci_device_intr_start(usbd_xfer_handle xfer)
{
#define exfer EXFER(xfer)
@@ -3167,7 +3167,7 @@ ehci_device_intr_start(usbd_xfer_handle xfer)
#undef exfer
}
-Static void
+void
ehci_device_intr_abort(usbd_xfer_handle xfer)
{
DPRINTFN(1, ("ehci_device_intr_abort: xfer=%p\n", xfer));
@@ -3178,7 +3178,7 @@ ehci_device_intr_abort(usbd_xfer_handle xfer)
ehci_abort_xfer(xfer, USBD_CANCELLED);
}
-Static void
+void
ehci_device_intr_close(usbd_pipe_handle pipe)
{
ehci_softc_t *sc = (ehci_softc_t *)pipe->device->bus;
@@ -3189,7 +3189,7 @@ ehci_device_intr_close(usbd_pipe_handle pipe)
ehci_close_pipe(pipe, isp->sqh);
}
-Static void
+void
ehci_device_intr_done(usbd_xfer_handle xfer)
{
#define exfer EXFER(xfer)
@@ -3250,8 +3250,8 @@ ehci_device_intr_done(usbd_xfer_handle xfer)
/************************/
-Static usbd_status ehci_device_isoc_transfer(usbd_xfer_handle xfer) { return USBD_IOERROR; }
-Static usbd_status ehci_device_isoc_start(usbd_xfer_handle xfer) { return USBD_IOERROR; }
-Static void ehci_device_isoc_abort(usbd_xfer_handle xfer) { }
-Static void ehci_device_isoc_close(usbd_pipe_handle pipe) { }
-Static void ehci_device_isoc_done(usbd_xfer_handle xfer) { }
+usbd_status ehci_device_isoc_transfer(usbd_xfer_handle xfer) { return USBD_IOERROR; }
+usbd_status ehci_device_isoc_start(usbd_xfer_handle xfer) { return USBD_IOERROR; }
+void ehci_device_isoc_abort(usbd_xfer_handle xfer) { }
+void ehci_device_isoc_close(usbd_pipe_handle pipe) { }
+void ehci_device_isoc_done(usbd_xfer_handle xfer) { }
diff --git a/sys/dev/usb/hid.c b/sys/dev/usb/hid.c
index d2a959f0f5a..f26bf0289d5 100644
--- a/sys/dev/usb/hid.c
+++ b/sys/dev/usb/hid.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: hid.c,v 1.17 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: hid.c,v 1.18 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: hid.c,v 1.23 2002/07/11 21:14:25 augustss Exp $ */
/* $FreeBSD: src/sys/dev/usb/hid.c,v 1.11 1999/11/17 22:33:39 n_hibma Exp $ */
@@ -57,7 +57,7 @@ extern int uhidevdebug;
#define DPRINTFN(n,x)
#endif
-Static void hid_clear_local(struct hid_item *);
+void hid_clear_local(struct hid_item *);
#define MAXUSAGE 256
struct hid_data {
@@ -73,7 +73,7 @@ struct hid_data {
enum hid_kind kind;
};
-Static void
+void
hid_clear_local(struct hid_item *c)
{
diff --git a/sys/dev/usb/if_aue.c b/sys/dev/usb/if_aue.c
index 4f7a3bde733..3a3716ec35c 100644
--- a/sys/dev/usb/if_aue.c
+++ b/sys/dev/usb/if_aue.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_aue.c,v 1.56 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: if_aue.c,v 1.57 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: if_aue.c,v 1.82 2003/03/05 17:37:36 shiba Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
@@ -137,7 +137,7 @@ struct aue_type {
#define PII 0x0004 /* Pegasus II chip */
};
-Static const struct aue_type aue_devs[] = {
+const struct aue_type aue_devs[] = {
{{ USB_VENDOR_3COM, USB_PRODUCT_3COM_3C460B}, PII },
{{ USB_VENDOR_ABOCOM, USB_PRODUCT_ABOCOM_XX1}, PNA|PII },
{{ USB_VENDOR_ABOCOM, USB_PRODUCT_ABOCOM_XX2}, PII },
@@ -212,43 +212,43 @@ Static const struct aue_type aue_devs[] = {
USB_DECLARE_DRIVER_CLASS(aue, DV_IFNET);
-Static void aue_reset_pegasus_II(struct aue_softc *sc);
-Static int aue_tx_list_init(struct aue_softc *);
-Static int aue_rx_list_init(struct aue_softc *);
-Static int aue_newbuf(struct aue_softc *, struct aue_chain *, struct mbuf *);
-Static int aue_send(struct aue_softc *, struct mbuf *, int);
-Static void aue_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void aue_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void aue_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void aue_tick(void *);
-Static void aue_tick_task(void *);
-Static void aue_start(struct ifnet *);
-Static int aue_ioctl(struct ifnet *, u_long, caddr_t);
-Static void aue_init(void *);
-Static void aue_shutdown(void *);
-Static void aue_stop(struct aue_softc *);
-Static void aue_watchdog(struct ifnet *);
-Static int aue_openpipes(struct aue_softc *);
-Static int aue_ifmedia_upd(struct ifnet *);
-Static void aue_ifmedia_sts(struct ifnet *, struct ifmediareq *);
-
-Static int aue_eeprom_getword(struct aue_softc *, int);
-Static void aue_read_mac(struct aue_softc *, u_char *);
-Static int aue_miibus_readreg(device_ptr_t, int, int);
-Static void aue_miibus_writereg(device_ptr_t, int, int, int);
-Static void aue_miibus_statchg(device_ptr_t);
-
-Static void aue_lock_mii(struct aue_softc *);
-Static void aue_unlock_mii(struct aue_softc *);
-
-Static void aue_setmulti(struct aue_softc *);
-Static u_int32_t aue_crc(caddr_t);
-Static void aue_reset(struct aue_softc *);
-
-Static int aue_csr_read_1(struct aue_softc *, int);
-Static int aue_csr_write_1(struct aue_softc *, int, int);
-Static int aue_csr_read_2(struct aue_softc *, int);
-Static int aue_csr_write_2(struct aue_softc *, int, int);
+void aue_reset_pegasus_II(struct aue_softc *sc);
+int aue_tx_list_init(struct aue_softc *);
+int aue_rx_list_init(struct aue_softc *);
+int aue_newbuf(struct aue_softc *, struct aue_chain *, struct mbuf *);
+int aue_send(struct aue_softc *, struct mbuf *, int);
+void aue_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void aue_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void aue_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void aue_tick(void *);
+void aue_tick_task(void *);
+void aue_start(struct ifnet *);
+int aue_ioctl(struct ifnet *, u_long, caddr_t);
+void aue_init(void *);
+void aue_shutdown(void *);
+void aue_stop(struct aue_softc *);
+void aue_watchdog(struct ifnet *);
+int aue_openpipes(struct aue_softc *);
+int aue_ifmedia_upd(struct ifnet *);
+void aue_ifmedia_sts(struct ifnet *, struct ifmediareq *);
+
+int aue_eeprom_getword(struct aue_softc *, int);
+void aue_read_mac(struct aue_softc *, u_char *);
+int aue_miibus_readreg(device_ptr_t, int, int);
+void aue_miibus_writereg(device_ptr_t, int, int, int);
+void aue_miibus_statchg(device_ptr_t);
+
+void aue_lock_mii(struct aue_softc *);
+void aue_unlock_mii(struct aue_softc *);
+
+void aue_setmulti(struct aue_softc *);
+u_int32_t aue_crc(caddr_t);
+void aue_reset(struct aue_softc *);
+
+int aue_csr_read_1(struct aue_softc *, int);
+int aue_csr_write_1(struct aue_softc *, int, int);
+int aue_csr_read_2(struct aue_softc *, int);
+int aue_csr_write_2(struct aue_softc *, int, int);
#define AUE_SETBIT(sc, reg, x) \
aue_csr_write_1(sc, reg, aue_csr_read_1(sc, reg) | (x))
@@ -256,7 +256,7 @@ Static int aue_csr_write_2(struct aue_softc *, int, int);
#define AUE_CLRBIT(sc, reg, x) \
aue_csr_write_1(sc, reg, aue_csr_read_1(sc, reg) & ~(x))
-Static int
+int
aue_csr_read_1(struct aue_softc *sc, int reg)
{
usb_device_request_t req;
@@ -283,7 +283,7 @@ aue_csr_read_1(struct aue_softc *sc, int reg)
return (val);
}
-Static int
+int
aue_csr_read_2(struct aue_softc *sc, int reg)
{
usb_device_request_t req;
@@ -310,7 +310,7 @@ aue_csr_read_2(struct aue_softc *sc, int reg)
return (UGETW(val));
}
-Static int
+int
aue_csr_write_1(struct aue_softc *sc, int reg, int aval)
{
usb_device_request_t req;
@@ -338,7 +338,7 @@ aue_csr_write_1(struct aue_softc *sc, int reg, int aval)
return (0);
}
-Static int
+int
aue_csr_write_2(struct aue_softc *sc, int reg, int aval)
{
usb_device_request_t req;
@@ -369,7 +369,7 @@ aue_csr_write_2(struct aue_softc *sc, int reg, int aval)
/*
* Read a word of data stored in the EEPROM at address 'addr.'
*/
-Static int
+int
aue_eeprom_getword(struct aue_softc *sc, int addr)
{
int i;
@@ -393,7 +393,7 @@ aue_eeprom_getword(struct aue_softc *sc, int addr)
/*
* Read the MAC from the EEPROM. It's at offset 0.
*/
-Static void
+void
aue_read_mac(struct aue_softc *sc, u_char *dest)
{
int i;
@@ -410,14 +410,14 @@ aue_read_mac(struct aue_softc *sc, u_char *dest)
}
/* Get exclusive access to the MII registers */
-Static void
+void
aue_lock_mii(struct aue_softc *sc)
{
sc->aue_refcnt++;
rw_enter_write(&sc->aue_mii_lock);
}
-Static void
+void
aue_unlock_mii(struct aue_softc *sc)
{
rw_exit_write(&sc->aue_mii_lock);
@@ -425,7 +425,7 @@ aue_unlock_mii(struct aue_softc *sc)
usb_detach_wakeup(USBDEV(sc->aue_dev));
}
-Static int
+int
aue_miibus_readreg(device_ptr_t dev, int phy, int reg)
{
struct aue_softc *sc = USBGETSOFTC(dev);
@@ -479,7 +479,7 @@ aue_miibus_readreg(device_ptr_t dev, int phy, int reg)
return (val);
}
-Static void
+void
aue_miibus_writereg(device_ptr_t dev, int phy, int reg, int data)
{
struct aue_softc *sc = USBGETSOFTC(dev);
@@ -513,7 +513,7 @@ aue_miibus_writereg(device_ptr_t dev, int phy, int reg, int data)
aue_unlock_mii(sc);
}
-Static void
+void
aue_miibus_statchg(device_ptr_t dev)
{
struct aue_softc *sc = USBGETSOFTC(dev);
@@ -554,7 +554,7 @@ aue_miibus_statchg(device_ptr_t dev)
#define AUE_POLY 0xEDB88320
#define AUE_BITS 6
-Static u_int32_t
+u_int32_t
aue_crc(caddr_t addr)
{
u_int32_t idx, bit, data, crc;
@@ -570,7 +570,7 @@ aue_crc(caddr_t addr)
return (crc & ((1 << AUE_BITS) - 1));
}
-Static void
+void
aue_setmulti(struct aue_softc *sc)
{
struct ifnet *ifp;
@@ -610,7 +610,7 @@ allmulti:
ifp->if_flags &= ~IFF_ALLMULTI;
}
-Static void
+void
aue_reset_pegasus_II(struct aue_softc *sc)
{
/* Magic constants taken from Linux driver. */
@@ -624,7 +624,7 @@ aue_reset_pegasus_II(struct aue_softc *sc)
aue_csr_write_1(sc, AUE_REG_81, 2);
}
-Static void
+void
aue_reset(struct aue_softc *sc)
{
int i;
@@ -908,7 +908,7 @@ aue_activate(device_ptr_t self, enum devact act)
/*
* Initialize an RX descriptor and attach an MBUF cluster.
*/
-Static int
+int
aue_newbuf(struct aue_softc *sc, struct aue_chain *c, struct mbuf *m)
{
struct mbuf *m_new = NULL;
@@ -943,7 +943,7 @@ aue_newbuf(struct aue_softc *sc, struct aue_chain *c, struct mbuf *m)
return (0);
}
-Static int
+int
aue_rx_list_init(struct aue_softc *sc)
{
struct aue_cdata *cd;
@@ -972,7 +972,7 @@ aue_rx_list_init(struct aue_softc *sc)
return (0);
}
-Static int
+int
aue_tx_list_init(struct aue_softc *sc)
{
struct aue_cdata *cd;
@@ -1000,7 +1000,7 @@ aue_tx_list_init(struct aue_softc *sc)
return (0);
}
-Static void
+void
aue_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct aue_softc *sc = priv;
@@ -1042,7 +1042,7 @@ aue_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
* A frame has been uploaded: pass the resulting mbuf chain up to
* the higher level protocols.
*/
-Static void
+void
aue_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct aue_chain *c = priv;
@@ -1145,7 +1145,7 @@ aue_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
* the list buffers.
*/
-Static void
+void
aue_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct aue_chain *c = priv;
@@ -1189,7 +1189,7 @@ aue_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static void
+void
aue_tick(void *xsc)
{
struct aue_softc *sc = xsc;
@@ -1206,7 +1206,7 @@ aue_tick(void *xsc)
usb_add_task(sc->aue_udev, &sc->aue_tick_task);
}
-Static void
+void
aue_tick_task(void *xsc)
{
struct aue_softc *sc = xsc;
@@ -1241,7 +1241,7 @@ aue_tick_task(void *xsc)
splx(s);
}
-Static int
+int
aue_send(struct aue_softc *sc, struct mbuf *m, int idx)
{
int total_len;
@@ -1290,7 +1290,7 @@ aue_send(struct aue_softc *sc, struct mbuf *m, int idx)
return (0);
}
-Static void
+void
aue_start(struct ifnet *ifp)
{
struct aue_softc *sc = ifp->if_softc;
@@ -1336,7 +1336,7 @@ aue_start(struct ifnet *ifp)
ifp->if_timer = 5;
}
-Static void
+void
aue_init(void *xsc)
{
struct aue_softc *sc = xsc;
@@ -1409,7 +1409,7 @@ aue_init(void *xsc)
usb_callout(sc->aue_stat_ch, hz, aue_tick, sc);
}
-Static int
+int
aue_openpipes(struct aue_softc *sc)
{
struct aue_chain *c;
@@ -1459,7 +1459,7 @@ aue_openpipes(struct aue_softc *sc)
/*
* Set media options.
*/
-Static int
+int
aue_ifmedia_upd(struct ifnet *ifp)
{
struct aue_softc *sc = ifp->if_softc;
@@ -1485,7 +1485,7 @@ aue_ifmedia_upd(struct ifnet *ifp)
/*
* Report current media status.
*/
-Static void
+void
aue_ifmedia_sts(struct ifnet *ifp, struct ifmediareq *ifmr)
{
struct aue_softc *sc = ifp->if_softc;
@@ -1498,7 +1498,7 @@ aue_ifmedia_sts(struct ifnet *ifp, struct ifmediareq *ifmr)
ifmr->ifm_status = mii->mii_media_status;
}
-Static int
+int
aue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct aue_softc *sc = ifp->if_softc;
@@ -1579,7 +1579,7 @@ aue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
return (error);
}
-Static void
+void
aue_watchdog(struct ifnet *ifp)
{
struct aue_softc *sc = ifp->if_softc;
@@ -1606,7 +1606,7 @@ aue_watchdog(struct ifnet *ifp)
* Stop all chip I/O so that the kernel's probe routines don't
* get confused by errant DMAs when rebooting.
*/
-Static void
+void
aue_shutdown(void *arg)
{
struct aue_softc *sc = (struct aue_softc *)arg;
@@ -1619,7 +1619,7 @@ aue_shutdown(void *arg)
* Stop the adapter and free any mbufs allocated to the
* RX and TX lists.
*/
-Static void
+void
aue_stop(struct aue_softc *sc)
{
usbd_status err;
diff --git a/sys/dev/usb/if_axe.c b/sys/dev/usb/if_axe.c
index 0e42b72efa0..4ad7503c551 100644
--- a/sys/dev/usb/if_axe.c
+++ b/sys/dev/usb/if_axe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_axe.c,v 1.69 2007/05/27 04:00:24 jsg Exp $ */
+/* $OpenBSD: if_axe.c,v 1.70 2007/06/05 08:43:55 mbalmer Exp $ */
/*
* Copyright (c) 2005, 2006, 2007 Jonathan Gray <jsg@openbsd.org>
@@ -143,7 +143,7 @@ int axedebug = 0;
/*
* Various supported device vendors/products.
*/
-Static const struct axe_type axe_devs[] = {
+const struct axe_type axe_devs[] = {
{ { USB_VENDOR_ABOCOM, USB_PRODUCT_ABOCOM_UF200}, 0 },
{ { USB_VENDOR_ACERCM, USB_PRODUCT_ACERCM_EP1427X2}, 0 },
{ { USB_VENDOR_ASIX, USB_PRODUCT_ASIX_AX88172}, 0 },
@@ -175,43 +175,43 @@ Static const struct axe_type axe_devs[] = {
USB_DECLARE_DRIVER_CLASS(axe, DV_IFNET);
-Static int axe_tx_list_init(struct axe_softc *);
-Static int axe_rx_list_init(struct axe_softc *);
-Static struct mbuf *axe_newbuf(void);
-Static int axe_encap(struct axe_softc *, struct mbuf *, int);
-Static void axe_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void axe_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void axe_tick(void *);
-Static void axe_tick_task(void *);
-Static void axe_start(struct ifnet *);
-Static int axe_ioctl(struct ifnet *, u_long, caddr_t);
-Static void axe_init(void *);
-Static void axe_stop(struct axe_softc *);
-Static void axe_watchdog(struct ifnet *);
-Static int axe_miibus_readreg(device_ptr_t, int, int);
-Static void axe_miibus_writereg(device_ptr_t, int, int, int);
-Static void axe_miibus_statchg(device_ptr_t);
-Static int axe_cmd(struct axe_softc *, int, int, int, void *);
-Static int axe_ifmedia_upd(struct ifnet *);
-Static void axe_ifmedia_sts(struct ifnet *, struct ifmediareq *);
-Static void axe_reset(struct axe_softc *sc);
-
-Static void axe_setmulti(struct axe_softc *);
-Static void axe_lock_mii(struct axe_softc *sc);
-Static void axe_unlock_mii(struct axe_softc *sc);
-
-Static void axe_ax88178_init(struct axe_softc *);
-Static void axe_ax88772_init(struct axe_softc *);
+int axe_tx_list_init(struct axe_softc *);
+int axe_rx_list_init(struct axe_softc *);
+struct mbuf *axe_newbuf(void);
+int axe_encap(struct axe_softc *, struct mbuf *, int);
+void axe_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void axe_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void axe_tick(void *);
+void axe_tick_task(void *);
+void axe_start(struct ifnet *);
+int axe_ioctl(struct ifnet *, u_long, caddr_t);
+void axe_init(void *);
+void axe_stop(struct axe_softc *);
+void axe_watchdog(struct ifnet *);
+int axe_miibus_readreg(device_ptr_t, int, int);
+void axe_miibus_writereg(device_ptr_t, int, int, int);
+void axe_miibus_statchg(device_ptr_t);
+int axe_cmd(struct axe_softc *, int, int, int, void *);
+int axe_ifmedia_upd(struct ifnet *);
+void axe_ifmedia_sts(struct ifnet *, struct ifmediareq *);
+void axe_reset(struct axe_softc *sc);
+
+void axe_setmulti(struct axe_softc *);
+void axe_lock_mii(struct axe_softc *sc);
+void axe_unlock_mii(struct axe_softc *sc);
+
+void axe_ax88178_init(struct axe_softc *);
+void axe_ax88772_init(struct axe_softc *);
/* Get exclusive access to the MII registers */
-Static void
+void
axe_lock_mii(struct axe_softc *sc)
{
sc->axe_refcnt++;
rw_enter_write(&sc->axe_mii_lock);
}
-Static void
+void
axe_unlock_mii(struct axe_softc *sc)
{
rw_exit_write(&sc->axe_mii_lock);
@@ -219,7 +219,7 @@ axe_unlock_mii(struct axe_softc *sc)
usb_detach_wakeup(USBDEV(sc->axe_dev));
}
-Static int
+int
axe_cmd(struct axe_softc *sc, int cmd, int index, int val, void *buf)
{
usb_device_request_t req;
@@ -245,7 +245,7 @@ axe_cmd(struct axe_softc *sc, int cmd, int index, int val, void *buf)
return(0);
}
-Static int
+int
axe_miibus_readreg(device_ptr_t dev, int phy, int reg)
{
struct axe_softc *sc = USBGETSOFTC(dev);
@@ -293,7 +293,7 @@ axe_miibus_readreg(device_ptr_t dev, int phy, int reg)
return (UGETW(val));
}
-Static void
+void
axe_miibus_writereg(device_ptr_t dev, int phy, int reg, int val)
{
struct axe_softc *sc = USBGETSOFTC(dev);
@@ -317,7 +317,7 @@ axe_miibus_writereg(device_ptr_t dev, int phy, int reg, int val)
}
}
-Static void
+void
axe_miibus_statchg(device_ptr_t dev)
{
struct axe_softc *sc = USBGETSOFTC(dev);
@@ -356,7 +356,7 @@ axe_miibus_statchg(device_ptr_t dev)
/*
* Set media options.
*/
-Static int
+int
axe_ifmedia_upd(struct ifnet *ifp)
{
struct axe_softc *sc = ifp->if_softc;
@@ -376,7 +376,7 @@ axe_ifmedia_upd(struct ifnet *ifp)
/*
* Report current media status.
*/
-Static void
+void
axe_ifmedia_sts(struct ifnet *ifp, struct ifmediareq *ifmr)
{
struct axe_softc *sc = ifp->if_softc;
@@ -387,7 +387,7 @@ axe_ifmedia_sts(struct ifnet *ifp, struct ifmediareq *ifmr)
ifmr->ifm_status = mii->mii_media_status;
}
-Static void
+void
axe_setmulti(struct axe_softc *sc)
{
struct ifnet *ifp;
@@ -432,7 +432,7 @@ allmulti:
return;
}
-Static void
+void
axe_reset(struct axe_softc *sc)
{
if (sc->axe_dying)
@@ -444,7 +444,7 @@ axe_reset(struct axe_softc *sc)
return;
}
-Static void
+void
axe_ax88178_init(struct axe_softc *sc)
{
int gpio0 = 0, phymode = 0;
@@ -498,7 +498,7 @@ axe_ax88178_init(struct axe_softc *sc)
axe_cmd(sc, AXE_CMD_RXCTL_WRITE, 0, 0, NULL);
}
-Static void
+void
axe_ax88772_init(struct axe_softc *sc)
{
axe_cmd(sc, AXE_CMD_WRITE_GPIO, 0, 0x00b0, NULL);
@@ -812,7 +812,7 @@ axe_activate(device_ptr_t self, enum devact act)
return (0);
}
-Static struct mbuf *
+struct mbuf *
axe_newbuf(void)
{
struct mbuf *m;
@@ -833,7 +833,7 @@ axe_newbuf(void)
return (m);
}
-Static int
+int
axe_rx_list_init(struct axe_softc *sc)
{
struct axe_cdata *cd;
@@ -864,7 +864,7 @@ axe_rx_list_init(struct axe_softc *sc)
return (0);
}
-Static int
+int
axe_tx_list_init(struct axe_softc *sc)
{
struct axe_cdata *cd;
@@ -899,7 +899,7 @@ axe_tx_list_init(struct axe_softc *sc)
* A frame has been uploaded: pass the resulting mbuf chain up to
* the higher level protocols.
*/
-Static void
+void
axe_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct axe_chain *c = (struct axe_chain *)priv;
@@ -1015,7 +1015,7 @@ done:
* the list buffers.
*/
-Static void
+void
axe_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct axe_softc *sc;
@@ -1060,7 +1060,7 @@ axe_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
return;
}
-Static void
+void
axe_tick(void *xsc)
{
struct axe_softc *sc = xsc;
@@ -1079,7 +1079,7 @@ axe_tick(void *xsc)
}
-Static void
+void
axe_tick_task(void *xsc)
{
int s;
@@ -1117,7 +1117,7 @@ axe_tick_task(void *xsc)
splx(s);
}
-Static int
+int
axe_encap(struct axe_softc *sc, struct mbuf *m, int idx)
{
struct axe_chain *c;
@@ -1169,7 +1169,7 @@ axe_encap(struct axe_softc *sc, struct mbuf *m, int idx)
return(0);
}
-Static void
+void
axe_start(struct ifnet *ifp)
{
struct axe_softc *sc;
@@ -1212,7 +1212,7 @@ axe_start(struct ifnet *ifp)
return;
}
-Static void
+void
axe_init(void *xsc)
{
struct axe_softc *sc = xsc;
@@ -1315,7 +1315,7 @@ axe_init(void *xsc)
return;
}
-Static int
+int
axe_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct axe_softc *sc = ifp->if_softc;
@@ -1399,7 +1399,7 @@ axe_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
return(error);
}
-Static void
+void
axe_watchdog(struct ifnet *ifp)
{
struct axe_softc *sc;
@@ -1426,7 +1426,7 @@ axe_watchdog(struct ifnet *ifp)
* Stop the adapter and free any mbufs allocated to the
* RX and TX lists.
*/
-Static void
+void
axe_stop(struct axe_softc *sc)
{
usbd_status err;
diff --git a/sys/dev/usb/if_cdce.c b/sys/dev/usb/if_cdce.c
index 9f82100ed8b..68fac6d0de1 100644
--- a/sys/dev/usb/if_cdce.c
+++ b/sys/dev/usb/if_cdce.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_cdce.c,v 1.26 2007/05/27 04:00:24 jsg Exp $ */
+/* $OpenBSD: if_cdce.c,v 1.27 2007/06/05 08:43:55 mbalmer Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000-2003 Bill Paul <wpaul@windriver.com>
@@ -73,22 +73,22 @@
#include <dev/usb/if_cdcereg.h>
-Static void *cdce_get_desc(usbd_device_handle dev, int type, int subtype);
-Static int cdce_tx_list_init(struct cdce_softc *);
-Static int cdce_rx_list_init(struct cdce_softc *);
-Static int cdce_newbuf(struct cdce_softc *, struct cdce_chain *,
+void *cdce_get_desc(usbd_device_handle dev, int type, int subtype);
+int cdce_tx_list_init(struct cdce_softc *);
+int cdce_rx_list_init(struct cdce_softc *);
+int cdce_newbuf(struct cdce_softc *, struct cdce_chain *,
struct mbuf *);
-Static int cdce_encap(struct cdce_softc *, struct mbuf *, int);
-Static void cdce_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void cdce_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void cdce_start(struct ifnet *);
-Static int cdce_ioctl(struct ifnet *, u_long, caddr_t);
-Static void cdce_init(void *);
-Static void cdce_watchdog(struct ifnet *);
-Static void cdce_stop(struct cdce_softc *);
+int cdce_encap(struct cdce_softc *, struct mbuf *, int);
+void cdce_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void cdce_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void cdce_start(struct ifnet *);
+int cdce_ioctl(struct ifnet *, u_long, caddr_t);
+void cdce_init(void *);
+void cdce_watchdog(struct ifnet *);
+void cdce_stop(struct cdce_softc *);
static uint32_t cdce_crc32(const void *, size_t);
-Static const struct cdce_type cdce_devs[] = {
+const struct cdce_type cdce_devs[] = {
{{ USB_VENDOR_ACERLABS, USB_PRODUCT_ACERLABS_M5632 }, CDCE_NO_UNION },
{{ USB_VENDOR_PROLIFIC, USB_PRODUCT_PROLIFIC_PL2501 }, CDCE_NO_UNION },
{{ USB_VENDOR_SHARP, USB_PRODUCT_SHARP_SL5500 }, CDCE_ZAURUS },
@@ -295,7 +295,7 @@ cdce_detach(struct device *self, int flags)
return (0);
}
-Static void
+void
cdce_start(struct ifnet *ifp)
{
struct cdce_softc *sc = ifp->if_softc;
@@ -325,7 +325,7 @@ cdce_start(struct ifnet *ifp)
ifp->if_timer = 6;
}
-Static int
+int
cdce_encap(struct cdce_softc *sc, struct mbuf *m, int idx)
{
struct cdce_chain *c;
@@ -359,7 +359,7 @@ cdce_encap(struct cdce_softc *sc, struct mbuf *m, int idx)
return (0);
}
-Static void
+void
cdce_stop(struct cdce_softc *sc)
{
usbd_status err;
@@ -416,7 +416,7 @@ cdce_stop(struct cdce_softc *sc)
}
}
-Static int
+int
cdce_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct cdce_softc *sc = ifp->if_softc;
@@ -478,7 +478,7 @@ cdce_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
return (error);
}
-Static void
+void
cdce_watchdog(struct ifnet *ifp)
{
struct cdce_softc *sc = ifp->if_softc;
@@ -490,7 +490,7 @@ cdce_watchdog(struct ifnet *ifp)
printf("%s: watchdog timeout\n", USBDEVNAME(sc->cdce_dev));
}
-Static void
+void
cdce_init(void *xsc)
{
struct cdce_softc *sc = xsc;
@@ -550,7 +550,7 @@ cdce_init(void *xsc)
splx(s);
}
-Static int
+int
cdce_newbuf(struct cdce_softc *sc, struct cdce_chain *c, struct mbuf *m)
{
struct mbuf *m_new = NULL;
@@ -581,7 +581,7 @@ cdce_newbuf(struct cdce_softc *sc, struct cdce_chain *c, struct mbuf *m)
return (0);
}
-Static int
+int
cdce_rx_list_init(struct cdce_softc *sc)
{
struct cdce_cdata *cd;
@@ -608,7 +608,7 @@ cdce_rx_list_init(struct cdce_softc *sc)
return (0);
}
-Static int
+int
cdce_tx_list_init(struct cdce_softc *sc)
{
struct cdce_cdata *cd;
@@ -634,7 +634,7 @@ cdce_tx_list_init(struct cdce_softc *sc)
return (0);
}
-Static void
+void
cdce_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct cdce_chain *c = priv;
@@ -711,7 +711,7 @@ done:
usbd_transfer(c->cdce_xfer);
}
-Static void
+void
cdce_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct cdce_chain *c = priv;
diff --git a/sys/dev/usb/if_cue.c b/sys/dev/usb/if_cue.c
index 585bfb1ec6c..200e513ee0d 100644
--- a/sys/dev/usb/if_cue.c
+++ b/sys/dev/usb/if_cue.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_cue.c,v 1.36 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: if_cue.c,v 1.37 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: if_cue.c,v 1.40 2002/07/11 21:14:26 augustss Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
@@ -102,7 +102,7 @@ int cuedebug = 0;
/*
* Various supported device vendors/products.
*/
-Static struct usb_devno cue_devs[] = {
+struct usb_devno cue_devs[] = {
{ USB_VENDOR_CATC, USB_PRODUCT_CATC_NETMATE },
{ USB_VENDOR_CATC, USB_PRODUCT_CATC_NETMATE2 },
{ USB_VENDOR_SMARTBRIDGES, USB_PRODUCT_SMARTBRIDGES_SMARTLINK },
@@ -112,32 +112,32 @@ Static struct usb_devno cue_devs[] = {
USB_DECLARE_DRIVER_CLASS(cue, DV_IFNET);
-Static int cue_open_pipes(struct cue_softc *);
-Static int cue_tx_list_init(struct cue_softc *);
-Static int cue_rx_list_init(struct cue_softc *);
-Static int cue_newbuf(struct cue_softc *, struct cue_chain *, struct mbuf *);
-Static int cue_send(struct cue_softc *, struct mbuf *, int);
-Static void cue_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void cue_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void cue_tick(void *);
-Static void cue_tick_task(void *);
-Static void cue_start(struct ifnet *);
-Static int cue_ioctl(struct ifnet *, u_long, caddr_t);
-Static void cue_init(void *);
-Static void cue_stop(struct cue_softc *);
-Static void cue_watchdog(struct ifnet *);
-
-Static void cue_setmulti(struct cue_softc *);
-Static void cue_reset(struct cue_softc *);
-
-Static int cue_csr_read_1(struct cue_softc *, int);
-Static int cue_csr_write_1(struct cue_softc *, int, int);
-Static int cue_csr_read_2(struct cue_softc *, int);
+int cue_open_pipes(struct cue_softc *);
+int cue_tx_list_init(struct cue_softc *);
+int cue_rx_list_init(struct cue_softc *);
+int cue_newbuf(struct cue_softc *, struct cue_chain *, struct mbuf *);
+int cue_send(struct cue_softc *, struct mbuf *, int);
+void cue_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void cue_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void cue_tick(void *);
+void cue_tick_task(void *);
+void cue_start(struct ifnet *);
+int cue_ioctl(struct ifnet *, u_long, caddr_t);
+void cue_init(void *);
+void cue_stop(struct cue_softc *);
+void cue_watchdog(struct ifnet *);
+
+void cue_setmulti(struct cue_softc *);
+void cue_reset(struct cue_softc *);
+
+int cue_csr_read_1(struct cue_softc *, int);
+int cue_csr_write_1(struct cue_softc *, int, int);
+int cue_csr_read_2(struct cue_softc *, int);
#if 0
-Static int cue_csr_write_2(struct cue_softc *, int, int);
+int cue_csr_write_2(struct cue_softc *, int, int);
#endif
-Static int cue_mem(struct cue_softc *, int, int, void *, int);
-Static int cue_getmac(struct cue_softc *, void *);
+int cue_mem(struct cue_softc *, int, int, void *, int);
+int cue_getmac(struct cue_softc *, void *);
#define CUE_SETBIT(sc, reg, x) \
cue_csr_write_1(sc, reg, cue_csr_read_1(sc, reg) | (x))
@@ -145,7 +145,7 @@ Static int cue_getmac(struct cue_softc *, void *);
#define CUE_CLRBIT(sc, reg, x) \
cue_csr_write_1(sc, reg, cue_csr_read_1(sc, reg) & ~(x))
-Static int
+int
cue_csr_read_1(struct cue_softc *sc, int reg)
{
usb_device_request_t req;
@@ -175,7 +175,7 @@ cue_csr_read_1(struct cue_softc *sc, int reg)
return (val);
}
-Static int
+int
cue_csr_read_2(struct cue_softc *sc, int reg)
{
usb_device_request_t req;
@@ -205,7 +205,7 @@ cue_csr_read_2(struct cue_softc *sc, int reg)
return (UGETW(val));
}
-Static int
+int
cue_csr_write_1(struct cue_softc *sc, int reg, int val)
{
usb_device_request_t req;
@@ -238,7 +238,7 @@ cue_csr_write_1(struct cue_softc *sc, int reg, int val)
}
#if 0
-Static int
+int
cue_csr_write_2(struct cue_softc *sc, int reg, int aval)
{
usb_device_request_t req;
@@ -271,7 +271,7 @@ cue_csr_write_2(struct cue_softc *sc, int reg, int aval)
}
#endif
-Static int
+int
cue_mem(struct cue_softc *sc, int cmd, int addr, void *buf, int len)
{
usb_device_request_t req;
@@ -300,7 +300,7 @@ cue_mem(struct cue_softc *sc, int cmd, int addr, void *buf, int len)
return (0);
}
-Static int
+int
cue_getmac(struct cue_softc *sc, void *buf)
{
usb_device_request_t req;
@@ -327,7 +327,7 @@ cue_getmac(struct cue_softc *sc, void *buf)
#define CUE_BITS 9
-Static void
+void
cue_setmulti(struct cue_softc *sc)
{
struct ifnet *ifp;
@@ -383,7 +383,7 @@ allmulti:
&sc->cue_mctab, CUE_MCAST_TABLE_LEN);
}
-Static void
+void
cue_reset(struct cue_softc *sc)
{
usb_device_request_t req;
@@ -608,7 +608,7 @@ cue_activate(device_ptr_t self, enum devact act)
/*
* Initialize an RX descriptor and attach an MBUF cluster.
*/
-Static int
+int
cue_newbuf(struct cue_softc *sc, struct cue_chain *c, struct mbuf *m)
{
struct mbuf *m_new = NULL;
@@ -641,7 +641,7 @@ cue_newbuf(struct cue_softc *sc, struct cue_chain *c, struct mbuf *m)
return (0);
}
-Static int
+int
cue_rx_list_init(struct cue_softc *sc)
{
struct cue_cdata *cd;
@@ -670,7 +670,7 @@ cue_rx_list_init(struct cue_softc *sc)
return (0);
}
-Static int
+int
cue_tx_list_init(struct cue_softc *sc)
{
struct cue_cdata *cd;
@@ -702,7 +702,7 @@ cue_tx_list_init(struct cue_softc *sc)
* A frame has been uploaded: pass the resulting mbuf chain up to
* the higher level protocols.
*/
-Static void
+void
cue_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct cue_chain *c = priv;
@@ -798,7 +798,7 @@ done:
* A frame was downloaded to the chip. It's safe for us to clean up
* the list buffers.
*/
-Static void
+void
cue_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct cue_chain *c = priv;
@@ -842,7 +842,7 @@ cue_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static void
+void
cue_tick(void *xsc)
{
struct cue_softc *sc = xsc;
@@ -859,7 +859,7 @@ cue_tick(void *xsc)
usb_add_task(sc->cue_udev, &sc->cue_tick_task);
}
-Static void
+void
cue_tick_task(void *xsc)
{
struct cue_softc *sc = xsc;
@@ -880,7 +880,7 @@ cue_tick_task(void *xsc)
ifp->if_ierrors++;
}
-Static int
+int
cue_send(struct cue_softc *sc, struct mbuf *m, int idx)
{
int total_len;
@@ -924,7 +924,7 @@ cue_send(struct cue_softc *sc, struct mbuf *m, int idx)
return (0);
}
-Static void
+void
cue_start(struct ifnet *ifp)
{
struct cue_softc *sc = ifp->if_softc;
@@ -966,7 +966,7 @@ cue_start(struct ifnet *ifp)
ifp->if_timer = 5;
}
-Static void
+void
cue_init(void *xsc)
{
struct cue_softc *sc = xsc;
@@ -1052,7 +1052,7 @@ cue_init(void *xsc)
usb_callout(sc->cue_stat_ch, hz, cue_tick, sc);
}
-Static int
+int
cue_open_pipes(struct cue_softc *sc)
{
struct cue_chain *c;
@@ -1088,7 +1088,7 @@ cue_open_pipes(struct cue_softc *sc)
return (0);
}
-Static int
+int
cue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct cue_softc *sc = ifp->if_softc;
@@ -1169,7 +1169,7 @@ cue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
return (error);
}
-Static void
+void
cue_watchdog(struct ifnet *ifp)
{
struct cue_softc *sc = ifp->if_softc;
@@ -1199,7 +1199,7 @@ cue_watchdog(struct ifnet *ifp)
* Stop the adapter and free any mbufs allocated to the
* RX and TX lists.
*/
-Static void
+void
cue_stop(struct cue_softc *sc)
{
usbd_status err;
diff --git a/sys/dev/usb/if_kue.c b/sys/dev/usb/if_kue.c
index eae67543a31..2d7c65e370f 100644
--- a/sys/dev/usb/if_kue.c
+++ b/sys/dev/usb/if_kue.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_kue.c,v 1.49 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: if_kue.c,v 1.50 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: if_kue.c,v 1.50 2002/07/16 22:00:31 augustss Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
@@ -117,7 +117,7 @@ int kuedebug = 0;
/*
* Various supported device vendors/products.
*/
-Static const struct usb_devno kue_devs[] = {
+const struct usb_devno kue_devs[] = {
{ USB_VENDOR_3COM, USB_PRODUCT_3COM_3C19250 },
{ USB_VENDOR_3COM, USB_PRODUCT_3COM_3C460 },
{ USB_VENDOR_ABOCOM, USB_PRODUCT_ABOCOM_URE450 },
@@ -156,29 +156,29 @@ Static const struct usb_devno kue_devs[] = {
USB_DECLARE_DRIVER_CLASS(kue, DV_IFNET);
-Static int kue_tx_list_init(struct kue_softc *);
-Static int kue_rx_list_init(struct kue_softc *);
-Static int kue_newbuf(struct kue_softc *, struct kue_chain *,struct mbuf *);
-Static int kue_send(struct kue_softc *, struct mbuf *, int);
-Static int kue_open_pipes(struct kue_softc *);
-Static void kue_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void kue_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void kue_start(struct ifnet *);
-Static int kue_ioctl(struct ifnet *, u_long, caddr_t);
-Static void kue_init(void *);
-Static void kue_stop(struct kue_softc *);
-Static void kue_watchdog(struct ifnet *);
-
-Static void kue_setmulti(struct kue_softc *);
-Static void kue_reset(struct kue_softc *);
-
-Static usbd_status kue_ctl(struct kue_softc *, int, u_int8_t,
+int kue_tx_list_init(struct kue_softc *);
+int kue_rx_list_init(struct kue_softc *);
+int kue_newbuf(struct kue_softc *, struct kue_chain *,struct mbuf *);
+int kue_send(struct kue_softc *, struct mbuf *, int);
+int kue_open_pipes(struct kue_softc *);
+void kue_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void kue_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void kue_start(struct ifnet *);
+int kue_ioctl(struct ifnet *, u_long, caddr_t);
+void kue_init(void *);
+void kue_stop(struct kue_softc *);
+void kue_watchdog(struct ifnet *);
+
+void kue_setmulti(struct kue_softc *);
+void kue_reset(struct kue_softc *);
+
+usbd_status kue_ctl(struct kue_softc *, int, u_int8_t,
u_int16_t, void *, u_int32_t);
-Static usbd_status kue_setword(struct kue_softc *, u_int8_t, u_int16_t);
-Static int kue_load_fw(struct kue_softc *);
+usbd_status kue_setword(struct kue_softc *, u_int8_t, u_int16_t);
+int kue_load_fw(struct kue_softc *);
void kue_attachhook(void *);
-Static usbd_status
+usbd_status
kue_setword(struct kue_softc *sc, u_int8_t breq, u_int16_t word)
{
usb_device_request_t req;
@@ -194,7 +194,7 @@ kue_setword(struct kue_softc *sc, u_int8_t breq, u_int16_t word)
return (usbd_do_request(sc->kue_udev, &req, NULL));
}
-Static usbd_status
+usbd_status
kue_ctl(struct kue_softc *sc, int rw, u_int8_t breq, u_int16_t val,
void *data, u_int32_t len)
{
@@ -216,7 +216,7 @@ kue_ctl(struct kue_softc *sc, int rw, u_int8_t breq, u_int16_t val,
return (usbd_do_request(sc->kue_udev, &req, data));
}
-Static int
+int
kue_load_fw(struct kue_softc *sc)
{
usb_device_descriptor_t dd;
@@ -318,7 +318,7 @@ kue_load_fw(struct kue_softc *sc)
return (0);
}
-Static void
+void
kue_setmulti(struct kue_softc *sc)
{
struct ifnet *ifp = GET_IFP(sc);
@@ -366,7 +366,7 @@ allmulti:
* done after the firmware is loaded into the adapter in order to
* bring it into proper operation.
*/
-Static void
+void
kue_reset(struct kue_softc *sc)
{
DPRINTFN(5,("%s: %s: enter\n", USBDEVNAME(sc->kue_dev), __func__));
@@ -601,7 +601,7 @@ kue_activate(device_ptr_t self, enum devact act)
/*
* Initialize an RX descriptor and attach an MBUF cluster.
*/
-Static int
+int
kue_newbuf(struct kue_softc *sc, struct kue_chain *c, struct mbuf *m)
{
struct mbuf *m_new = NULL;
@@ -635,7 +635,7 @@ kue_newbuf(struct kue_softc *sc, struct kue_chain *c, struct mbuf *m)
return (0);
}
-Static int
+int
kue_rx_list_init(struct kue_softc *sc)
{
struct kue_cdata *cd;
@@ -664,7 +664,7 @@ kue_rx_list_init(struct kue_softc *sc)
return (0);
}
-Static int
+int
kue_tx_list_init(struct kue_softc *sc)
{
struct kue_cdata *cd;
@@ -696,7 +696,7 @@ kue_tx_list_init(struct kue_softc *sc)
* A frame has been uploaded: pass the resulting mbuf chain up to
* the higher level protocols.
*/
-Static void
+void
kue_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct kue_chain *c = priv;
@@ -799,7 +799,7 @@ kue_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
* the list buffers.
*/
-Static void
+void
kue_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct kue_chain *c = priv;
@@ -843,7 +843,7 @@ kue_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static int
+int
kue_send(struct kue_softc *sc, struct mbuf *m, int idx)
{
int total_len;
@@ -887,7 +887,7 @@ kue_send(struct kue_softc *sc, struct mbuf *m, int idx)
return (0);
}
-Static void
+void
kue_start(struct ifnet *ifp)
{
struct kue_softc *sc = ifp->if_softc;
@@ -929,7 +929,7 @@ kue_start(struct ifnet *ifp)
ifp->if_timer = 6;
}
-Static void
+void
kue_init(void *xsc)
{
struct kue_softc *sc = xsc;
@@ -996,7 +996,7 @@ kue_init(void *xsc)
splx(s);
}
-Static int
+int
kue_open_pipes(struct kue_softc *sc)
{
usbd_status err;
@@ -1037,7 +1037,7 @@ kue_open_pipes(struct kue_softc *sc)
return (0);
}
-Static int
+int
kue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct kue_softc *sc = ifp->if_softc;
@@ -1129,7 +1129,7 @@ kue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
return (error);
}
-Static void
+void
kue_watchdog(struct ifnet *ifp)
{
struct kue_softc *sc = ifp->if_softc;
@@ -1159,7 +1159,7 @@ kue_watchdog(struct ifnet *ifp)
* Stop the adapter and free any mbufs allocated to the
* RX and TX lists.
*/
-Static void
+void
kue_stop(struct kue_softc *sc)
{
usbd_status err;
diff --git a/sys/dev/usb/if_ral.c b/sys/dev/usb/if_ral.c
index 782f00f7fe7..9dd4ca16619 100644
--- a/sys/dev/usb/if_ral.c
+++ b/sys/dev/usb/if_ral.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_ral.c,v 1.92 2007/05/27 04:00:24 jsg Exp $ */
+/* $OpenBSD: if_ral.c,v 1.93 2007/06/05 08:43:55 mbalmer Exp $ */
/*-
* Copyright (c) 2005, 2006
@@ -109,68 +109,68 @@ static const struct usb_devno ural_devs[] = {
{ USB_VENDOR_ZINWELL, USB_PRODUCT_ZINWELL_RT2570 }
};
-Static int ural_alloc_tx_list(struct ural_softc *);
-Static void ural_free_tx_list(struct ural_softc *);
-Static int ural_alloc_rx_list(struct ural_softc *);
-Static void ural_free_rx_list(struct ural_softc *);
-Static int ural_media_change(struct ifnet *);
-Static void ural_next_scan(void *);
-Static void ural_task(void *);
-Static int ural_newstate(struct ieee80211com *,
+int ural_alloc_tx_list(struct ural_softc *);
+void ural_free_tx_list(struct ural_softc *);
+int ural_alloc_rx_list(struct ural_softc *);
+void ural_free_rx_list(struct ural_softc *);
+int ural_media_change(struct ifnet *);
+void ural_next_scan(void *);
+void ural_task(void *);
+int ural_newstate(struct ieee80211com *,
enum ieee80211_state, int);
-Static void ural_txeof(usbd_xfer_handle, usbd_private_handle,
+void ural_txeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static void ural_rxeof(usbd_xfer_handle, usbd_private_handle,
+void ural_rxeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
#if NBPFILTER > 0
-Static uint8_t ural_rxrate(const struct ural_rx_desc *);
+uint8_t ural_rxrate(const struct ural_rx_desc *);
#endif
-Static int ural_ack_rate(struct ieee80211com *, int);
-Static uint16_t ural_txtime(int, int, uint32_t);
-Static uint8_t ural_plcp_signal(int);
-Static void ural_setup_tx_desc(struct ural_softc *,
+int ural_ack_rate(struct ieee80211com *, int);
+uint16_t ural_txtime(int, int, uint32_t);
+uint8_t ural_plcp_signal(int);
+void ural_setup_tx_desc(struct ural_softc *,
struct ural_tx_desc *, uint32_t, int, int);
-Static int ural_tx_bcn(struct ural_softc *, struct mbuf *,
+int ural_tx_bcn(struct ural_softc *, struct mbuf *,
struct ieee80211_node *);
-Static int ural_tx_data(struct ural_softc *, struct mbuf *,
+int ural_tx_data(struct ural_softc *, struct mbuf *,
struct ieee80211_node *);
-Static void ural_start(struct ifnet *);
-Static void ural_watchdog(struct ifnet *);
-Static int ural_ioctl(struct ifnet *, u_long, caddr_t);
-Static void ural_eeprom_read(struct ural_softc *, uint16_t, void *,
+void ural_start(struct ifnet *);
+void ural_watchdog(struct ifnet *);
+int ural_ioctl(struct ifnet *, u_long, caddr_t);
+void ural_eeprom_read(struct ural_softc *, uint16_t, void *,
int);
-Static uint16_t ural_read(struct ural_softc *, uint16_t);
-Static void ural_read_multi(struct ural_softc *, uint16_t, void *,
+uint16_t ural_read(struct ural_softc *, uint16_t);
+void ural_read_multi(struct ural_softc *, uint16_t, void *,
int);
-Static void ural_write(struct ural_softc *, uint16_t, uint16_t);
-Static void ural_write_multi(struct ural_softc *, uint16_t, void *,
+void ural_write(struct ural_softc *, uint16_t, uint16_t);
+void ural_write_multi(struct ural_softc *, uint16_t, void *,
int);
-Static void ural_bbp_write(struct ural_softc *, uint8_t, uint8_t);
-Static uint8_t ural_bbp_read(struct ural_softc *, uint8_t);
-Static void ural_rf_write(struct ural_softc *, uint8_t, uint32_t);
-Static void ural_set_chan(struct ural_softc *,
+void ural_bbp_write(struct ural_softc *, uint8_t, uint8_t);
+uint8_t ural_bbp_read(struct ural_softc *, uint8_t);
+void ural_rf_write(struct ural_softc *, uint8_t, uint32_t);
+void ural_set_chan(struct ural_softc *,
struct ieee80211_channel *);
-Static void ural_disable_rf_tune(struct ural_softc *);
-Static void ural_enable_tsf_sync(struct ural_softc *);
-Static void ural_update_slot(struct ural_softc *);
-Static void ural_set_txpreamble(struct ural_softc *);
-Static void ural_set_basicrates(struct ural_softc *);
-Static void ural_set_bssid(struct ural_softc *, const uint8_t *);
-Static void ural_set_macaddr(struct ural_softc *, const uint8_t *);
-Static void ural_update_promisc(struct ural_softc *);
-Static const char *ural_get_rf(int);
-Static void ural_read_eeprom(struct ural_softc *);
-Static int ural_bbp_init(struct ural_softc *);
-Static void ural_set_txantenna(struct ural_softc *, int);
-Static void ural_set_rxantenna(struct ural_softc *, int);
-Static int ural_init(struct ifnet *);
-Static void ural_stop(struct ifnet *, int);
-Static void ural_newassoc(struct ieee80211com *,
+void ural_disable_rf_tune(struct ural_softc *);
+void ural_enable_tsf_sync(struct ural_softc *);
+void ural_update_slot(struct ural_softc *);
+void ural_set_txpreamble(struct ural_softc *);
+void ural_set_basicrates(struct ural_softc *);
+void ural_set_bssid(struct ural_softc *, const uint8_t *);
+void ural_set_macaddr(struct ural_softc *, const uint8_t *);
+void ural_update_promisc(struct ural_softc *);
+const char *ural_get_rf(int);
+void ural_read_eeprom(struct ural_softc *);
+int ural_bbp_init(struct ural_softc *);
+void ural_set_txantenna(struct ural_softc *, int);
+void ural_set_rxantenna(struct ural_softc *, int);
+int ural_init(struct ifnet *);
+void ural_stop(struct ifnet *, int);
+void ural_newassoc(struct ieee80211com *,
struct ieee80211_node *, int);
-Static void ural_amrr_start(struct ural_softc *,
+void ural_amrr_start(struct ural_softc *,
struct ieee80211_node *);
-Static void ural_amrr_timeout(void *);
-Static void ural_amrr_update(usbd_xfer_handle, usbd_private_handle,
+void ural_amrr_timeout(void *);
+void ural_amrr_update(usbd_xfer_handle, usbd_private_handle,
usbd_status status);
static const struct {
@@ -391,7 +391,7 @@ ural_detach(struct device *self, int flags)
return 0;
}
-Static int
+int
ural_alloc_tx_list(struct ural_softc *sc)
{
int i, error;
@@ -426,7 +426,7 @@ fail: ural_free_tx_list(sc);
return error;
}
-Static void
+void
ural_free_tx_list(struct ural_softc *sc)
{
int i;
@@ -446,7 +446,7 @@ ural_free_tx_list(struct ural_softc *sc)
}
}
-Static int
+int
ural_alloc_rx_list(struct ural_softc *sc)
{
int i, error;
@@ -493,7 +493,7 @@ fail: ural_free_tx_list(sc);
return error;
}
-Static void
+void
ural_free_rx_list(struct ural_softc *sc)
{
int i;
@@ -512,7 +512,7 @@ ural_free_rx_list(struct ural_softc *sc)
}
}
-Static int
+int
ural_media_change(struct ifnet *ifp)
{
int error;
@@ -531,7 +531,7 @@ ural_media_change(struct ifnet *ifp)
* This function is called periodically (every 200ms) during scanning to
* switch from one channel to another.
*/
-Static void
+void
ural_next_scan(void *arg)
{
struct ural_softc *sc = arg;
@@ -542,7 +542,7 @@ ural_next_scan(void *arg)
ieee80211_next_scan(ifp);
}
-Static void
+void
ural_task(void *arg)
{
struct ural_softc *sc = arg;
@@ -630,7 +630,7 @@ ural_task(void *arg)
sc->sc_newstate(ic, sc->sc_state, sc->sc_arg);
}
-Static int
+int
ural_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg)
{
struct ural_softc *sc = ic->ic_if.if_softc;
@@ -656,7 +656,7 @@ ural_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg)
#define RAL_RXTX_TURNAROUND 5 /* us */
-Static void
+void
ural_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct ural_tx_data *data = priv;
@@ -696,7 +696,7 @@ ural_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static void
+void
ural_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct ural_rx_data *data = priv;
@@ -819,7 +819,7 @@ skip: /* setup a new transfer */
* which a given frame was received.
*/
#if NBPFILTER > 0
-Static uint8_t
+uint8_t
ural_rxrate(const struct ural_rx_desc *desc)
{
if (letoh32(desc->flags) & RAL_RX_OFDM) {
@@ -851,7 +851,7 @@ ural_rxrate(const struct ural_rx_desc *desc)
/*
* Return the expected ack rate for a frame transmitted at rate `rate'.
*/
-Static int
+int
ural_ack_rate(struct ieee80211com *ic, int rate)
{
switch (rate) {
@@ -886,7 +886,7 @@ ural_ack_rate(struct ieee80211com *ic, int rate)
* The function automatically determines the operating mode depending on the
* given rate. `flags' indicates whether short preamble is in use or not.
*/
-Static uint16_t
+uint16_t
ural_txtime(int len, int rate, uint32_t flags)
{
uint16_t txtime;
@@ -906,7 +906,7 @@ ural_txtime(int len, int rate, uint32_t flags)
return txtime;
}
-Static uint8_t
+uint8_t
ural_plcp_signal(int rate)
{
switch (rate) {
@@ -931,7 +931,7 @@ ural_plcp_signal(int rate)
}
}
-Static void
+void
ural_setup_tx_desc(struct ural_softc *sc, struct ural_tx_desc *desc,
uint32_t flags, int len, int rate)
{
@@ -978,7 +978,7 @@ ural_setup_tx_desc(struct ural_softc *sc, struct ural_tx_desc *desc,
#define RAL_TX_TIMEOUT 5000
-Static int
+int
ural_tx_bcn(struct ural_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
{
struct ural_tx_desc *desc;
@@ -1028,7 +1028,7 @@ ural_tx_bcn(struct ural_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
return error;
}
-Static int
+int
ural_tx_data(struct ural_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1215,7 +1215,7 @@ ural_tx_data(struct ural_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
return 0;
}
-Static void
+void
ural_start(struct ifnet *ifp)
{
struct ural_softc *sc = ifp->if_softc;
@@ -1283,7 +1283,7 @@ ural_start(struct ifnet *ifp)
}
}
-Static void
+void
ural_watchdog(struct ifnet *ifp)
{
struct ural_softc *sc = ifp->if_softc;
@@ -1303,7 +1303,7 @@ ural_watchdog(struct ifnet *ifp)
ieee80211_watchdog(ifp);
}
-Static int
+int
ural_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct ural_softc *sc = ifp->if_softc;
@@ -1378,7 +1378,7 @@ ural_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
return error;
}
-Static void
+void
ural_eeprom_read(struct ural_softc *sc, uint16_t addr, void *buf, int len)
{
usb_device_request_t req;
@@ -1397,7 +1397,7 @@ ural_eeprom_read(struct ural_softc *sc, uint16_t addr, void *buf, int len)
}
}
-Static uint16_t
+uint16_t
ural_read(struct ural_softc *sc, uint16_t reg)
{
usb_device_request_t req;
@@ -1419,7 +1419,7 @@ ural_read(struct ural_softc *sc, uint16_t reg)
return letoh16(val);
}
-Static void
+void
ural_read_multi(struct ural_softc *sc, uint16_t reg, void *buf, int len)
{
usb_device_request_t req;
@@ -1438,7 +1438,7 @@ ural_read_multi(struct ural_softc *sc, uint16_t reg, void *buf, int len)
}
}
-Static void
+void
ural_write(struct ural_softc *sc, uint16_t reg, uint16_t val)
{
usb_device_request_t req;
@@ -1457,7 +1457,7 @@ ural_write(struct ural_softc *sc, uint16_t reg, uint16_t val)
}
}
-Static void
+void
ural_write_multi(struct ural_softc *sc, uint16_t reg, void *buf, int len)
{
usb_device_request_t req;
@@ -1476,7 +1476,7 @@ ural_write_multi(struct ural_softc *sc, uint16_t reg, void *buf, int len)
}
}
-Static void
+void
ural_bbp_write(struct ural_softc *sc, uint8_t reg, uint8_t val)
{
uint16_t tmp;
@@ -1495,7 +1495,7 @@ ural_bbp_write(struct ural_softc *sc, uint8_t reg, uint8_t val)
ural_write(sc, RAL_PHY_CSR7, tmp);
}
-Static uint8_t
+uint8_t
ural_bbp_read(struct ural_softc *sc, uint8_t reg)
{
uint16_t val;
@@ -1515,7 +1515,7 @@ ural_bbp_read(struct ural_softc *sc, uint8_t reg)
return ural_read(sc, RAL_PHY_CSR7) & 0xff;
}
-Static void
+void
ural_rf_write(struct ural_softc *sc, uint8_t reg, uint32_t val)
{
uint32_t tmp;
@@ -1540,7 +1540,7 @@ ural_rf_write(struct ural_softc *sc, uint8_t reg, uint32_t val)
DPRINTFN(15, ("RF R[%u] <- 0x%05x\n", reg & 0x3, val & 0xfffff));
}
-Static void
+void
ural_set_chan(struct ural_softc *sc, struct ieee80211_channel *c)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1628,7 +1628,7 @@ ural_set_chan(struct ural_softc *sc, struct ieee80211_channel *c)
/*
* Disable RF auto-tuning.
*/
-Static void
+void
ural_disable_rf_tune(struct ural_softc *sc)
{
uint32_t tmp;
@@ -1648,7 +1648,7 @@ ural_disable_rf_tune(struct ural_softc *sc)
* Refer to IEEE Std 802.11-1999 pp. 123 for more information on TSF
* synchronization.
*/
-Static void
+void
ural_enable_tsf_sync(struct ural_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1676,7 +1676,7 @@ ural_enable_tsf_sync(struct ural_softc *sc)
DPRINTF(("enabling TSF synchronization\n"));
}
-Static void
+void
ural_update_slot(struct ural_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1701,7 +1701,7 @@ ural_update_slot(struct ural_softc *sc)
ural_write(sc, RAL_MAC_CSR12, eifs);
}
-Static void
+void
ural_set_txpreamble(struct ural_softc *sc)
{
uint16_t tmp;
@@ -1715,7 +1715,7 @@ ural_set_txpreamble(struct ural_softc *sc)
ural_write(sc, RAL_TXRX_CSR10, tmp);
}
-Static void
+void
ural_set_basicrates(struct ural_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1730,7 +1730,7 @@ ural_set_basicrates(struct ural_softc *sc)
}
}
-Static void
+void
ural_set_bssid(struct ural_softc *sc, const uint8_t *bssid)
{
uint16_t tmp;
@@ -1747,7 +1747,7 @@ ural_set_bssid(struct ural_softc *sc, const uint8_t *bssid)
DPRINTF(("setting BSSID to %s\n", ether_sprintf((uint8_t *)bssid)));
}
-Static void
+void
ural_set_macaddr(struct ural_softc *sc, const uint8_t *addr)
{
uint16_t tmp;
@@ -1765,7 +1765,7 @@ ural_set_macaddr(struct ural_softc *sc, const uint8_t *addr)
ether_sprintf((uint8_t *)addr)));
}
-Static void
+void
ural_update_promisc(struct ural_softc *sc)
{
struct ifnet *ifp = &sc->sc_ic.ic_if;
@@ -1783,7 +1783,7 @@ ural_update_promisc(struct ural_softc *sc)
"entering" : "leaving"));
}
-Static const char *
+const char *
ural_get_rf(int rev)
{
switch (rev) {
@@ -1798,7 +1798,7 @@ ural_get_rf(int rev)
}
}
-Static void
+void
ural_read_eeprom(struct ural_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1827,7 +1827,7 @@ ural_read_eeprom(struct ural_softc *sc)
ural_eeprom_read(sc, RAL_EEPROM_TXPOWER, sc->txpow, 14);
}
-Static int
+int
ural_bbp_init(struct ural_softc *sc)
{
#define N(a) (sizeof (a) / sizeof ((a)[0]))
@@ -1861,7 +1861,7 @@ ural_bbp_init(struct ural_softc *sc)
#undef N
}
-Static void
+void
ural_set_txantenna(struct ural_softc *sc, int antenna)
{
uint16_t tmp;
@@ -1890,7 +1890,7 @@ ural_set_txantenna(struct ural_softc *sc, int antenna)
ural_write(sc, RAL_PHY_CSR6, tmp | (tx & 0x7));
}
-Static void
+void
ural_set_rxantenna(struct ural_softc *sc, int antenna)
{
uint8_t rx;
@@ -1910,7 +1910,7 @@ ural_set_rxantenna(struct ural_softc *sc, int antenna)
ural_bbp_write(sc, RAL_BBP_RX, rx);
}
-Static int
+int
ural_init(struct ifnet *ifp)
{
#define N(a) (sizeof (a) / sizeof ((a)[0]))
@@ -2062,7 +2062,7 @@ fail: ural_stop(ifp, 1);
#undef N
}
-Static void
+void
ural_stop(struct ifnet *ifp, int disable)
{
struct ural_softc *sc = ifp->if_softc;
@@ -2100,14 +2100,14 @@ ural_stop(struct ifnet *ifp, int disable)
ural_free_tx_list(sc);
}
-Static void
+void
ural_newassoc(struct ieee80211com *ic, struct ieee80211_node *ni, int isnew)
{
/* start with lowest Tx rate */
ni->ni_txrate = 0;
}
-Static void
+void
ural_amrr_start(struct ural_softc *sc, struct ieee80211_node *ni)
{
int i;
@@ -2126,7 +2126,7 @@ ural_amrr_start(struct ural_softc *sc, struct ieee80211_node *ni)
timeout_add(&sc->amrr_to, hz);
}
-Static void
+void
ural_amrr_timeout(void *arg)
{
struct ural_softc *sc = arg;
@@ -2152,7 +2152,7 @@ ural_amrr_timeout(void *arg)
splx(s);
}
-Static void
+void
ural_amrr_update(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -2182,7 +2182,7 @@ ural_amrr_update(usbd_xfer_handle xfer, usbd_private_handle priv,
timeout_add(&sc->amrr_to, hz);
}
-Static int
+int
ural_activate(device_ptr_t self, enum devact act)
{
switch (act) {
diff --git a/sys/dev/usb/if_rum.c b/sys/dev/usb/if_rum.c
index 90832819911..c7648134309 100644
--- a/sys/dev/usb/if_rum.c
+++ b/sys/dev/usb/if_rum.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_rum.c,v 1.57 2007/05/27 04:00:24 jsg Exp $ */
+/* $OpenBSD: if_rum.c,v 1.58 2007/06/05 08:43:55 mbalmer Exp $ */
/*-
* Copyright (c) 2005-2007 Damien Bergamini <damien.bergamini@free.fr>
@@ -126,72 +126,72 @@ static const struct usb_devno rum_devs[] = {
{ USB_VENDOR_SURECOM, USB_PRODUCT_SURECOM_RT2573 }
};
-Static void rum_attachhook(void *);
-Static int rum_alloc_tx_list(struct rum_softc *);
-Static void rum_free_tx_list(struct rum_softc *);
-Static int rum_alloc_rx_list(struct rum_softc *);
-Static void rum_free_rx_list(struct rum_softc *);
-Static int rum_media_change(struct ifnet *);
-Static void rum_next_scan(void *);
-Static void rum_task(void *);
-Static int rum_newstate(struct ieee80211com *,
+void rum_attachhook(void *);
+int rum_alloc_tx_list(struct rum_softc *);
+void rum_free_tx_list(struct rum_softc *);
+int rum_alloc_rx_list(struct rum_softc *);
+void rum_free_rx_list(struct rum_softc *);
+int rum_media_change(struct ifnet *);
+void rum_next_scan(void *);
+void rum_task(void *);
+int rum_newstate(struct ieee80211com *,
enum ieee80211_state, int);
-Static void rum_txeof(usbd_xfer_handle, usbd_private_handle,
+void rum_txeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static void rum_rxeof(usbd_xfer_handle, usbd_private_handle,
+void rum_rxeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
#if NBPFILTER > 0
-Static uint8_t rum_rxrate(const struct rum_rx_desc *);
+uint8_t rum_rxrate(const struct rum_rx_desc *);
#endif
-Static int rum_ack_rate(struct ieee80211com *, int);
-Static uint16_t rum_txtime(int, int, uint32_t);
-Static uint8_t rum_plcp_signal(int);
-Static void rum_setup_tx_desc(struct rum_softc *,
+int rum_ack_rate(struct ieee80211com *, int);
+uint16_t rum_txtime(int, int, uint32_t);
+uint8_t rum_plcp_signal(int);
+void rum_setup_tx_desc(struct rum_softc *,
struct rum_tx_desc *, uint32_t, uint16_t, int,
int);
-Static int rum_tx_data(struct rum_softc *, struct mbuf *,
+int rum_tx_data(struct rum_softc *, struct mbuf *,
struct ieee80211_node *);
-Static void rum_start(struct ifnet *);
-Static void rum_watchdog(struct ifnet *);
-Static int rum_ioctl(struct ifnet *, u_long, caddr_t);
-Static void rum_eeprom_read(struct rum_softc *, uint16_t, void *,
+void rum_start(struct ifnet *);
+void rum_watchdog(struct ifnet *);
+int rum_ioctl(struct ifnet *, u_long, caddr_t);
+void rum_eeprom_read(struct rum_softc *, uint16_t, void *,
int);
-Static uint32_t rum_read(struct rum_softc *, uint16_t);
-Static void rum_read_multi(struct rum_softc *, uint16_t, void *,
+uint32_t rum_read(struct rum_softc *, uint16_t);
+void rum_read_multi(struct rum_softc *, uint16_t, void *,
int);
-Static void rum_write(struct rum_softc *, uint16_t, uint32_t);
-Static void rum_write_multi(struct rum_softc *, uint16_t, void *,
+void rum_write(struct rum_softc *, uint16_t, uint32_t);
+void rum_write_multi(struct rum_softc *, uint16_t, void *,
size_t);
-Static void rum_bbp_write(struct rum_softc *, uint8_t, uint8_t);
-Static uint8_t rum_bbp_read(struct rum_softc *, uint8_t);
-Static void rum_rf_write(struct rum_softc *, uint8_t, uint32_t);
-Static void rum_select_antenna(struct rum_softc *);
-Static void rum_enable_mrr(struct rum_softc *);
-Static void rum_set_txpreamble(struct rum_softc *);
-Static void rum_set_basicrates(struct rum_softc *);
-Static void rum_select_band(struct rum_softc *,
+void rum_bbp_write(struct rum_softc *, uint8_t, uint8_t);
+uint8_t rum_bbp_read(struct rum_softc *, uint8_t);
+void rum_rf_write(struct rum_softc *, uint8_t, uint32_t);
+void rum_select_antenna(struct rum_softc *);
+void rum_enable_mrr(struct rum_softc *);
+void rum_set_txpreamble(struct rum_softc *);
+void rum_set_basicrates(struct rum_softc *);
+void rum_select_band(struct rum_softc *,
struct ieee80211_channel *);
-Static void rum_set_chan(struct rum_softc *,
+void rum_set_chan(struct rum_softc *,
struct ieee80211_channel *);
-Static void rum_enable_tsf_sync(struct rum_softc *);
-Static void rum_update_slot(struct rum_softc *);
-Static void rum_set_bssid(struct rum_softc *, const uint8_t *);
-Static void rum_set_macaddr(struct rum_softc *, const uint8_t *);
-Static void rum_update_promisc(struct rum_softc *);
-Static const char *rum_get_rf(int);
-Static void rum_read_eeprom(struct rum_softc *);
-Static int rum_bbp_init(struct rum_softc *);
-Static int rum_init(struct ifnet *);
-Static void rum_stop(struct ifnet *, int);
-Static int rum_load_microcode(struct rum_softc *, const u_char *,
+void rum_enable_tsf_sync(struct rum_softc *);
+void rum_update_slot(struct rum_softc *);
+void rum_set_bssid(struct rum_softc *, const uint8_t *);
+void rum_set_macaddr(struct rum_softc *, const uint8_t *);
+void rum_update_promisc(struct rum_softc *);
+const char *rum_get_rf(int);
+void rum_read_eeprom(struct rum_softc *);
+int rum_bbp_init(struct rum_softc *);
+int rum_init(struct ifnet *);
+void rum_stop(struct ifnet *, int);
+int rum_load_microcode(struct rum_softc *, const u_char *,
size_t);
-Static int rum_prepare_beacon(struct rum_softc *);
-Static void rum_newassoc(struct ieee80211com *,
+int rum_prepare_beacon(struct rum_softc *);
+void rum_newassoc(struct ieee80211com *,
struct ieee80211_node *, int);
-Static void rum_amrr_start(struct rum_softc *,
+void rum_amrr_start(struct rum_softc *,
struct ieee80211_node *);
-Static void rum_amrr_timeout(void *);
-Static void rum_amrr_update(usbd_xfer_handle, usbd_private_handle,
+void rum_amrr_timeout(void *);
+void rum_amrr_update(usbd_xfer_handle, usbd_private_handle,
usbd_status status);
static const struct {
@@ -231,7 +231,7 @@ rum_match(struct device *parent, void *match, void *aux)
UMATCH_VENDOR_PRODUCT : UMATCH_NONE;
}
-Static void
+void
rum_attachhook(void *xsc)
{
struct rum_softc *sc = xsc;
@@ -476,7 +476,7 @@ rum_detach(struct device *self, int flags)
return 0;
}
-Static int
+int
rum_alloc_tx_list(struct rum_softc *sc)
{
int i, error;
@@ -513,7 +513,7 @@ fail: rum_free_tx_list(sc);
return error;
}
-Static void
+void
rum_free_tx_list(struct rum_softc *sc)
{
int i;
@@ -533,7 +533,7 @@ rum_free_tx_list(struct rum_softc *sc)
}
}
-Static int
+int
rum_alloc_rx_list(struct rum_softc *sc)
{
int i, error;
@@ -580,7 +580,7 @@ fail: rum_free_tx_list(sc);
return error;
}
-Static void
+void
rum_free_rx_list(struct rum_softc *sc)
{
int i;
@@ -599,7 +599,7 @@ rum_free_rx_list(struct rum_softc *sc)
}
}
-Static int
+int
rum_media_change(struct ifnet *ifp)
{
int error;
@@ -618,7 +618,7 @@ rum_media_change(struct ifnet *ifp)
* This function is called periodically (every 200ms) during scanning to
* switch from one channel to another.
*/
-Static void
+void
rum_next_scan(void *arg)
{
struct rum_softc *sc = arg;
@@ -629,7 +629,7 @@ rum_next_scan(void *arg)
ieee80211_next_scan(ifp);
}
-Static void
+void
rum_task(void *arg)
{
struct rum_softc *sc = arg;
@@ -696,7 +696,7 @@ rum_task(void *arg)
sc->sc_newstate(ic, sc->sc_state, sc->sc_arg);
}
-Static int
+int
rum_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg)
{
struct rum_softc *sc = ic->ic_if.if_softc;
@@ -718,7 +718,7 @@ rum_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg)
#define RUM_ACK_SIZE 14 /* 10 + 4(FCS) */
#define RUM_CTS_SIZE 14 /* 10 + 4(FCS) */
-Static void
+void
rum_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct rum_tx_data *data = priv;
@@ -758,7 +758,7 @@ rum_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static void
+void
rum_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct rum_rx_data *data = priv;
@@ -880,7 +880,7 @@ skip: /* setup a new transfer */
* which a given frame was received.
*/
#if NBPFILTER > 0
-Static uint8_t
+uint8_t
rum_rxrate(const struct rum_rx_desc *desc)
{
if (letoh32(desc->flags) & RT2573_RX_OFDM) {
@@ -912,7 +912,7 @@ rum_rxrate(const struct rum_rx_desc *desc)
/*
* Return the expected ack rate for a frame transmitted at rate `rate'.
*/
-Static int
+int
rum_ack_rate(struct ieee80211com *ic, int rate)
{
switch (rate) {
@@ -947,7 +947,7 @@ rum_ack_rate(struct ieee80211com *ic, int rate)
* The function automatically determines the operating mode depending on the
* given rate. `flags' indicates whether short preamble is in use or not.
*/
-Static uint16_t
+uint16_t
rum_txtime(int len, int rate, uint32_t flags)
{
uint16_t txtime;
@@ -967,7 +967,7 @@ rum_txtime(int len, int rate, uint32_t flags)
return txtime;
}
-Static uint8_t
+uint8_t
rum_plcp_signal(int rate)
{
switch (rate) {
@@ -992,7 +992,7 @@ rum_plcp_signal(int rate)
}
}
-Static void
+void
rum_setup_tx_desc(struct rum_softc *sc, struct rum_tx_desc *desc,
uint32_t flags, uint16_t xflags, int len, int rate)
{
@@ -1040,7 +1040,7 @@ rum_setup_tx_desc(struct rum_softc *sc, struct rum_tx_desc *desc,
#define RUM_TX_TIMEOUT 5000
-Static int
+int
rum_tx_data(struct rum_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1226,7 +1226,7 @@ rum_tx_data(struct rum_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
return 0;
}
-Static void
+void
rum_start(struct ifnet *ifp)
{
struct rum_softc *sc = ifp->if_softc;
@@ -1294,7 +1294,7 @@ rum_start(struct ifnet *ifp)
}
}
-Static void
+void
rum_watchdog(struct ifnet *ifp)
{
struct rum_softc *sc = ifp->if_softc;
@@ -1314,7 +1314,7 @@ rum_watchdog(struct ifnet *ifp)
ieee80211_watchdog(ifp);
}
-Static int
+int
rum_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct rum_softc *sc = ifp->if_softc;
@@ -1389,7 +1389,7 @@ rum_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
return error;
}
-Static void
+void
rum_eeprom_read(struct rum_softc *sc, uint16_t addr, void *buf, int len)
{
usb_device_request_t req;
@@ -1408,7 +1408,7 @@ rum_eeprom_read(struct rum_softc *sc, uint16_t addr, void *buf, int len)
}
}
-Static uint32_t
+uint32_t
rum_read(struct rum_softc *sc, uint16_t reg)
{
uint32_t val;
@@ -1418,7 +1418,7 @@ rum_read(struct rum_softc *sc, uint16_t reg)
return letoh32(val);
}
-Static void
+void
rum_read_multi(struct rum_softc *sc, uint16_t reg, void *buf, int len)
{
usb_device_request_t req;
@@ -1437,7 +1437,7 @@ rum_read_multi(struct rum_softc *sc, uint16_t reg, void *buf, int len)
}
}
-Static void
+void
rum_write(struct rum_softc *sc, uint16_t reg, uint32_t val)
{
uint32_t tmp = htole32(val);
@@ -1445,7 +1445,7 @@ rum_write(struct rum_softc *sc, uint16_t reg, uint32_t val)
rum_write_multi(sc, reg, &tmp, sizeof tmp);
}
-Static void
+void
rum_write_multi(struct rum_softc *sc, uint16_t reg, void *buf, size_t len)
{
usb_device_request_t req;
@@ -1464,7 +1464,7 @@ rum_write_multi(struct rum_softc *sc, uint16_t reg, void *buf, size_t len)
}
}
-Static void
+void
rum_bbp_write(struct rum_softc *sc, uint8_t reg, uint8_t val)
{
uint32_t tmp;
@@ -1483,7 +1483,7 @@ rum_bbp_write(struct rum_softc *sc, uint8_t reg, uint8_t val)
rum_write(sc, RT2573_PHY_CSR3, tmp);
}
-Static uint8_t
+uint8_t
rum_bbp_read(struct rum_softc *sc, uint8_t reg)
{
uint32_t val;
@@ -1512,7 +1512,7 @@ rum_bbp_read(struct rum_softc *sc, uint8_t reg)
return 0;
}
-Static void
+void
rum_rf_write(struct rum_softc *sc, uint8_t reg, uint32_t val)
{
uint32_t tmp;
@@ -1537,7 +1537,7 @@ rum_rf_write(struct rum_softc *sc, uint8_t reg, uint32_t val)
DPRINTFN(15, ("RF R[%u] <- 0x%05x\n", reg & 3, val & 0xfffff));
}
-Static void
+void
rum_select_antenna(struct rum_softc *sc)
{
uint8_t bbp4, bbp77;
@@ -1562,7 +1562,7 @@ rum_select_antenna(struct rum_softc *sc)
* Enable multi-rate retries for frames sent at OFDM rates.
* In 802.11b/g mode, allow fallback to CCK rates.
*/
-Static void
+void
rum_enable_mrr(struct rum_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1578,7 +1578,7 @@ rum_enable_mrr(struct rum_softc *sc)
rum_write(sc, RT2573_TXRX_CSR4, tmp);
}
-Static void
+void
rum_set_txpreamble(struct rum_softc *sc)
{
uint32_t tmp;
@@ -1592,7 +1592,7 @@ rum_set_txpreamble(struct rum_softc *sc)
rum_write(sc, RT2573_TXRX_CSR4, tmp);
}
-Static void
+void
rum_set_basicrates(struct rum_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1614,7 +1614,7 @@ rum_set_basicrates(struct rum_softc *sc)
* Reprogram MAC/BBP to switch to a new band. Values taken from the reference
* driver.
*/
-Static void
+void
rum_select_band(struct rum_softc *sc, struct ieee80211_channel *c)
{
uint8_t bbp17, bbp35, bbp96, bbp97, bbp98, bbp104;
@@ -1660,7 +1660,7 @@ rum_select_band(struct rum_softc *sc, struct ieee80211_channel *c)
sc->sifs = IEEE80211_IS_CHAN_5GHZ(c) ? 16 : 10;
}
-Static void
+void
rum_set_chan(struct rum_softc *sc, struct ieee80211_channel *c)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1733,7 +1733,7 @@ rum_set_chan(struct rum_softc *sc, struct ieee80211_channel *c)
* Enable TSF synchronization and tell h/w to start sending beacons for IBSS
* and HostAP operating modes.
*/
-Static void
+void
rum_enable_tsf_sync(struct rum_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1761,7 +1761,7 @@ rum_enable_tsf_sync(struct rum_softc *sc)
rum_write(sc, RT2573_TXRX_CSR9, tmp);
}
-Static void
+void
rum_update_slot(struct rum_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1777,7 +1777,7 @@ rum_update_slot(struct rum_softc *sc)
DPRINTF(("setting slot time to %uus\n", slottime));
}
-Static void
+void
rum_set_bssid(struct rum_softc *sc, const uint8_t *bssid)
{
uint32_t tmp;
@@ -1789,7 +1789,7 @@ rum_set_bssid(struct rum_softc *sc, const uint8_t *bssid)
rum_write(sc, RT2573_MAC_CSR5, tmp);
}
-Static void
+void
rum_set_macaddr(struct rum_softc *sc, const uint8_t *addr)
{
uint32_t tmp;
@@ -1801,7 +1801,7 @@ rum_set_macaddr(struct rum_softc *sc, const uint8_t *addr)
rum_write(sc, RT2573_MAC_CSR3, tmp);
}
-Static void
+void
rum_update_promisc(struct rum_softc *sc)
{
struct ifnet *ifp = &sc->sc_ic.ic_if;
@@ -1819,7 +1819,7 @@ rum_update_promisc(struct rum_softc *sc)
"entering" : "leaving"));
}
-Static const char *
+const char *
rum_get_rf(int rev)
{
switch (rev) {
@@ -1831,7 +1831,7 @@ rum_get_rf(int rev)
}
}
-Static void
+void
rum_read_eeprom(struct rum_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1906,7 +1906,7 @@ rum_read_eeprom(struct rum_softc *sc)
#endif
}
-Static int
+int
rum_bbp_init(struct rum_softc *sc)
{
#define N(a) (sizeof (a) / sizeof ((a)[0]))
@@ -1940,7 +1940,7 @@ rum_bbp_init(struct rum_softc *sc)
#undef N
}
-Static int
+int
rum_init(struct ifnet *ifp)
{
#define N(a) (sizeof (a) / sizeof ((a)[0]))
@@ -2080,7 +2080,7 @@ fail: rum_stop(ifp, 1);
#undef N
}
-Static void
+void
rum_stop(struct ifnet *ifp, int disable)
{
struct rum_softc *sc = ifp->if_softc;
@@ -2116,7 +2116,7 @@ rum_stop(struct ifnet *ifp, int disable)
rum_free_tx_list(sc);
}
-Static int
+int
rum_load_microcode(struct rum_softc *sc, const u_char *ucode, size_t size)
{
usb_device_request_t req;
@@ -2141,7 +2141,7 @@ rum_load_microcode(struct rum_softc *sc, const u_char *ucode, size_t size)
return error;
}
-Static int
+int
rum_prepare_beacon(struct rum_softc *sc)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -2174,14 +2174,14 @@ rum_prepare_beacon(struct rum_softc *sc)
return 0;
}
-Static void
+void
rum_newassoc(struct ieee80211com *ic, struct ieee80211_node *ni, int isnew)
{
/* start with lowest Tx rate */
ni->ni_txrate = 0;
}
-Static void
+void
rum_amrr_start(struct rum_softc *sc, struct ieee80211_node *ni)
{
int i;
@@ -2200,7 +2200,7 @@ rum_amrr_start(struct rum_softc *sc, struct ieee80211_node *ni)
timeout_add(&sc->amrr_to, hz);
}
-Static void
+void
rum_amrr_timeout(void *arg)
{
struct rum_softc *sc = arg;
@@ -2221,7 +2221,7 @@ rum_amrr_timeout(void *arg)
(void)usbd_transfer(sc->amrr_xfer);
}
-Static void
+void
rum_amrr_update(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
diff --git a/sys/dev/usb/if_uath.c b/sys/dev/usb/if_uath.c
index b0ef6373406..1e38e78d67e 100644
--- a/sys/dev/usb/if_uath.c
+++ b/sys/dev/usb/if_uath.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_uath.c,v 1.19 2007/05/27 04:00:24 jsg Exp $ */
+/* $OpenBSD: if_uath.c,v 1.20 2007/06/05 08:43:55 mbalmer Exp $ */
/*-
* Copyright (c) 2006
@@ -131,68 +131,68 @@ static const struct uath_type {
#define uath_lookup(v, p) \
((const struct uath_type *)usb_lookup(uath_devs, v, p))
-Static void uath_attachhook(void *);
-Static int uath_open_pipes(struct uath_softc *);
-Static void uath_close_pipes(struct uath_softc *);
-Static int uath_alloc_tx_data_list(struct uath_softc *);
-Static void uath_free_tx_data_list(struct uath_softc *);
-Static int uath_alloc_rx_data_list(struct uath_softc *);
-Static void uath_free_rx_data_list(struct uath_softc *);
-Static void uath_free_rx_data(caddr_t, u_int, void *);
-Static int uath_alloc_tx_cmd_list(struct uath_softc *);
-Static void uath_free_tx_cmd_list(struct uath_softc *);
-Static int uath_alloc_rx_cmd_list(struct uath_softc *);
-Static void uath_free_rx_cmd_list(struct uath_softc *);
-Static int uath_media_change(struct ifnet *);
-Static void uath_stat(void *);
-Static void uath_next_scan(void *);
-Static void uath_task(void *);
-Static int uath_newstate(struct ieee80211com *, enum ieee80211_state,
+void uath_attachhook(void *);
+int uath_open_pipes(struct uath_softc *);
+void uath_close_pipes(struct uath_softc *);
+int uath_alloc_tx_data_list(struct uath_softc *);
+void uath_free_tx_data_list(struct uath_softc *);
+int uath_alloc_rx_data_list(struct uath_softc *);
+void uath_free_rx_data_list(struct uath_softc *);
+void uath_free_rx_data(caddr_t, u_int, void *);
+int uath_alloc_tx_cmd_list(struct uath_softc *);
+void uath_free_tx_cmd_list(struct uath_softc *);
+int uath_alloc_rx_cmd_list(struct uath_softc *);
+void uath_free_rx_cmd_list(struct uath_softc *);
+int uath_media_change(struct ifnet *);
+void uath_stat(void *);
+void uath_next_scan(void *);
+void uath_task(void *);
+int uath_newstate(struct ieee80211com *, enum ieee80211_state,
int);
#ifdef UATH_DEBUG
-Static void uath_dump_cmd(const uint8_t *, int, char);
+void uath_dump_cmd(const uint8_t *, int, char);
#endif
-Static int uath_cmd(struct uath_softc *, uint32_t, const void *, int,
+int uath_cmd(struct uath_softc *, uint32_t, const void *, int,
void *, int);
-Static int uath_cmd_write(struct uath_softc *, uint32_t, const void *,
+int uath_cmd_write(struct uath_softc *, uint32_t, const void *,
int, int);
-Static int uath_cmd_read(struct uath_softc *, uint32_t, const void *,
+int uath_cmd_read(struct uath_softc *, uint32_t, const void *,
int, void *, int);
-Static int uath_write_reg(struct uath_softc *, uint32_t, uint32_t);
-Static int uath_write_multi(struct uath_softc *, uint32_t, const void *,
+int uath_write_reg(struct uath_softc *, uint32_t, uint32_t);
+int uath_write_multi(struct uath_softc *, uint32_t, const void *,
int);
-Static int uath_read_reg(struct uath_softc *, uint32_t, uint32_t *);
-Static int uath_read_eeprom(struct uath_softc *, uint32_t, void *);
-Static void uath_cmd_rxeof(usbd_xfer_handle, usbd_private_handle,
+int uath_read_reg(struct uath_softc *, uint32_t, uint32_t *);
+int uath_read_eeprom(struct uath_softc *, uint32_t, void *);
+void uath_cmd_rxeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static void uath_data_rxeof(usbd_xfer_handle, usbd_private_handle,
+void uath_data_rxeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static void uath_data_txeof(usbd_xfer_handle, usbd_private_handle,
+void uath_data_txeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static int uath_tx_null(struct uath_softc *);
-Static int uath_tx_data(struct uath_softc *, struct mbuf *,
+int uath_tx_null(struct uath_softc *);
+int uath_tx_data(struct uath_softc *, struct mbuf *,
struct ieee80211_node *);
-Static void uath_start(struct ifnet *);
-Static void uath_watchdog(struct ifnet *);
-Static int uath_ioctl(struct ifnet *, u_long, caddr_t);
-Static int uath_query_eeprom(struct uath_softc *);
-Static int uath_reset(struct uath_softc *);
-Static int uath_reset_tx_queues(struct uath_softc *);
-Static int uath_wme_init(struct uath_softc *);
-Static int uath_set_chan(struct uath_softc *, struct ieee80211_channel *);
-Static int uath_set_key(struct uath_softc *,
+void uath_start(struct ifnet *);
+void uath_watchdog(struct ifnet *);
+int uath_ioctl(struct ifnet *, u_long, caddr_t);
+int uath_query_eeprom(struct uath_softc *);
+int uath_reset(struct uath_softc *);
+int uath_reset_tx_queues(struct uath_softc *);
+int uath_wme_init(struct uath_softc *);
+int uath_set_chan(struct uath_softc *, struct ieee80211_channel *);
+int uath_set_key(struct uath_softc *,
const struct ieee80211_wepkey *, int);
-Static int uath_set_keys(struct uath_softc *);
-Static int uath_set_rates(struct uath_softc *,
+int uath_set_keys(struct uath_softc *);
+int uath_set_rates(struct uath_softc *,
const struct ieee80211_rateset *);
-Static int uath_set_rxfilter(struct uath_softc *, uint32_t, uint32_t);
-Static int uath_set_led(struct uath_softc *, int, int);
-Static int uath_switch_channel(struct uath_softc *,
+int uath_set_rxfilter(struct uath_softc *, uint32_t, uint32_t);
+int uath_set_led(struct uath_softc *, int, int);
+int uath_switch_channel(struct uath_softc *,
struct ieee80211_channel *);
-Static int uath_init(struct ifnet *);
-Static void uath_stop(struct ifnet *, int);
-Static int uath_loadfirmware(struct uath_softc *, const u_char *, int);
-Static int uath_activate(device_ptr_t, enum devact);
+int uath_init(struct ifnet *);
+void uath_stop(struct ifnet *, int);
+int uath_loadfirmware(struct uath_softc *, const u_char *, int);
+int uath_activate(device_ptr_t, enum devact);
USB_DECLARE_DRIVER(uath);
@@ -208,7 +208,7 @@ uath_match(struct device *parent, void *match, void *aux)
UMATCH_VENDOR_PRODUCT : UMATCH_NONE;
}
-Static void
+void
uath_attachhook(void *xsc)
{
struct uath_softc *sc = xsc;
@@ -475,7 +475,7 @@ uath_detach(struct device *self, int flags)
return 0;
}
-Static int
+int
uath_open_pipes(struct uath_softc *sc)
{
int error;
@@ -523,7 +523,7 @@ fail: uath_close_pipes(sc);
return error;
}
-Static void
+void
uath_close_pipes(struct uath_softc *sc)
{
/* assumes no transfers are pending on the pipes */
@@ -541,7 +541,7 @@ uath_close_pipes(struct uath_softc *sc)
usbd_close_pipe(sc->cmd_rx_pipe);
}
-Static int
+int
uath_alloc_tx_data_list(struct uath_softc *sc)
{
int i, error;
@@ -572,7 +572,7 @@ fail: uath_free_tx_data_list(sc);
return error;
}
-Static void
+void
uath_free_tx_data_list(struct uath_softc *sc)
{
int i;
@@ -585,7 +585,7 @@ uath_free_tx_data_list(struct uath_softc *sc)
usbd_free_xfer(sc->tx_data[i].xfer);
}
-Static int
+int
uath_alloc_rx_data_list(struct uath_softc *sc)
{
int i, error;
@@ -618,7 +618,7 @@ fail: uath_free_rx_data_list(sc);
return error;
}
-Static void
+void
uath_free_rx_data_list(struct uath_softc *sc)
{
int i;
@@ -631,7 +631,7 @@ uath_free_rx_data_list(struct uath_softc *sc)
usbd_free_xfer(sc->rx_data[i].xfer);
}
-Static void
+void
uath_free_rx_data(caddr_t buf, u_int size, void *arg)
{
struct uath_rx_data *data = arg;
@@ -645,7 +645,7 @@ uath_free_rx_data(caddr_t buf, u_int size, void *arg)
wakeup(UATH_COND_NOREF(sc));
}
-Static int
+int
uath_alloc_tx_cmd_list(struct uath_softc *sc)
{
int i, error;
@@ -676,7 +676,7 @@ fail: uath_free_tx_cmd_list(sc);
return error;
}
-Static void
+void
uath_free_tx_cmd_list(struct uath_softc *sc)
{
int i;
@@ -689,7 +689,7 @@ uath_free_tx_cmd_list(struct uath_softc *sc)
usbd_free_xfer(sc->tx_cmd[i].xfer);
}
-Static int
+int
uath_alloc_rx_cmd_list(struct uath_softc *sc)
{
int i, error;
@@ -720,7 +720,7 @@ fail: uath_free_rx_cmd_list(sc);
return error;
}
-Static void
+void
uath_free_rx_cmd_list(struct uath_softc *sc)
{
int i;
@@ -733,7 +733,7 @@ uath_free_rx_cmd_list(struct uath_softc *sc)
usbd_free_xfer(sc->rx_cmd[i].xfer);
}
-Static int
+int
uath_media_change(struct ifnet *ifp)
{
int error;
@@ -752,7 +752,7 @@ uath_media_change(struct ifnet *ifp)
* This function is called periodically (every second) when associated to
* query device statistics.
*/
-Static void
+void
uath_stat(void *arg)
{
struct uath_softc *sc = arg;
@@ -774,7 +774,7 @@ uath_stat(void *arg)
* This function is called periodically (every 250ms) during scanning to
* switch from one channel to another.
*/
-Static void
+void
uath_next_scan(void *arg)
{
struct uath_softc *sc = arg;
@@ -785,7 +785,7 @@ uath_next_scan(void *arg)
ieee80211_next_scan(ifp);
}
-Static void
+void
uath_task(void *arg)
{
struct uath_softc *sc = arg;
@@ -914,7 +914,7 @@ uath_task(void *arg)
sc->sc_newstate(ic, sc->sc_state, sc->sc_arg);
}
-Static int
+int
uath_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg)
{
struct uath_softc *sc = ic->ic_softc;
@@ -931,7 +931,7 @@ uath_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg)
}
#ifdef UATH_DEBUG
-Static void
+void
uath_dump_cmd(const uint8_t *buf, int len, char prefix)
{
int i;
@@ -950,7 +950,7 @@ uath_dump_cmd(const uint8_t *buf, int len, char prefix)
/*
* Low-level function to send read or write commands to the firmware.
*/
-Static int
+int
uath_cmd(struct uath_softc *sc, uint32_t code, const void *idata, int ilen,
void *odata, int flags)
{
@@ -1015,7 +1015,7 @@ uath_cmd(struct uath_softc *sc, uint32_t code, const void *idata, int ilen,
return error;
}
-Static int
+int
uath_cmd_write(struct uath_softc *sc, uint32_t code, const void *data, int len,
int flags)
{
@@ -1023,7 +1023,7 @@ uath_cmd_write(struct uath_softc *sc, uint32_t code, const void *data, int len,
return uath_cmd(sc, code, data, len, NULL, flags);
}
-Static int
+int
uath_cmd_read(struct uath_softc *sc, uint32_t code, const void *idata,
int ilen, void *odata, int flags)
{
@@ -1031,7 +1031,7 @@ uath_cmd_read(struct uath_softc *sc, uint32_t code, const void *idata,
return uath_cmd(sc, code, idata, ilen, odata, flags);
}
-Static int
+int
uath_write_reg(struct uath_softc *sc, uint32_t reg, uint32_t val)
{
struct uath_write_mac write;
@@ -1050,7 +1050,7 @@ uath_write_reg(struct uath_softc *sc, uint32_t reg, uint32_t val)
return error;
}
-Static int
+int
uath_write_multi(struct uath_softc *sc, uint32_t reg, const void *data,
int len)
{
@@ -1071,7 +1071,7 @@ uath_write_multi(struct uath_softc *sc, uint32_t reg, const void *data,
return error;
}
-Static int
+int
uath_read_reg(struct uath_softc *sc, uint32_t reg, uint32_t *val)
{
struct uath_read_mac read;
@@ -1089,7 +1089,7 @@ uath_read_reg(struct uath_softc *sc, uint32_t reg, uint32_t *val)
return error;
}
-Static int
+int
uath_read_eeprom(struct uath_softc *sc, uint32_t reg, void *odata)
{
struct uath_read_mac read;
@@ -1108,7 +1108,7 @@ uath_read_eeprom(struct uath_softc *sc, uint32_t reg, void *odata)
return error;
}
-Static void
+void
uath_cmd_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -1170,7 +1170,7 @@ uath_cmd_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv,
(void)usbd_transfer(xfer);
}
-Static void
+void
uath_data_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -1298,7 +1298,7 @@ skip: /* setup a new transfer */
(void)usbd_transfer(data->xfer);
}
-Static int
+int
uath_tx_null(struct uath_softc *sc)
{
struct uath_tx_data *data;
@@ -1326,7 +1326,7 @@ uath_tx_null(struct uath_softc *sc)
return uath_cmd_write(sc, UATH_CMD_0F, NULL, 0, UATH_CMD_FLAG_ASYNC);
}
-Static void
+void
uath_data_txeof(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -1365,7 +1365,7 @@ uath_data_txeof(usbd_xfer_handle xfer, usbd_private_handle priv,
splx(s);
}
-Static int
+int
uath_tx_data(struct uath_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
{
struct ieee80211com *ic = &sc->sc_ic;
@@ -1471,7 +1471,7 @@ uath_tx_data(struct uath_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
return 0;
}
-Static void
+void
uath_start(struct ifnet *ifp)
{
struct uath_softc *sc = ifp->if_softc;
@@ -1538,7 +1538,7 @@ uath_start(struct ifnet *ifp)
}
}
-Static void
+void
uath_watchdog(struct ifnet *ifp)
{
struct uath_softc *sc = ifp->if_softc;
@@ -1558,7 +1558,7 @@ uath_watchdog(struct ifnet *ifp)
ieee80211_watchdog(ifp);
}
-Static int
+int
uath_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct uath_softc *sc = ifp->if_softc;
@@ -1614,7 +1614,7 @@ uath_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
return error;
}
-Static int
+int
uath_query_eeprom(struct uath_softc *sc)
{
uint32_t tmp;
@@ -1640,7 +1640,7 @@ uath_query_eeprom(struct uath_softc *sc)
return 0;
}
-Static int
+int
uath_reset(struct uath_softc *sc)
{
struct uath_cmd_setup setup;
@@ -1674,7 +1674,7 @@ uath_reset(struct uath_softc *sc)
return error;
}
-Static int
+int
uath_reset_tx_queues(struct uath_softc *sc)
{
int ac, error;
@@ -1691,7 +1691,7 @@ uath_reset_tx_queues(struct uath_softc *sc)
return error;
}
-Static int
+int
uath_wme_init(struct uath_softc *sc)
{
struct uath_qinfo qinfo;
@@ -1726,7 +1726,7 @@ uath_wme_init(struct uath_softc *sc)
return error;
}
-Static int
+int
uath_set_chan(struct uath_softc *sc, struct ieee80211_channel *c)
{
struct uath_set_chan chan;
@@ -1743,7 +1743,7 @@ uath_set_chan(struct uath_softc *sc, struct ieee80211_channel *c)
return uath_cmd_write(sc, UATH_CMD_SET_CHAN, &chan, sizeof chan, 0);
}
-Static int
+int
uath_set_key(struct uath_softc *sc, const struct ieee80211_wepkey *wk,
int index)
{
@@ -1771,7 +1771,7 @@ uath_set_key(struct uath_softc *sc, const struct ieee80211_wepkey *wk,
return uath_cmd_write(sc, UATH_CMD_CRYPTO, &crypto, sizeof crypto, 0);
}
-Static int
+int
uath_set_keys(struct uath_softc *sc)
{
const struct ieee80211com *ic = &sc->sc_ic;
@@ -1788,7 +1788,7 @@ uath_set_keys(struct uath_softc *sc)
UATH_DEFAULT_KEY);
}
-Static int
+int
uath_set_rates(struct uath_softc *sc, const struct ieee80211_rateset *rs)
{
struct uath_cmd_rates rates;
@@ -1803,7 +1803,7 @@ uath_set_rates(struct uath_softc *sc, const struct ieee80211_rateset *rs)
return uath_cmd_write(sc, UATH_CMD_SET_RATES, &rates, sizeof rates, 0);
}
-Static int
+int
uath_set_rxfilter(struct uath_softc *sc, uint32_t filter, uint32_t flags)
{
struct uath_cmd_filter rxfilter;
@@ -1816,7 +1816,7 @@ uath_set_rxfilter(struct uath_softc *sc, uint32_t filter, uint32_t flags)
sizeof rxfilter, 0);
}
-Static int
+int
uath_set_led(struct uath_softc *sc, int which, int on)
{
struct uath_cmd_led led;
@@ -1830,7 +1830,7 @@ uath_set_led(struct uath_softc *sc, int which, int on)
return uath_cmd_write(sc, UATH_CMD_SET_LED, &led, sizeof led, 0);
}
-Static int
+int
uath_switch_channel(struct uath_softc *sc, struct ieee80211_channel *c)
{
uint32_t val;
@@ -1866,7 +1866,7 @@ uath_switch_channel(struct uath_softc *sc, struct ieee80211_channel *c)
return uath_tx_null(sc);
}
-Static int
+int
uath_init(struct ifnet *ifp)
{
struct uath_softc *sc = ifp->if_softc;
@@ -1975,7 +1975,7 @@ fail: uath_stop(ifp, 1);
return error;
}
-Static void
+void
uath_stop(struct ifnet *ifp, int disable)
{
struct uath_softc *sc = ifp->if_softc;
@@ -2017,7 +2017,7 @@ uath_stop(struct ifnet *ifp, int disable)
* product Id (a la ezusb). XXX this could also be implemented in userland
* through /dev/ugen.
*/
-Static int
+int
uath_loadfirmware(struct uath_softc *sc, const u_char *fw, int len)
{
usbd_xfer_handle ctlxfer, txxfer, rxxfer;
@@ -2122,7 +2122,7 @@ fail2: usbd_free_xfer(ctlxfer);
fail1: return error;
}
-Static int
+int
uath_activate(device_ptr_t self, enum devact act)
{
switch (act) {
diff --git a/sys/dev/usb/if_udav.c b/sys/dev/usb/if_udav.c
index a70d6626bb5..c502fc47700 100644
--- a/sys/dev/usb/if_udav.c
+++ b/sys/dev/usb/if_udav.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_udav.c,v 1.25 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: if_udav.c,v 1.26 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: if_udav.c,v 1.3 2004/04/23 17:25:25 itojun Exp $ */
/* $nabe: if_udav.c,v 1.3 2003/08/21 16:57:19 nabe Exp $ */
/*
@@ -89,40 +89,40 @@
/* Function declarations */
USB_DECLARE_DRIVER_CLASS(udav, DV_IFNET);
-Static int udav_openpipes(struct udav_softc *);
-Static int udav_rx_list_init(struct udav_softc *);
-Static int udav_tx_list_init(struct udav_softc *);
-Static int udav_newbuf(struct udav_softc *, struct udav_chain *, struct mbuf *);
-Static void udav_start(struct ifnet *);
-Static int udav_send(struct udav_softc *, struct mbuf *, int);
-Static void udav_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void udav_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void udav_tick(void *);
-Static void udav_tick_task(void *);
-Static int udav_ioctl(struct ifnet *, u_long, caddr_t);
-Static void udav_stop_task(struct udav_softc *);
-Static void udav_stop(struct ifnet *, int);
-Static void udav_watchdog(struct ifnet *);
-Static int udav_ifmedia_change(struct ifnet *);
-Static void udav_ifmedia_status(struct ifnet *, struct ifmediareq *);
-Static void udav_lock_mii(struct udav_softc *);
-Static void udav_unlock_mii(struct udav_softc *);
-Static int udav_miibus_readreg(device_ptr_t, int, int);
-Static void udav_miibus_writereg(device_ptr_t, int, int, int);
-Static void udav_miibus_statchg(device_ptr_t);
-Static int udav_init(struct ifnet *);
-Static void udav_setmulti(struct udav_softc *);
-Static void udav_reset(struct udav_softc *);
-
-Static int udav_csr_read(struct udav_softc *, int, void *, int);
-Static int udav_csr_write(struct udav_softc *, int, void *, int);
-Static int udav_csr_read1(struct udav_softc *, int);
-Static int udav_csr_write1(struct udav_softc *, int, unsigned char);
+int udav_openpipes(struct udav_softc *);
+int udav_rx_list_init(struct udav_softc *);
+int udav_tx_list_init(struct udav_softc *);
+int udav_newbuf(struct udav_softc *, struct udav_chain *, struct mbuf *);
+void udav_start(struct ifnet *);
+int udav_send(struct udav_softc *, struct mbuf *, int);
+void udav_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void udav_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void udav_tick(void *);
+void udav_tick_task(void *);
+int udav_ioctl(struct ifnet *, u_long, caddr_t);
+void udav_stop_task(struct udav_softc *);
+void udav_stop(struct ifnet *, int);
+void udav_watchdog(struct ifnet *);
+int udav_ifmedia_change(struct ifnet *);
+void udav_ifmedia_status(struct ifnet *, struct ifmediareq *);
+void udav_lock_mii(struct udav_softc *);
+void udav_unlock_mii(struct udav_softc *);
+int udav_miibus_readreg(device_ptr_t, int, int);
+void udav_miibus_writereg(device_ptr_t, int, int, int);
+void udav_miibus_statchg(device_ptr_t);
+int udav_init(struct ifnet *);
+void udav_setmulti(struct udav_softc *);
+void udav_reset(struct udav_softc *);
+
+int udav_csr_read(struct udav_softc *, int, void *, int);
+int udav_csr_write(struct udav_softc *, int, void *, int);
+int udav_csr_read1(struct udav_softc *, int);
+int udav_csr_write1(struct udav_softc *, int, unsigned char);
#if 0
-Static int udav_mem_read(struct udav_softc *, int, void *, int);
-Static int udav_mem_write(struct udav_softc *, int, void *, int);
-Static int udav_mem_write1(struct udav_softc *, int, unsigned char);
+int udav_mem_read(struct udav_softc *, int, void *, int);
+int udav_mem_write(struct udav_softc *, int, void *, int);
+int udav_mem_write1(struct udav_softc *, int, unsigned char);
#endif
/* Macros */
@@ -360,7 +360,7 @@ udav_detach(struct device *self, int flags)
#if 0
/* read memory */
-Static int
+int
udav_mem_read(struct udav_softc *sc, int offset, void *buf, int len)
{
usb_device_request_t req;
@@ -397,7 +397,7 @@ udav_mem_read(struct udav_softc *sc, int offset, void *buf, int len)
}
/* write memory */
-Static int
+int
udav_mem_write(struct udav_softc *sc, int offset, void *buf, int len)
{
usb_device_request_t req;
@@ -434,7 +434,7 @@ udav_mem_write(struct udav_softc *sc, int offset, void *buf, int len)
}
/* write memory */
-Static int
+int
udav_mem_write1(struct udav_softc *sc, int offset, unsigned char ch)
{
usb_device_request_t req;
@@ -471,7 +471,7 @@ udav_mem_write1(struct udav_softc *sc, int offset, unsigned char ch)
#endif
/* read register(s) */
-Static int
+int
udav_csr_read(struct udav_softc *sc, int offset, void *buf, int len)
{
usb_device_request_t req;
@@ -508,7 +508,7 @@ udav_csr_read(struct udav_softc *sc, int offset, void *buf, int len)
}
/* write register(s) */
-Static int
+int
udav_csr_write(struct udav_softc *sc, int offset, void *buf, int len)
{
usb_device_request_t req;
@@ -544,7 +544,7 @@ udav_csr_write(struct udav_softc *sc, int offset, void *buf, int len)
return (err);
}
-Static int
+int
udav_csr_read1(struct udav_softc *sc, int offset)
{
u_int8_t val = 0;
@@ -562,7 +562,7 @@ udav_csr_read1(struct udav_softc *sc, int offset)
}
/* write a register */
-Static int
+int
udav_csr_write1(struct udav_softc *sc, int offset, unsigned char ch)
{
usb_device_request_t req;
@@ -597,7 +597,7 @@ udav_csr_write1(struct udav_softc *sc, int offset, unsigned char ch)
return (err);
}
-Static int
+int
udav_init(struct ifnet *ifp)
{
struct udav_softc *sc = ifp->if_softc;
@@ -674,7 +674,7 @@ udav_init(struct ifnet *ifp)
return (0);
}
-Static void
+void
udav_reset(struct udav_softc *sc)
{
int i;
@@ -733,7 +733,7 @@ udav_activate(device_ptr_t self, enum devact act)
#define UDAV_CALCHASH(addr) \
(ether_crc32_le((addr), ETHER_ADDR_LEN) & ((1 << UDAV_BITS) - 1))
-Static void
+void
udav_setmulti(struct udav_softc *sc)
{
struct ifnet *ifp;
@@ -785,7 +785,7 @@ udav_setmulti(struct udav_softc *sc)
udav_csr_write(sc, UDAV_MAR, hashes, sizeof(hashes));
}
-Static int
+int
udav_openpipes(struct udav_softc *sc)
{
struct udav_chain *c;
@@ -853,7 +853,7 @@ udav_openpipes(struct udav_softc *sc)
return (error);
}
-Static int
+int
udav_newbuf(struct udav_softc *sc, struct udav_chain *c, struct mbuf *m)
{
struct mbuf *m_new = NULL;
@@ -888,7 +888,7 @@ udav_newbuf(struct udav_softc *sc, struct udav_chain *c, struct mbuf *m)
}
-Static int
+int
udav_rx_list_init(struct udav_softc *sc)
{
struct udav_cdata *cd;
@@ -919,7 +919,7 @@ udav_rx_list_init(struct udav_softc *sc)
return (0);
}
-Static int
+int
udav_tx_list_init(struct udav_softc *sc)
{
struct udav_cdata *cd;
@@ -949,7 +949,7 @@ udav_tx_list_init(struct udav_softc *sc)
return (0);
}
-Static void
+void
udav_start(struct ifnet *ifp)
{
struct udav_softc *sc = ifp->if_softc;
@@ -989,7 +989,7 @@ udav_start(struct ifnet *ifp)
ifp->if_timer = 5;
}
-Static int
+int
udav_send(struct udav_softc *sc, struct mbuf *m, int idx)
{
int total_len;
@@ -1041,7 +1041,7 @@ udav_send(struct udav_softc *sc, struct mbuf *m, int idx)
return (0);
}
-Static void
+void
udav_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct udav_chain *c = priv;
@@ -1088,7 +1088,7 @@ udav_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static void
+void
udav_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct udav_chain *c = priv;
@@ -1183,12 +1183,12 @@ udav_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
}
#if 0
-Static void udav_intr()
+void udav_intr()
{
}
#endif
-Static int
+int
udav_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct udav_softc *sc = ifp->if_softc;
@@ -1269,7 +1269,7 @@ udav_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
return (error);
}
-Static void
+void
udav_watchdog(struct ifnet *ifp)
{
struct udav_softc *sc = ifp->if_softc;
@@ -1292,14 +1292,14 @@ udav_watchdog(struct ifnet *ifp)
splx(s);
}
-Static void
+void
udav_stop_task(struct udav_softc *sc)
{
udav_stop(GET_IFP(sc), 1);
}
/* Stop the adapter and free any mbufs allocated to the RX and TX lists. */
-Static void
+void
udav_stop(struct ifnet *ifp, int disable)
{
struct udav_softc *sc = ifp->if_softc;
@@ -1386,7 +1386,7 @@ udav_stop(struct ifnet *ifp, int disable)
}
/* Set media options */
-Static int
+int
udav_ifmedia_change(struct ifnet *ifp)
{
struct udav_softc *sc = ifp->if_softc;
@@ -1409,7 +1409,7 @@ udav_ifmedia_change(struct ifnet *ifp)
}
/* Report current media status. */
-Static void
+void
udav_ifmedia_status(struct ifnet *ifp, struct ifmediareq *ifmr)
{
struct udav_softc *sc = ifp->if_softc;
@@ -1431,7 +1431,7 @@ udav_ifmedia_status(struct ifnet *ifp, struct ifmediareq *ifmr)
ifmr->ifm_status = mii->mii_media_status;
}
-Static void
+void
udav_tick(void *xsc)
{
struct udav_softc *sc = xsc;
@@ -1449,7 +1449,7 @@ udav_tick(void *xsc)
usb_add_task(sc->sc_udev, &sc->sc_tick_task);
}
-Static void
+void
udav_tick_task(void *xsc)
{
struct udav_softc *sc = xsc;
@@ -1490,7 +1490,7 @@ udav_tick_task(void *xsc)
}
/* Get exclusive access to the MII registers */
-Static void
+void
udav_lock_mii(struct udav_softc *sc)
{
DPRINTFN(0xff, ("%s: %s: enter\n", USBDEVNAME(sc->sc_dev),
@@ -1500,7 +1500,7 @@ udav_lock_mii(struct udav_softc *sc)
rw_enter_write(&sc->sc_mii_lock);
}
-Static void
+void
udav_unlock_mii(struct udav_softc *sc)
{
DPRINTFN(0xff, ("%s: %s: enter\n", USBDEVNAME(sc->sc_dev),
@@ -1511,7 +1511,7 @@ udav_unlock_mii(struct udav_softc *sc)
usb_detach_wakeup(USBDEV(sc->sc_dev));
}
-Static int
+int
udav_miibus_readreg(device_ptr_t dev, int phy, int reg)
{
struct udav_softc *sc;
@@ -1568,7 +1568,7 @@ udav_miibus_readreg(device_ptr_t dev, int phy, int reg)
return (data16);
}
-Static void
+void
udav_miibus_writereg(device_ptr_t dev, int phy, int reg, int data)
{
struct udav_softc *sc;
@@ -1621,7 +1621,7 @@ udav_miibus_writereg(device_ptr_t dev, int phy, int reg, int data)
return;
}
-Static void
+void
udav_miibus_statchg(device_ptr_t dev)
{
#ifdef UDAV_DEBUG
diff --git a/sys/dev/usb/if_upl.c b/sys/dev/usb/if_upl.c
index f408cd7ab51..51334651104 100644
--- a/sys/dev/usb/if_upl.c
+++ b/sys/dev/usb/if_upl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_upl.c,v 1.29 2007/06/01 06:12:20 mbalmer Exp $ */
+/* $OpenBSD: if_upl.c,v 1.30 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: if_upl.c,v 1.19 2002/07/11 21:14:26 augustss Exp $ */
/*
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -171,7 +171,7 @@ int upldebug = 0;
/*
* Various supported device vendors/products.
*/
-Static struct upl_type sc_devs[] = {
+struct upl_type sc_devs[] = {
{ USB_VENDOR_PROLIFIC, USB_PRODUCT_PROLIFIC_PL2301 },
{ USB_VENDOR_PROLIFIC, USB_PRODUCT_PROLIFIC_PL2302 },
{ 0, 0 }
@@ -179,23 +179,23 @@ Static struct upl_type sc_devs[] = {
USB_DECLARE_DRIVER_CLASS(upl, DV_IFNET);
-Static int upl_openpipes(struct upl_softc *);
-Static int upl_tx_list_init(struct upl_softc *);
-Static int upl_rx_list_init(struct upl_softc *);
-Static int upl_newbuf(struct upl_softc *, struct upl_chain *, struct mbuf *);
-Static int upl_send(struct upl_softc *, struct mbuf *, int);
-Static void upl_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void upl_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void upl_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void upl_start(struct ifnet *);
-Static int upl_ioctl(struct ifnet *, u_long, caddr_t);
-Static void upl_init(void *);
-Static void upl_stop(struct upl_softc *);
-Static void upl_watchdog(struct ifnet *);
-
-Static int upl_output(struct ifnet *, struct mbuf *, struct sockaddr *,
+int upl_openpipes(struct upl_softc *);
+int upl_tx_list_init(struct upl_softc *);
+int upl_rx_list_init(struct upl_softc *);
+int upl_newbuf(struct upl_softc *, struct upl_chain *, struct mbuf *);
+int upl_send(struct upl_softc *, struct mbuf *, int);
+void upl_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void upl_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void upl_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void upl_start(struct ifnet *);
+int upl_ioctl(struct ifnet *, u_long, caddr_t);
+void upl_init(void *);
+void upl_stop(struct upl_softc *);
+void upl_watchdog(struct ifnet *);
+
+int upl_output(struct ifnet *, struct mbuf *, struct sockaddr *,
struct rtentry *);
-Static void upl_input(struct ifnet *, struct mbuf *);
+void upl_input(struct ifnet *, struct mbuf *);
/*
* Probe for a Prolific chip.
@@ -376,7 +376,7 @@ upl_activate(device_ptr_t self, enum devact act)
/*
* Initialize an RX descriptor and attach an MBUF cluster.
*/
-Static int
+int
upl_newbuf(struct upl_softc *sc, struct upl_chain *c, struct mbuf *m)
{
struct mbuf *m_new = NULL;
@@ -410,7 +410,7 @@ upl_newbuf(struct upl_softc *sc, struct upl_chain *c, struct mbuf *m)
return (0);
}
-Static int
+int
upl_rx_list_init(struct upl_softc *sc)
{
struct upl_cdata *cd;
@@ -441,7 +441,7 @@ upl_rx_list_init(struct upl_softc *sc)
return (0);
}
-Static int
+int
upl_tx_list_init(struct upl_softc *sc)
{
struct upl_cdata *cd;
@@ -475,7 +475,7 @@ upl_tx_list_init(struct upl_softc *sc)
* A frame has been uploaded: pass the resulting mbuf chain up to
* the higher level protocols.
*/
-Static void
+void
upl_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct upl_chain *c = priv;
@@ -564,7 +564,7 @@ upl_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
* A frame was downloaded to the chip. It's safe for us to clean up
* the list buffers.
*/
-Static void
+void
upl_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct upl_chain *c = priv;
@@ -608,7 +608,7 @@ upl_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static int
+int
upl_send(struct upl_softc *sc, struct mbuf *m, int idx)
{
int total_len;
@@ -647,7 +647,7 @@ upl_send(struct upl_softc *sc, struct mbuf *m, int idx)
return (0);
}
-Static void
+void
upl_start(struct ifnet *ifp)
{
struct upl_softc *sc = ifp->if_softc;
@@ -689,7 +689,7 @@ upl_start(struct ifnet *ifp)
ifp->if_timer = 5;
}
-Static void
+void
upl_init(void *xsc)
{
struct upl_softc *sc = xsc;
@@ -733,7 +733,7 @@ upl_init(void *xsc)
splx(s);
}
-Static int
+int
upl_openpipes(struct upl_softc *sc)
{
struct upl_chain *c;
@@ -781,7 +781,7 @@ upl_openpipes(struct upl_softc *sc)
return (0);
}
-Static void
+void
upl_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct upl_softc *sc = priv;
@@ -822,7 +822,7 @@ upl_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
}
-Static int
+int
upl_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct upl_softc *sc = ifp->if_softc;
@@ -878,7 +878,7 @@ upl_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
return (error);
}
-Static void
+void
upl_watchdog(struct ifnet *ifp)
{
struct upl_softc *sc = ifp->if_softc;
@@ -902,7 +902,7 @@ upl_watchdog(struct ifnet *ifp)
* Stop the adapter and free any mbufs allocated to the
* RX and TX lists.
*/
-Static void
+void
upl_stop(struct upl_softc *sc)
{
usbd_status err;
@@ -983,7 +983,7 @@ upl_stop(struct upl_softc *sc)
}
}
-Static int
+int
upl_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst,
struct rtentry *rt0)
{
@@ -1013,7 +1013,7 @@ upl_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst,
return (0);
}
-Static void
+void
upl_input(struct ifnet *ifp, struct mbuf *m)
{
struct ifqueue *inq;
diff --git a/sys/dev/usb/if_url.c b/sys/dev/usb/if_url.c
index 3b5a9e59887..941bb960535 100644
--- a/sys/dev/usb/if_url.c
+++ b/sys/dev/usb/if_url.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_url.c,v 1.39 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: if_url.c,v 1.40 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: if_url.c,v 1.6 2002/09/29 10:19:21 martin Exp $ */
/*
* Copyright (c) 2001, 2002
@@ -87,37 +87,37 @@
/* Function declarations */
USB_DECLARE_DRIVER_CLASS(url, DV_IFNET);
-Static int url_openpipes(struct url_softc *);
-Static int url_rx_list_init(struct url_softc *);
-Static int url_tx_list_init(struct url_softc *);
-Static int url_newbuf(struct url_softc *, struct url_chain *, struct mbuf *);
-Static void url_start(struct ifnet *);
-Static int url_send(struct url_softc *, struct mbuf *, int);
-Static void url_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void url_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void url_tick(void *);
-Static void url_tick_task(void *);
-Static int url_ioctl(struct ifnet *, u_long, caddr_t);
-Static void url_stop_task(struct url_softc *);
-Static void url_stop(struct ifnet *, int);
-Static void url_watchdog(struct ifnet *);
-Static int url_ifmedia_change(struct ifnet *);
-Static void url_ifmedia_status(struct ifnet *, struct ifmediareq *);
-Static void url_lock_mii(struct url_softc *);
-Static void url_unlock_mii(struct url_softc *);
-Static int url_int_miibus_readreg(device_ptr_t, int, int);
-Static void url_int_miibus_writereg(device_ptr_t, int, int, int);
-Static void url_miibus_statchg(device_ptr_t);
-Static int url_init(struct ifnet *);
-Static void url_setmulti(struct url_softc *);
-Static void url_reset(struct url_softc *);
-
-Static int url_csr_read_1(struct url_softc *, int);
-Static int url_csr_read_2(struct url_softc *, int);
-Static int url_csr_write_1(struct url_softc *, int, int);
-Static int url_csr_write_2(struct url_softc *, int, int);
-Static int url_csr_write_4(struct url_softc *, int, int);
-Static int url_mem(struct url_softc *, int, int, void *, int);
+int url_openpipes(struct url_softc *);
+int url_rx_list_init(struct url_softc *);
+int url_tx_list_init(struct url_softc *);
+int url_newbuf(struct url_softc *, struct url_chain *, struct mbuf *);
+void url_start(struct ifnet *);
+int url_send(struct url_softc *, struct mbuf *, int);
+void url_txeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void url_rxeof(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void url_tick(void *);
+void url_tick_task(void *);
+int url_ioctl(struct ifnet *, u_long, caddr_t);
+void url_stop_task(struct url_softc *);
+void url_stop(struct ifnet *, int);
+void url_watchdog(struct ifnet *);
+int url_ifmedia_change(struct ifnet *);
+void url_ifmedia_status(struct ifnet *, struct ifmediareq *);
+void url_lock_mii(struct url_softc *);
+void url_unlock_mii(struct url_softc *);
+int url_int_miibus_readreg(device_ptr_t, int, int);
+void url_int_miibus_writereg(device_ptr_t, int, int, int);
+void url_miibus_statchg(device_ptr_t);
+int url_init(struct ifnet *);
+void url_setmulti(struct url_softc *);
+void url_reset(struct url_softc *);
+
+int url_csr_read_1(struct url_softc *, int);
+int url_csr_read_2(struct url_softc *, int);
+int url_csr_write_1(struct url_softc *, int, int);
+int url_csr_write_2(struct url_softc *, int, int);
+int url_csr_write_4(struct url_softc *, int, int);
+int url_mem(struct url_softc *, int, int, void *, int);
/* Macros */
#ifdef URL_DEBUG
@@ -370,7 +370,7 @@ url_detach(struct device *self, int flags)
}
/* read/write memory */
-Static int
+int
url_mem(struct url_softc *sc, int cmd, int offset, void *buf, int len)
{
usb_device_request_t req;
@@ -409,7 +409,7 @@ url_mem(struct url_softc *sc, int cmd, int offset, void *buf, int len)
}
/* read 1byte from register */
-Static int
+int
url_csr_read_1(struct url_softc *sc, int reg)
{
u_int8_t val = 0;
@@ -424,7 +424,7 @@ url_csr_read_1(struct url_softc *sc, int reg)
}
/* read 2bytes from register */
-Static int
+int
url_csr_read_2(struct url_softc *sc, int reg)
{
uWord val;
@@ -440,7 +440,7 @@ url_csr_read_2(struct url_softc *sc, int reg)
}
/* write 1byte to register */
-Static int
+int
url_csr_write_1(struct url_softc *sc, int reg, int aval)
{
u_int8_t val = aval;
@@ -455,7 +455,7 @@ url_csr_write_1(struct url_softc *sc, int reg, int aval)
}
/* write 2bytes to register */
-Static int
+int
url_csr_write_2(struct url_softc *sc, int reg, int aval)
{
uWord val;
@@ -472,7 +472,7 @@ url_csr_write_2(struct url_softc *sc, int reg, int aval)
}
/* write 4bytes to register */
-Static int
+int
url_csr_write_4(struct url_softc *sc, int reg, int aval)
{
uDWord val;
@@ -488,7 +488,7 @@ url_csr_write_4(struct url_softc *sc, int reg, int aval)
return (url_mem(sc, URL_CMD_WRITEMEM, reg, &val, 4) ? -1 : 0);
}
-Static int
+int
url_init(struct ifnet *ifp)
{
struct url_softc *sc = ifp->if_softc;
@@ -569,7 +569,7 @@ url_init(struct ifnet *ifp)
return (0);
}
-Static void
+void
url_reset(struct url_softc *sc)
{
int i;
@@ -614,7 +614,7 @@ url_activate(device_ptr_t self, enum devact act)
#define url_calchash(addr) (ether_crc32_be((addr), ETHER_ADDR_LEN) >> 26)
-Static void
+void
url_setmulti(struct url_softc *sc)
{
struct ifnet *ifp;
@@ -675,7 +675,7 @@ url_setmulti(struct url_softc *sc)
url_csr_write_4(sc, URL_MAR4, hashes[1]);
}
-Static int
+int
url_openpipes(struct url_softc *sc)
{
struct url_chain *c;
@@ -743,7 +743,7 @@ url_openpipes(struct url_softc *sc)
return (error);
}
-Static int
+int
url_newbuf(struct url_softc *sc, struct url_chain *c, struct mbuf *m)
{
struct mbuf *m_new = NULL;
@@ -778,7 +778,7 @@ url_newbuf(struct url_softc *sc, struct url_chain *c, struct mbuf *m)
}
-Static int
+int
url_rx_list_init(struct url_softc *sc)
{
struct url_cdata *cd;
@@ -809,7 +809,7 @@ url_rx_list_init(struct url_softc *sc)
return (0);
}
-Static int
+int
url_tx_list_init(struct url_softc *sc)
{
struct url_cdata *cd;
@@ -839,7 +839,7 @@ url_tx_list_init(struct url_softc *sc)
return (0);
}
-Static void
+void
url_start(struct ifnet *ifp)
{
struct url_softc *sc = ifp->if_softc;
@@ -879,7 +879,7 @@ url_start(struct ifnet *ifp)
ifp->if_timer = 5;
}
-Static int
+int
url_send(struct url_softc *sc, struct mbuf *m, int idx)
{
int total_len;
@@ -924,7 +924,7 @@ url_send(struct url_softc *sc, struct mbuf *m, int idx)
return (0);
}
-Static void
+void
url_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct url_chain *c = priv;
@@ -971,7 +971,7 @@ url_txeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
splx(s);
}
-Static void
+void
url_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct url_chain *c = priv;
@@ -1070,12 +1070,12 @@ url_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
}
#if 0
-Static void url_intr()
+void url_intr()
{
}
#endif
-Static int
+int
url_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct url_softc *sc = ifp->if_softc;
@@ -1157,7 +1157,7 @@ url_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
return (error);
}
-Static void
+void
url_watchdog(struct ifnet *ifp)
{
struct url_softc *sc = ifp->if_softc;
@@ -1180,14 +1180,14 @@ url_watchdog(struct ifnet *ifp)
splx(s);
}
-Static void
+void
url_stop_task(struct url_softc *sc)
{
url_stop(GET_IFP(sc), 1);
}
/* Stop the adapter and free any mbufs allocated to the RX and TX lists. */
-Static void
+void
url_stop(struct ifnet *ifp, int disable)
{
struct url_softc *sc = ifp->if_softc;
@@ -1274,7 +1274,7 @@ url_stop(struct ifnet *ifp, int disable)
}
/* Set media options */
-Static int
+int
url_ifmedia_change(struct ifnet *ifp)
{
struct url_softc *sc = ifp->if_softc;
@@ -1297,7 +1297,7 @@ url_ifmedia_change(struct ifnet *ifp)
}
/* Report current media status. */
-Static void
+void
url_ifmedia_status(struct ifnet *ifp, struct ifmediareq *ifmr)
{
struct url_softc *sc = ifp->if_softc;
@@ -1319,7 +1319,7 @@ url_ifmedia_status(struct ifnet *ifp, struct ifmediareq *ifmr)
ifmr->ifm_status = mii->mii_media_status;
}
-Static void
+void
url_tick(void *xsc)
{
struct url_softc *sc = xsc;
@@ -1337,7 +1337,7 @@ url_tick(void *xsc)
usb_add_task(sc->sc_udev, &sc->sc_tick_task);
}
-Static void
+void
url_tick_task(void *xsc)
{
struct url_softc *sc = xsc;
@@ -1378,7 +1378,7 @@ url_tick_task(void *xsc)
}
/* Get exclusive access to the MII registers */
-Static void
+void
url_lock_mii(struct url_softc *sc)
{
DPRINTFN(0xff, ("%s: %s: enter\n", USBDEVNAME(sc->sc_dev),
@@ -1388,7 +1388,7 @@ url_lock_mii(struct url_softc *sc)
rw_enter_write(&sc->sc_mii_lock);
}
-Static void
+void
url_unlock_mii(struct url_softc *sc)
{
DPRINTFN(0xff, ("%s: %s: enter\n", USBDEVNAME(sc->sc_dev),
@@ -1399,7 +1399,7 @@ url_unlock_mii(struct url_softc *sc)
usb_detach_wakeup(USBDEV(sc->sc_dev));
}
-Static int
+int
url_int_miibus_readreg(device_ptr_t dev, int phy, int reg)
{
struct url_softc *sc;
@@ -1472,7 +1472,7 @@ url_int_miibus_readreg(device_ptr_t dev, int phy, int reg)
return (val);
}
-Static void
+void
url_int_miibus_writereg(device_ptr_t dev, int phy, int reg, int data)
{
struct url_softc *sc;
@@ -1539,7 +1539,7 @@ url_int_miibus_writereg(device_ptr_t dev, int phy, int reg, int data)
return;
}
-Static void
+void
url_miibus_statchg(device_ptr_t dev)
{
#ifdef URL_DEBUG
@@ -1558,7 +1558,7 @@ url_miibus_statchg(device_ptr_t dev)
/*
* external PHYs support, but not test.
*/
-Static int
+int
url_ext_miibus_redreg(device_ptr_t dev, int phy, int reg)
{
struct url_softc *sc = USBGETSOFTC(dev);
@@ -1602,7 +1602,7 @@ url_ext_miibus_redreg(device_ptr_t dev, int phy, int reg)
return (val);
}
-Static void
+void
url_ext_miibus_writereg(device_ptr_t dev, int phy, int reg, int data)
{
struct url_softc *sc = USBGETSOFTC(dev);
diff --git a/sys/dev/usb/moscom.c b/sys/dev/usb/moscom.c
index 65655d57b47..734e067e9be 100644
--- a/sys/dev/usb/moscom.c
+++ b/sys/dev/usb/moscom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: moscom.c,v 1.3 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: moscom.c,v 1.4 2007/06/05 08:43:55 mbalmer Exp $ */
/*
* Copyright (c) 2006 Jonathan Gray <jsg@openbsd.org>
@@ -145,11 +145,11 @@ struct moscom_softc {
u_char sc_dying;
};
-Static void moscom_get_status(void *, int, u_char *, u_char *);
-Static void moscom_set(void *, int, int, int);
-Static int moscom_param(void *, int, struct termios *);
-Static int moscom_open(void *, int);
-Static int moscom_cmd(struct moscom_softc *, int, int);
+void moscom_get_status(void *, int, u_char *, u_char *);
+void moscom_set(void *, int, int, int);
+int moscom_param(void *, int, struct termios *);
+int moscom_open(void *, int);
+int moscom_cmd(struct moscom_softc *, int, int);
struct ucom_methods moscom_methods = {
NULL,
@@ -294,7 +294,7 @@ moscom_activate(device_ptr_t self, enum devact act)
return (rv);
}
-Static int
+int
moscom_open(void *vsc, int portno)
{
struct moscom_softc *sc = vsc;
@@ -324,7 +324,7 @@ moscom_open(void *vsc, int portno)
return (0);
}
-Static void
+void
moscom_set(void *vsc, int portno, int reg, int onoff)
{
struct moscom_softc *sc = vsc;
@@ -350,7 +350,7 @@ moscom_set(void *vsc, int portno, int reg, int onoff)
moscom_cmd(sc, MOSCOM_MCR, val);
}
-Static int
+int
moscom_param(void *vsc, int portno, struct termios *t)
{
struct moscom_softc *sc = (struct moscom_softc *)vsc;
@@ -411,7 +411,7 @@ moscom_param(void *vsc, int portno, struct termios *t)
return (0);
}
-Static void
+void
moscom_get_status(void *vsc, int portno, u_char *lsr, u_char *msr)
{
struct moscom_softc *sc = vsc;
@@ -422,7 +422,7 @@ moscom_get_status(void *vsc, int portno, u_char *lsr, u_char *msr)
*lsr = sc->sc_lsr;
}
-Static int
+int
moscom_cmd(struct moscom_softc *sc, int reg, int val)
{
usb_device_request_t req;
diff --git a/sys/dev/usb/ohci.c b/sys/dev/usb/ohci.c
index efce97685d7..23064422c6c 100644
--- a/sys/dev/usb/ohci.c
+++ b/sys/dev/usb/ohci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ohci.c,v 1.78 2007/05/21 06:10:43 jsg Exp $ */
+/* $OpenBSD: ohci.c,v 1.79 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: ohci.c,v 1.139 2003/02/22 05:24:16 tsutsui Exp $ */
/* $FreeBSD: src/sys/dev/usb/ohci.c,v 1.22 1999/11/17 22:33:40 n_hibma Exp $ */
@@ -88,109 +88,109 @@ int ohcidebug = 0;
struct ohci_pipe;
-Static ohci_soft_ed_t *ohci_alloc_sed(ohci_softc_t *);
-Static void ohci_free_sed(ohci_softc_t *, ohci_soft_ed_t *);
+ohci_soft_ed_t *ohci_alloc_sed(ohci_softc_t *);
+void ohci_free_sed(ohci_softc_t *, ohci_soft_ed_t *);
-Static ohci_soft_td_t *ohci_alloc_std(ohci_softc_t *);
-Static void ohci_free_std(ohci_softc_t *, ohci_soft_td_t *);
+ohci_soft_td_t *ohci_alloc_std(ohci_softc_t *);
+void ohci_free_std(ohci_softc_t *, ohci_soft_td_t *);
-Static ohci_soft_itd_t *ohci_alloc_sitd(ohci_softc_t *);
-Static void ohci_free_sitd(ohci_softc_t *,ohci_soft_itd_t *);
+ohci_soft_itd_t *ohci_alloc_sitd(ohci_softc_t *);
+void ohci_free_sitd(ohci_softc_t *,ohci_soft_itd_t *);
#if 0
-Static void ohci_free_std_chain(ohci_softc_t *, ohci_soft_td_t *,
+void ohci_free_std_chain(ohci_softc_t *, ohci_soft_td_t *,
ohci_soft_td_t *);
#endif
-Static usbd_status ohci_alloc_std_chain(struct ohci_pipe *,
+usbd_status ohci_alloc_std_chain(struct ohci_pipe *,
ohci_softc_t *, int, int, usbd_xfer_handle,
ohci_soft_td_t *, ohci_soft_td_t **);
-Static void ohci_shutdown(void *v);
-Static usbd_status ohci_open(usbd_pipe_handle);
-Static void ohci_poll(struct usbd_bus *);
-Static void ohci_softintr(void *);
-Static void ohci_waitintr(ohci_softc_t *, usbd_xfer_handle);
-Static void ohci_add_done(ohci_softc_t *, ohci_physaddr_t);
-Static void ohci_rhsc(ohci_softc_t *, usbd_xfer_handle);
-
-Static usbd_status ohci_device_request(usbd_xfer_handle xfer);
-Static void ohci_add_ed(ohci_soft_ed_t *, ohci_soft_ed_t *);
-Static void ohci_rem_ed(ohci_soft_ed_t *, ohci_soft_ed_t *);
-Static void ohci_hash_add_td(ohci_softc_t *, ohci_soft_td_t *);
-Static void ohci_hash_rem_td(ohci_softc_t *, ohci_soft_td_t *);
-Static ohci_soft_td_t *ohci_hash_find_td(ohci_softc_t *, ohci_physaddr_t);
-Static void ohci_hash_add_itd(ohci_softc_t *, ohci_soft_itd_t *);
-Static void ohci_hash_rem_itd(ohci_softc_t *, ohci_soft_itd_t *);
-Static ohci_soft_itd_t *ohci_hash_find_itd(ohci_softc_t *, ohci_physaddr_t);
-
-Static usbd_status ohci_setup_isoc(usbd_pipe_handle pipe);
-Static void ohci_device_isoc_enter(usbd_xfer_handle);
-
-Static usbd_status ohci_allocm(struct usbd_bus *, usb_dma_t *, u_int32_t);
-Static void ohci_freem(struct usbd_bus *, usb_dma_t *);
-
-Static usbd_xfer_handle ohci_allocx(struct usbd_bus *);
-Static void ohci_freex(struct usbd_bus *, usbd_xfer_handle);
-
-Static usbd_status ohci_root_ctrl_transfer(usbd_xfer_handle);
-Static usbd_status ohci_root_ctrl_start(usbd_xfer_handle);
-Static void ohci_root_ctrl_abort(usbd_xfer_handle);
-Static void ohci_root_ctrl_close(usbd_pipe_handle);
-Static void ohci_root_ctrl_done(usbd_xfer_handle);
-
-Static usbd_status ohci_root_intr_transfer(usbd_xfer_handle);
-Static usbd_status ohci_root_intr_start(usbd_xfer_handle);
-Static void ohci_root_intr_abort(usbd_xfer_handle);
-Static void ohci_root_intr_close(usbd_pipe_handle);
-Static void ohci_root_intr_done(usbd_xfer_handle);
-
-Static usbd_status ohci_device_ctrl_transfer(usbd_xfer_handle);
-Static usbd_status ohci_device_ctrl_start(usbd_xfer_handle);
-Static void ohci_device_ctrl_abort(usbd_xfer_handle);
-Static void ohci_device_ctrl_close(usbd_pipe_handle);
-Static void ohci_device_ctrl_done(usbd_xfer_handle);
-
-Static usbd_status ohci_device_bulk_transfer(usbd_xfer_handle);
-Static usbd_status ohci_device_bulk_start(usbd_xfer_handle);
-Static void ohci_device_bulk_abort(usbd_xfer_handle);
-Static void ohci_device_bulk_close(usbd_pipe_handle);
-Static void ohci_device_bulk_done(usbd_xfer_handle);
-
-Static usbd_status ohci_device_intr_transfer(usbd_xfer_handle);
-Static usbd_status ohci_device_intr_start(usbd_xfer_handle);
-Static void ohci_device_intr_abort(usbd_xfer_handle);
-Static void ohci_device_intr_close(usbd_pipe_handle);
-Static void ohci_device_intr_done(usbd_xfer_handle);
-
-Static usbd_status ohci_device_isoc_transfer(usbd_xfer_handle);
-Static usbd_status ohci_device_isoc_start(usbd_xfer_handle);
-Static void ohci_device_isoc_abort(usbd_xfer_handle);
-Static void ohci_device_isoc_close(usbd_pipe_handle);
-Static void ohci_device_isoc_done(usbd_xfer_handle);
-
-Static usbd_status ohci_device_setintr(ohci_softc_t *sc,
+void ohci_shutdown(void *v);
+usbd_status ohci_open(usbd_pipe_handle);
+void ohci_poll(struct usbd_bus *);
+void ohci_softintr(void *);
+void ohci_waitintr(ohci_softc_t *, usbd_xfer_handle);
+void ohci_add_done(ohci_softc_t *, ohci_physaddr_t);
+void ohci_rhsc(ohci_softc_t *, usbd_xfer_handle);
+
+usbd_status ohci_device_request(usbd_xfer_handle xfer);
+void ohci_add_ed(ohci_soft_ed_t *, ohci_soft_ed_t *);
+void ohci_rem_ed(ohci_soft_ed_t *, ohci_soft_ed_t *);
+void ohci_hash_add_td(ohci_softc_t *, ohci_soft_td_t *);
+void ohci_hash_rem_td(ohci_softc_t *, ohci_soft_td_t *);
+ohci_soft_td_t *ohci_hash_find_td(ohci_softc_t *, ohci_physaddr_t);
+void ohci_hash_add_itd(ohci_softc_t *, ohci_soft_itd_t *);
+void ohci_hash_rem_itd(ohci_softc_t *, ohci_soft_itd_t *);
+ohci_soft_itd_t *ohci_hash_find_itd(ohci_softc_t *, ohci_physaddr_t);
+
+usbd_status ohci_setup_isoc(usbd_pipe_handle pipe);
+void ohci_device_isoc_enter(usbd_xfer_handle);
+
+usbd_status ohci_allocm(struct usbd_bus *, usb_dma_t *, u_int32_t);
+void ohci_freem(struct usbd_bus *, usb_dma_t *);
+
+usbd_xfer_handle ohci_allocx(struct usbd_bus *);
+void ohci_freex(struct usbd_bus *, usbd_xfer_handle);
+
+usbd_status ohci_root_ctrl_transfer(usbd_xfer_handle);
+usbd_status ohci_root_ctrl_start(usbd_xfer_handle);
+void ohci_root_ctrl_abort(usbd_xfer_handle);
+void ohci_root_ctrl_close(usbd_pipe_handle);
+void ohci_root_ctrl_done(usbd_xfer_handle);
+
+usbd_status ohci_root_intr_transfer(usbd_xfer_handle);
+usbd_status ohci_root_intr_start(usbd_xfer_handle);
+void ohci_root_intr_abort(usbd_xfer_handle);
+void ohci_root_intr_close(usbd_pipe_handle);
+void ohci_root_intr_done(usbd_xfer_handle);
+
+usbd_status ohci_device_ctrl_transfer(usbd_xfer_handle);
+usbd_status ohci_device_ctrl_start(usbd_xfer_handle);
+void ohci_device_ctrl_abort(usbd_xfer_handle);
+void ohci_device_ctrl_close(usbd_pipe_handle);
+void ohci_device_ctrl_done(usbd_xfer_handle);
+
+usbd_status ohci_device_bulk_transfer(usbd_xfer_handle);
+usbd_status ohci_device_bulk_start(usbd_xfer_handle);
+void ohci_device_bulk_abort(usbd_xfer_handle);
+void ohci_device_bulk_close(usbd_pipe_handle);
+void ohci_device_bulk_done(usbd_xfer_handle);
+
+usbd_status ohci_device_intr_transfer(usbd_xfer_handle);
+usbd_status ohci_device_intr_start(usbd_xfer_handle);
+void ohci_device_intr_abort(usbd_xfer_handle);
+void ohci_device_intr_close(usbd_pipe_handle);
+void ohci_device_intr_done(usbd_xfer_handle);
+
+usbd_status ohci_device_isoc_transfer(usbd_xfer_handle);
+usbd_status ohci_device_isoc_start(usbd_xfer_handle);
+void ohci_device_isoc_abort(usbd_xfer_handle);
+void ohci_device_isoc_close(usbd_pipe_handle);
+void ohci_device_isoc_done(usbd_xfer_handle);
+
+usbd_status ohci_device_setintr(ohci_softc_t *sc,
struct ohci_pipe *pipe, int ival);
-Static int ohci_str(usb_string_descriptor_t *, int, const char *);
+int ohci_str(usb_string_descriptor_t *, int, const char *);
-Static void ohci_timeout(void *);
-Static void ohci_timeout_task(void *);
-Static void ohci_rhsc_able(ohci_softc_t *, int);
-Static void ohci_rhsc_enable(void *);
+void ohci_timeout(void *);
+void ohci_timeout_task(void *);
+void ohci_rhsc_able(ohci_softc_t *, int);
+void ohci_rhsc_enable(void *);
-Static void ohci_close_pipe(usbd_pipe_handle, ohci_soft_ed_t *);
-Static void ohci_abort_xfer(usbd_xfer_handle, usbd_status);
+void ohci_close_pipe(usbd_pipe_handle, ohci_soft_ed_t *);
+void ohci_abort_xfer(usbd_xfer_handle, usbd_status);
-Static void ohci_device_clear_toggle(usbd_pipe_handle pipe);
-Static void ohci_noop(usbd_pipe_handle pipe);
+void ohci_device_clear_toggle(usbd_pipe_handle pipe);
+void ohci_noop(usbd_pipe_handle pipe);
#ifdef OHCI_DEBUG
-Static void ohci_dumpregs(ohci_softc_t *);
-Static void ohci_dump_tds(ohci_soft_td_t *);
-Static void ohci_dump_td(ohci_soft_td_t *);
-Static void ohci_dump_ed(ohci_soft_ed_t *);
-Static void ohci_dump_itd(ohci_soft_itd_t *);
-Static void ohci_dump_itds(ohci_soft_itd_t *);
+void ohci_dumpregs(ohci_softc_t *);
+void ohci_dump_tds(ohci_soft_td_t *);
+void ohci_dump_td(ohci_soft_td_t *);
+void ohci_dump_ed(ohci_soft_ed_t *);
+void ohci_dump_itd(ohci_soft_itd_t *);
+void ohci_dump_itds(ohci_soft_itd_t *);
#endif
#define OBARR(sc) bus_space_barrier((sc)->iot, (sc)->ioh, 0, (sc)->sc_size, \
@@ -206,7 +206,7 @@ Static void ohci_dump_itds(ohci_soft_itd_t *);
#define OREAD4(sc, r) (OBARR(sc), bus_space_read_4((sc)->iot, (sc)->ioh, (r)))
/* Reverse the bits in a value 0 .. 31 */
-Static u_int8_t revbits[OHCI_NO_INTRS] =
+u_int8_t revbits[OHCI_NO_INTRS] =
{ 0x00, 0x10, 0x08, 0x18, 0x04, 0x14, 0x0c, 0x1c,
0x02, 0x12, 0x0a, 0x1a, 0x06, 0x16, 0x0e, 0x1e,
0x01, 0x11, 0x09, 0x19, 0x05, 0x15, 0x0d, 0x1d,
@@ -246,7 +246,7 @@ struct ohci_pipe {
#define OHCI_INTR_ENDPT 1
-Static struct usbd_bus_methods ohci_bus_methods = {
+struct usbd_bus_methods ohci_bus_methods = {
ohci_open,
ohci_softintr,
ohci_poll,
@@ -256,7 +256,7 @@ Static struct usbd_bus_methods ohci_bus_methods = {
ohci_freex,
};
-Static struct usbd_pipe_methods ohci_root_ctrl_methods = {
+struct usbd_pipe_methods ohci_root_ctrl_methods = {
ohci_root_ctrl_transfer,
ohci_root_ctrl_start,
ohci_root_ctrl_abort,
@@ -265,7 +265,7 @@ Static struct usbd_pipe_methods ohci_root_ctrl_methods = {
ohci_root_ctrl_done,
};
-Static struct usbd_pipe_methods ohci_root_intr_methods = {
+struct usbd_pipe_methods ohci_root_intr_methods = {
ohci_root_intr_transfer,
ohci_root_intr_start,
ohci_root_intr_abort,
@@ -274,7 +274,7 @@ Static struct usbd_pipe_methods ohci_root_intr_methods = {
ohci_root_intr_done,
};
-Static struct usbd_pipe_methods ohci_device_ctrl_methods = {
+struct usbd_pipe_methods ohci_device_ctrl_methods = {
ohci_device_ctrl_transfer,
ohci_device_ctrl_start,
ohci_device_ctrl_abort,
@@ -283,7 +283,7 @@ Static struct usbd_pipe_methods ohci_device_ctrl_methods = {
ohci_device_ctrl_done,
};
-Static struct usbd_pipe_methods ohci_device_intr_methods = {
+struct usbd_pipe_methods ohci_device_intr_methods = {
ohci_device_intr_transfer,
ohci_device_intr_start,
ohci_device_intr_abort,
@@ -292,7 +292,7 @@ Static struct usbd_pipe_methods ohci_device_intr_methods = {
ohci_device_intr_done,
};
-Static struct usbd_pipe_methods ohci_device_bulk_methods = {
+struct usbd_pipe_methods ohci_device_bulk_methods = {
ohci_device_bulk_transfer,
ohci_device_bulk_start,
ohci_device_bulk_abort,
@@ -301,7 +301,7 @@ Static struct usbd_pipe_methods ohci_device_bulk_methods = {
ohci_device_bulk_done,
};
-Static struct usbd_pipe_methods ohci_device_isoc_methods = {
+struct usbd_pipe_methods ohci_device_isoc_methods = {
ohci_device_isoc_transfer,
ohci_device_isoc_start,
ohci_device_isoc_abort,
@@ -533,7 +533,7 @@ ohci_alloc_std_chain(struct ohci_pipe *opipe, ohci_softc_t *sc,
}
#if 0
-Static void
+void
ohci_free_std_chain(ohci_softc_t *sc, ohci_soft_td_t *std,
ohci_soft_td_t *stdend)
{
@@ -1077,7 +1077,7 @@ ohci_dumpregs(ohci_softc_t *sc)
}
#endif
-Static int ohci_intr1(ohci_softc_t *);
+int ohci_intr1(ohci_softc_t *);
int
ohci_intr(void *p)
@@ -1102,7 +1102,7 @@ ohci_intr(void *p)
return (ohci_intr1(sc));
}
-Static int
+int
ohci_intr1(ohci_softc_t *sc)
{
u_int32_t intrs, eintrs;
@@ -2281,7 +2281,7 @@ ohci_abort_xfer(usbd_xfer_handle xfer, usbd_status status)
/*
* Data structures and routines to emulate the root hub.
*/
-Static usb_device_descriptor_t ohci_devd = {
+usb_device_descriptor_t ohci_devd = {
USB_DEVICE_DESCRIPTOR_SIZE,
UDESC_DEVICE, /* type */
{0x00, 0x01}, /* USB version */
@@ -2294,7 +2294,7 @@ Static usb_device_descriptor_t ohci_devd = {
1 /* # of configurations */
};
-Static usb_config_descriptor_t ohci_confd = {
+usb_config_descriptor_t ohci_confd = {
USB_CONFIG_DESCRIPTOR_SIZE,
UDESC_CONFIG,
{USB_CONFIG_DESCRIPTOR_SIZE +
@@ -2307,7 +2307,7 @@ Static usb_config_descriptor_t ohci_confd = {
0 /* max power */
};
-Static usb_interface_descriptor_t ohci_ifcd = {
+usb_interface_descriptor_t ohci_ifcd = {
USB_INTERFACE_DESCRIPTOR_SIZE,
UDESC_INTERFACE,
0,
@@ -2319,7 +2319,7 @@ Static usb_interface_descriptor_t ohci_ifcd = {
0
};
-Static usb_endpoint_descriptor_t ohci_endpd = {
+usb_endpoint_descriptor_t ohci_endpd = {
USB_ENDPOINT_DESCRIPTOR_SIZE,
UDESC_ENDPOINT,
UE_DIR_IN | OHCI_INTR_ENDPT,
@@ -2328,7 +2328,7 @@ Static usb_endpoint_descriptor_t ohci_endpd = {
255
};
-Static usb_hub_descriptor_t ohci_hubd = {
+usb_hub_descriptor_t ohci_hubd = {
USB_HUB_DESCRIPTOR_SIZE,
UDESC_HUB,
0,
@@ -2338,7 +2338,7 @@ Static usb_hub_descriptor_t ohci_hubd = {
{0},
};
-Static int
+int
ohci_str(usb_string_descriptor_t *p, int l, const char *s)
{
int i;
@@ -2358,7 +2358,7 @@ ohci_str(usb_string_descriptor_t *p, int l, const char *s)
/*
* Simulate a hardware hub by handling all the necessary requests.
*/
-Static usbd_status
+usbd_status
ohci_root_ctrl_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2372,7 +2372,7 @@ ohci_root_ctrl_transfer(usbd_xfer_handle xfer)
return (ohci_root_ctrl_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ohci_root_ctrl_start(usbd_xfer_handle xfer)
{
ohci_softc_t *sc = (ohci_softc_t *)xfer->pipe->device->bus;
@@ -2683,21 +2683,21 @@ ohci_root_ctrl_start(usbd_xfer_handle xfer)
}
/* Abort a root control request. */
-Static void
+void
ohci_root_ctrl_abort(usbd_xfer_handle xfer)
{
/* Nothing to do, all transfers are synchronous. */
}
/* Close the root pipe. */
-Static void
+void
ohci_root_ctrl_close(usbd_pipe_handle pipe)
{
DPRINTF(("ohci_root_ctrl_close\n"));
/* Nothing to do. */
}
-Static usbd_status
+usbd_status
ohci_root_intr_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2711,7 +2711,7 @@ ohci_root_intr_transfer(usbd_xfer_handle xfer)
return (ohci_root_intr_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ohci_root_intr_start(usbd_xfer_handle xfer)
{
usbd_pipe_handle pipe = xfer->pipe;
@@ -2726,7 +2726,7 @@ ohci_root_intr_start(usbd_xfer_handle xfer)
}
/* Abort a root interrupt request. */
-Static void
+void
ohci_root_intr_abort(usbd_xfer_handle xfer)
{
int s;
@@ -2742,7 +2742,7 @@ ohci_root_intr_abort(usbd_xfer_handle xfer)
}
/* Close the root pipe. */
-Static void
+void
ohci_root_intr_close(usbd_pipe_handle pipe)
{
ohci_softc_t *sc = (ohci_softc_t *)pipe->device->bus;
@@ -2754,7 +2754,7 @@ ohci_root_intr_close(usbd_pipe_handle pipe)
/************************/
-Static usbd_status
+usbd_status
ohci_device_ctrl_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2768,7 +2768,7 @@ ohci_device_ctrl_transfer(usbd_xfer_handle xfer)
return (ohci_device_ctrl_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ohci_device_ctrl_start(usbd_xfer_handle xfer)
{
ohci_softc_t *sc = (ohci_softc_t *)xfer->pipe->device->bus;
@@ -2796,7 +2796,7 @@ ohci_device_ctrl_start(usbd_xfer_handle xfer)
}
/* Abort a device control request. */
-Static void
+void
ohci_device_ctrl_abort(usbd_xfer_handle xfer)
{
DPRINTF(("ohci_device_ctrl_abort: xfer=%p\n", xfer));
@@ -2804,7 +2804,7 @@ ohci_device_ctrl_abort(usbd_xfer_handle xfer)
}
/* Close a device control pipe. */
-Static void
+void
ohci_device_ctrl_close(usbd_pipe_handle pipe)
{
struct ohci_pipe *opipe = (struct ohci_pipe *)pipe;
@@ -2817,7 +2817,7 @@ ohci_device_ctrl_close(usbd_pipe_handle pipe)
/************************/
-Static void
+void
ohci_device_clear_toggle(usbd_pipe_handle pipe)
{
struct ohci_pipe *opipe = (struct ohci_pipe *)pipe;
@@ -2825,12 +2825,12 @@ ohci_device_clear_toggle(usbd_pipe_handle pipe)
opipe->sed->ed.ed_headp &= htole32(~OHCI_TOGGLECARRY);
}
-Static void
+void
ohci_noop(usbd_pipe_handle pipe)
{
}
-Static usbd_status
+usbd_status
ohci_device_bulk_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2844,7 +2844,7 @@ ohci_device_bulk_transfer(usbd_xfer_handle xfer)
return (ohci_device_bulk_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ohci_device_bulk_start(usbd_xfer_handle xfer)
{
struct ohci_pipe *opipe = (struct ohci_pipe *)xfer->pipe;
@@ -2946,7 +2946,7 @@ ohci_device_bulk_start(usbd_xfer_handle xfer)
return (USBD_IN_PROGRESS);
}
-Static void
+void
ohci_device_bulk_abort(usbd_xfer_handle xfer)
{
DPRINTF(("ohci_device_bulk_abort: xfer=%p\n", xfer));
@@ -2956,7 +2956,7 @@ ohci_device_bulk_abort(usbd_xfer_handle xfer)
/*
* Close a device bulk pipe.
*/
-Static void
+void
ohci_device_bulk_close(usbd_pipe_handle pipe)
{
struct ohci_pipe *opipe = (struct ohci_pipe *)pipe;
@@ -2969,7 +2969,7 @@ ohci_device_bulk_close(usbd_pipe_handle pipe)
/************************/
-Static usbd_status
+usbd_status
ohci_device_intr_transfer(usbd_xfer_handle xfer)
{
usbd_status err;
@@ -2983,7 +2983,7 @@ ohci_device_intr_transfer(usbd_xfer_handle xfer)
return (ohci_device_intr_start(SIMPLEQ_FIRST(&xfer->pipe->queue)));
}
-Static usbd_status
+usbd_status
ohci_device_intr_start(usbd_xfer_handle xfer)
{
struct ohci_pipe *opipe = (struct ohci_pipe *)xfer->pipe;
@@ -3064,7 +3064,7 @@ ohci_device_intr_start(usbd_xfer_handle xfer)
}
/* Abort a device control request. */
-Static void
+void
ohci_device_intr_abort(usbd_xfer_handle xfer)
{
if (xfer->pipe->intrxfer == xfer) {
@@ -3075,7 +3075,7 @@ ohci_device_intr_abort(usbd_xfer_handle xfer)
}
/* Close a device interrupt pipe. */
-Static void
+void
ohci_device_intr_close(usbd_pipe_handle pipe)
{
struct ohci_pipe *opipe = (struct ohci_pipe *)pipe;
@@ -3111,7 +3111,7 @@ ohci_device_intr_close(usbd_pipe_handle pipe)
ohci_free_sed(sc, opipe->sed);
}
-Static usbd_status
+usbd_status
ohci_device_setintr(ohci_softc_t *sc, struct ohci_pipe *opipe, int ival)
{
int i, j, s, best;
diff --git a/sys/dev/usb/uark.c b/sys/dev/usb/uark.c
index cbe02d4b550..feaf3db2cd3 100644
--- a/sys/dev/usb/uark.c
+++ b/sys/dev/usb/uark.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uark.c,v 1.3 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uark.c,v 1.4 2007/06/05 08:43:55 mbalmer Exp $ */
/*
* Copyright (c) 2006 Jonathan Gray <jsg@openbsd.org>
@@ -71,12 +71,12 @@ struct uark_softc {
u_char sc_dying;
};
-Static void uark_get_status(void *, int portno, u_char *lsr, u_char *msr);
-Static void uark_set(void *, int, int, int);
-Static int uark_param(void *, int, struct termios *);
-Static int uark_open(void *sc, int);
-Static void uark_break(void *, int, int);
-Static int uark_cmd(struct uark_softc *, uint16_t, uint16_t);
+void uark_get_status(void *, int portno, u_char *lsr, u_char *msr);
+void uark_set(void *, int, int, int);
+int uark_param(void *, int, struct termios *);
+int uark_open(void *sc, int);
+void uark_break(void *, int, int);
+int uark_cmd(struct uark_softc *, uint16_t, uint16_t);
struct ucom_methods uark_methods = {
uark_get_status,
@@ -221,7 +221,7 @@ uark_activate(device_ptr_t self, enum devact act)
return (rv);
}
-Static void
+void
uark_set(void *vsc, int portno, int reg, int onoff)
{
struct uark_softc *sc = vsc;
@@ -237,7 +237,7 @@ uark_set(void *vsc, int portno, int reg, int onoff)
}
}
-Static int
+int
uark_param(void *vsc, int portno, struct termios *t)
{
struct uark_softc *sc = (struct uark_softc *)vsc;
diff --git a/sys/dev/usb/uaudio.c b/sys/dev/usb/uaudio.c
index 772220d28b4..ba54145d1d4 100644
--- a/sys/dev/usb/uaudio.c
+++ b/sys/dev/usb/uaudio.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uaudio.c,v 1.40 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: uaudio.c,v 1.41 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: uaudio.c,v 1.90 2004/10/29 17:12:53 kent Exp $ */
/*
@@ -211,119 +211,119 @@ struct io_terminal {
#define UAC_RECORD 3
#define UAC_NCLASSES 4
#ifdef UAUDIO_DEBUG
-Static const char *uac_names[] = {
+const char *uac_names[] = {
AudioCoutputs, AudioCinputs, AudioCequalization, AudioCrecord,
};
#endif
-Static usbd_status uaudio_identify_ac
+usbd_status uaudio_identify_ac
(struct uaudio_softc *, const usb_config_descriptor_t *);
-Static usbd_status uaudio_identify_as
+usbd_status uaudio_identify_as
(struct uaudio_softc *, const usb_config_descriptor_t *);
-Static usbd_status uaudio_process_as
+usbd_status uaudio_process_as
(struct uaudio_softc *, const char *, int *, int,
const usb_interface_descriptor_t *);
-Static void uaudio_add_alt(struct uaudio_softc *, const struct as_info *);
+void uaudio_add_alt(struct uaudio_softc *, const struct as_info *);
-Static const usb_interface_descriptor_t *uaudio_find_iface
+const usb_interface_descriptor_t *uaudio_find_iface
(const char *, int, int *, int);
-Static void uaudio_mixer_add_ctl(struct uaudio_softc *, struct mixerctl *);
-Static char *uaudio_id_name
+void uaudio_mixer_add_ctl(struct uaudio_softc *, struct mixerctl *);
+char *uaudio_id_name
(struct uaudio_softc *, const struct io_terminal *, int);
-Static struct usb_audio_cluster uaudio_get_cluster
+struct usb_audio_cluster uaudio_get_cluster
(int, const struct io_terminal *);
-Static void uaudio_add_input
+void uaudio_add_input
(struct uaudio_softc *, const struct io_terminal *, int);
-Static void uaudio_add_output
+void uaudio_add_output
(struct uaudio_softc *, const struct io_terminal *, int);
-Static void uaudio_add_mixer
+void uaudio_add_mixer
(struct uaudio_softc *, const struct io_terminal *, int);
-Static void uaudio_add_selector
+void uaudio_add_selector
(struct uaudio_softc *, const struct io_terminal *, int);
#ifdef UAUDIO_DEBUG
-Static const char *uaudio_get_terminal_name(int);
+const char *uaudio_get_terminal_name(int);
#endif
-Static int uaudio_determine_class
+int uaudio_determine_class
(const struct io_terminal *, struct mixerctl *);
-Static const char *uaudio_feature_name
+const char *uaudio_feature_name
(const struct io_terminal *, struct mixerctl *);
-Static void uaudio_add_feature
+void uaudio_add_feature
(struct uaudio_softc *, const struct io_terminal *, int);
-Static void uaudio_add_processing_updown
+void uaudio_add_processing_updown
(struct uaudio_softc *, const struct io_terminal *, int);
-Static void uaudio_add_processing
+void uaudio_add_processing
(struct uaudio_softc *, const struct io_terminal *, int);
-Static void uaudio_add_extension
+void uaudio_add_extension
(struct uaudio_softc *, const struct io_terminal *, int);
-Static struct terminal_list *uaudio_merge_terminal_list
+struct terminal_list *uaudio_merge_terminal_list
(const struct io_terminal *);
-Static struct terminal_list *uaudio_io_terminaltype
+struct terminal_list *uaudio_io_terminaltype
(int, struct io_terminal *, int);
-Static usbd_status uaudio_identify
+usbd_status uaudio_identify
(struct uaudio_softc *, const usb_config_descriptor_t *);
-Static int uaudio_signext(int, int);
-Static int uaudio_value2bsd(struct mixerctl *, int);
-Static int uaudio_bsd2value(struct mixerctl *, int);
-Static int uaudio_get(struct uaudio_softc *, int, int, int, int, int);
-Static int uaudio_ctl_get
+int uaudio_signext(int, int);
+int uaudio_value2bsd(struct mixerctl *, int);
+int uaudio_bsd2value(struct mixerctl *, int);
+int uaudio_get(struct uaudio_softc *, int, int, int, int, int);
+int uaudio_ctl_get
(struct uaudio_softc *, int, struct mixerctl *, int);
-Static void uaudio_set
+void uaudio_set
(struct uaudio_softc *, int, int, int, int, int, int);
-Static void uaudio_ctl_set
+void uaudio_ctl_set
(struct uaudio_softc *, int, struct mixerctl *, int, int);
-Static usbd_status uaudio_set_speed(struct uaudio_softc *, int, u_int);
+usbd_status uaudio_set_speed(struct uaudio_softc *, int, u_int);
-Static usbd_status uaudio_chan_open(struct uaudio_softc *, struct chan *);
-Static void uaudio_chan_close(struct uaudio_softc *, struct chan *);
-Static usbd_status uaudio_chan_alloc_buffers
+usbd_status uaudio_chan_open(struct uaudio_softc *, struct chan *);
+void uaudio_chan_close(struct uaudio_softc *, struct chan *);
+usbd_status uaudio_chan_alloc_buffers
(struct uaudio_softc *, struct chan *);
-Static void uaudio_chan_free_buffers(struct uaudio_softc *, struct chan *);
-Static void uaudio_chan_init
+void uaudio_chan_free_buffers(struct uaudio_softc *, struct chan *);
+void uaudio_chan_init
(struct chan *, int, const struct audio_params *, int);
-Static void uaudio_chan_set_param(struct chan *, u_char *, u_char *, int);
-Static void uaudio_chan_ptransfer(struct chan *);
-Static void uaudio_chan_pintr
+void uaudio_chan_set_param(struct chan *, u_char *, u_char *, int);
+void uaudio_chan_ptransfer(struct chan *);
+void uaudio_chan_pintr
(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void uaudio_chan_rtransfer(struct chan *);
-Static void uaudio_chan_rintr
+void uaudio_chan_rtransfer(struct chan *);
+void uaudio_chan_rintr
(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static int uaudio_open(void *, int);
-Static void uaudio_close(void *);
-Static int uaudio_drain(void *);
-Static int uaudio_query_encoding(void *, struct audio_encoding *);
-Static void uaudio_get_minmax_rates
+int uaudio_open(void *, int);
+void uaudio_close(void *);
+int uaudio_drain(void *);
+int uaudio_query_encoding(void *, struct audio_encoding *);
+void uaudio_get_minmax_rates
(int, const struct as_info *, const struct audio_params *,
int, u_long *, u_long *);
-Static int uaudio_match_alt_sub
+int uaudio_match_alt_sub
(int, const struct as_info *, const struct audio_params *, int, u_long);
-Static int uaudio_match_alt_chan
+int uaudio_match_alt_chan
(int, const struct as_info *, struct audio_params *, int);
-Static int uaudio_match_alt
+int uaudio_match_alt
(int, const struct as_info *, struct audio_params *, int);
-Static int uaudio_set_params
+int uaudio_set_params
(void *, int, int, struct audio_params *, struct audio_params *);
-Static int uaudio_round_blocksize(void *, int);
-Static int uaudio_trigger_output
+int uaudio_round_blocksize(void *, int);
+int uaudio_trigger_output
(void *, void *, void *, int, void (*)(void *), void *,
struct audio_params *);
-Static int uaudio_trigger_input
+int uaudio_trigger_input
(void *, void *, void *, int, void (*)(void *), void *,
struct audio_params *);
-Static int uaudio_halt_in_dma(void *);
-Static int uaudio_halt_out_dma(void *);
-Static int uaudio_getdev(void *, struct audio_device *);
-Static int uaudio_mixer_set_port(void *, mixer_ctrl_t *);
-Static int uaudio_mixer_get_port(void *, mixer_ctrl_t *);
-Static int uaudio_query_devinfo(void *, mixer_devinfo_t *);
-Static int uaudio_get_props(void *);
-
-Static struct audio_hw_if uaudio_hw_if = {
+int uaudio_halt_in_dma(void *);
+int uaudio_halt_out_dma(void *);
+int uaudio_getdev(void *, struct audio_device *);
+int uaudio_mixer_set_port(void *, mixer_ctrl_t *);
+int uaudio_mixer_get_port(void *, mixer_ctrl_t *);
+int uaudio_query_devinfo(void *, mixer_devinfo_t *);
+int uaudio_get_props(void *);
+
+struct audio_hw_if uaudio_hw_if = {
uaudio_open,
uaudio_close,
uaudio_drain,
@@ -352,7 +352,7 @@ Static struct audio_hw_if uaudio_hw_if = {
uaudio_trigger_input,
};
-Static struct audio_device uaudio_device = {
+struct audio_device uaudio_device = {
"USB audio",
"",
"uaudio"
@@ -502,7 +502,7 @@ uaudio_detach(device_ptr_t self, int flags)
return (rv);
}
-Static int
+int
uaudio_query_encoding(void *addr, struct audio_encoding *fp)
{
struct uaudio_softc *sc = addr;
@@ -570,7 +570,7 @@ uaudio_query_encoding(void *addr, struct audio_encoding *fp)
}
}
-Static const usb_interface_descriptor_t *
+const usb_interface_descriptor_t *
uaudio_find_iface(const char *buf, int size, int *offsp, int subtype)
{
const usb_interface_descriptor_t *d;
@@ -586,7 +586,7 @@ uaudio_find_iface(const char *buf, int size, int *offsp, int subtype)
return (NULL);
}
-Static void
+void
uaudio_mixer_add_ctl(struct uaudio_softc *sc, struct mixerctl *mc)
{
int res;
@@ -654,7 +654,7 @@ uaudio_mixer_add_ctl(struct uaudio_softc *sc, struct mixerctl *mc)
#endif
}
-Static char *
+char *
uaudio_id_name(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
static char buf[32];
@@ -662,7 +662,7 @@ uaudio_id_name(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
return (buf);
}
-Static struct usb_audio_cluster
+struct usb_audio_cluster
uaudio_get_cluster(int id, const struct io_terminal *iot)
{
struct usb_audio_cluster r;
@@ -712,7 +712,7 @@ uaudio_get_cluster(int id, const struct io_terminal *iot)
}
-Static void
+void
uaudio_add_input(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
#ifdef UAUDIO_DEBUG
@@ -727,7 +727,7 @@ uaudio_add_input(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
#endif
}
-Static void
+void
uaudio_add_output(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
#ifdef UAUDIO_DEBUG
@@ -740,7 +740,7 @@ uaudio_add_output(struct uaudio_softc *sc, const struct io_terminal *iot, int id
#endif
}
-Static void
+void
uaudio_add_mixer(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
const struct usb_audio_mixer_unit *d = iot[id].d.mu;
@@ -804,7 +804,7 @@ uaudio_add_mixer(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
}
-Static void
+void
uaudio_add_selector(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
const struct usb_audio_selector_unit *d = iot[id].d.su;
@@ -833,7 +833,7 @@ uaudio_add_selector(struct uaudio_softc *sc, const struct io_terminal *iot, int
}
#ifdef UAUDIO_DEBUG
-Static const char *
+const char *
uaudio_get_terminal_name(int terminal_type)
{
static char buf[100];
@@ -909,7 +909,7 @@ uaudio_get_terminal_name(int terminal_type)
}
#endif
-Static int
+int
uaudio_determine_class(const struct io_terminal *iot, struct mixerctl *mix)
{
int terminal_type;
@@ -959,7 +959,7 @@ uaudio_determine_class(const struct io_terminal *iot, struct mixerctl *mix)
return terminal_type;
}
-Static const char *
+const char *
uaudio_feature_name(const struct io_terminal *iot, struct mixerctl *mix)
{
int terminal_type;
@@ -1060,7 +1060,7 @@ uaudio_feature_name(const struct io_terminal *iot, struct mixerctl *mix)
}
}
-Static void
+void
uaudio_add_feature(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
const struct usb_audio_feature_unit *d = iot[id].d.fu;
@@ -1173,7 +1173,7 @@ uaudio_add_feature(struct uaudio_softc *sc, const struct io_terminal *iot, int i
}
}
-Static void
+void
uaudio_add_processing_updown(struct uaudio_softc *sc,
const struct io_terminal *iot, int id)
{
@@ -1210,7 +1210,7 @@ uaudio_add_processing_updown(struct uaudio_softc *sc,
uaudio_mixer_add_ctl(sc, &mix);
}
-Static void
+void
uaudio_add_processing(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
const struct usb_audio_processing_unit *d = iot[id].d.pu;
@@ -1252,7 +1252,7 @@ uaudio_add_processing(struct uaudio_softc *sc, const struct io_terminal *iot, in
}
}
-Static void
+void
uaudio_add_extension(struct uaudio_softc *sc, const struct io_terminal *iot, int id)
{
const struct usb_audio_extension_unit *d = iot[id].d.eu;
@@ -1279,7 +1279,7 @@ uaudio_add_extension(struct uaudio_softc *sc, const struct io_terminal *iot, int
}
}
-Static struct terminal_list*
+struct terminal_list*
uaudio_merge_terminal_list(const struct io_terminal *iot)
{
struct terminal_list *tml;
@@ -1314,7 +1314,7 @@ uaudio_merge_terminal_list(const struct io_terminal *iot)
return tml;
}
-Static struct terminal_list *
+struct terminal_list *
uaudio_io_terminaltype(int outtype, struct io_terminal *iot, int id)
{
struct terminal_list *tml;
@@ -1465,7 +1465,7 @@ uaudio_io_terminaltype(int outtype, struct io_terminal *iot, int id)
}
}
-Static usbd_status
+usbd_status
uaudio_identify(struct uaudio_softc *sc, const usb_config_descriptor_t *cdesc)
{
usbd_status err;
@@ -1476,7 +1476,7 @@ uaudio_identify(struct uaudio_softc *sc, const usb_config_descriptor_t *cdesc)
return (uaudio_identify_as(sc, cdesc));
}
-Static void
+void
uaudio_add_alt(struct uaudio_softc *sc, const struct as_info *ai)
{
size_t len;
@@ -1499,7 +1499,7 @@ uaudio_add_alt(struct uaudio_softc *sc, const struct as_info *ai)
sc->sc_alts[sc->sc_nalts++] = *ai;
}
-Static usbd_status
+usbd_status
uaudio_process_as(struct uaudio_softc *sc, const char *buf, int *offsp,
int size, const usb_interface_descriptor_t *id)
#define offs (*offsp)
@@ -1710,7 +1710,7 @@ uaudio_process_as(struct uaudio_softc *sc, const char *buf, int *offsp,
}
#undef offs
-Static usbd_status
+usbd_status
uaudio_identify_as(struct uaudio_softc *sc,
const usb_config_descriptor_t *cdesc)
{
@@ -1766,7 +1766,7 @@ uaudio_identify_as(struct uaudio_softc *sc,
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
uaudio_identify_ac(struct uaudio_softc *sc, const usb_config_descriptor_t *cdesc)
{
struct io_terminal* iot;
@@ -1980,7 +1980,7 @@ uaudio_identify_ac(struct uaudio_softc *sc, const usb_config_descriptor_t *cdesc
return (USBD_NORMAL_COMPLETION);
}
-Static int
+int
uaudio_query_devinfo(void *addr, mixer_devinfo_t *mi)
{
struct uaudio_softc *sc = addr;
@@ -2064,7 +2064,7 @@ uaudio_query_devinfo(void *addr, mixer_devinfo_t *mi)
return (0);
}
-Static int
+int
uaudio_open(void *addr, int flags)
{
struct uaudio_softc *sc = addr;
@@ -2084,7 +2084,7 @@ uaudio_open(void *addr, int flags)
/*
* Close function is called at splaudio().
*/
-Static void
+void
uaudio_close(void *addr)
{
struct uaudio_softc *sc = addr;
@@ -2095,7 +2095,7 @@ uaudio_close(void *addr)
uaudio_chan_close(sc, &sc->sc_recchan);
}
-Static int
+int
uaudio_drain(void *addr)
{
struct uaudio_softc *sc = addr;
@@ -2105,7 +2105,7 @@ uaudio_drain(void *addr)
return (0);
}
-Static int
+int
uaudio_halt_out_dma(void *addr)
{
struct uaudio_softc *sc = addr;
@@ -2120,7 +2120,7 @@ uaudio_halt_out_dma(void *addr)
return (0);
}
-Static int
+int
uaudio_halt_in_dma(void *addr)
{
struct uaudio_softc *sc = addr;
@@ -2135,7 +2135,7 @@ uaudio_halt_in_dma(void *addr)
return (0);
}
-Static int
+int
uaudio_getdev(void *addr, struct audio_device *retp)
{
struct uaudio_softc *sc = addr;
@@ -2151,7 +2151,7 @@ uaudio_getdev(void *addr, struct audio_device *retp)
/*
* Make sure the block size is large enough to hold all outstanding transfers.
*/
-Static int
+int
uaudio_round_blocksize(void *addr, int blk)
{
struct uaudio_softc *sc = addr;
@@ -2186,14 +2186,14 @@ uaudio_round_blocksize(void *addr, int blk)
return (blk);
}
-Static int
+int
uaudio_get_props(void *addr)
{
return (AUDIO_PROP_FULLDUPLEX | AUDIO_PROP_INDEPENDENT);
}
-Static int
+int
uaudio_get(struct uaudio_softc *sc, int which, int type, int wValue,
int wIndex, int len)
{
@@ -2233,7 +2233,7 @@ uaudio_get(struct uaudio_softc *sc, int which, int type, int wValue,
return (val);
}
-Static void
+void
uaudio_set(struct uaudio_softc *sc, int which, int type, int wValue,
int wIndex, int len, int val)
{
@@ -2270,7 +2270,7 @@ uaudio_set(struct uaudio_softc *sc, int which, int type, int wValue,
#endif
}
-Static int
+int
uaudio_signext(int type, int val)
{
if (!MIX_UNSIGNED(type)) {
@@ -2282,7 +2282,7 @@ uaudio_signext(int type, int val)
return (val);
}
-Static int
+int
uaudio_value2bsd(struct mixerctl *mc, int val)
{
DPRINTFN(5, ("uaudio_value2bsd: type=%03x val=%d min=%d max=%d ",
@@ -2315,7 +2315,7 @@ uaudio_bsd2value(struct mixerctl *mc, int val)
return (val);
}
-Static int
+int
uaudio_ctl_get(struct uaudio_softc *sc, int which, struct mixerctl *mc,
int chan)
{
@@ -2327,7 +2327,7 @@ uaudio_ctl_get(struct uaudio_softc *sc, int which, struct mixerctl *mc,
return (uaudio_value2bsd(mc, val));
}
-Static void
+void
uaudio_ctl_set(struct uaudio_softc *sc, int which, struct mixerctl *mc,
int chan, int val)
{
@@ -2336,7 +2336,7 @@ uaudio_ctl_set(struct uaudio_softc *sc, int which, struct mixerctl *mc,
mc->wIndex, MIX_SIZE(mc->type), val);
}
-Static int
+int
uaudio_mixer_get_port(void *addr, mixer_ctrl_t *cp)
{
struct uaudio_softc *sc = addr;
@@ -2381,7 +2381,7 @@ uaudio_mixer_get_port(void *addr, mixer_ctrl_t *cp)
return (0);
}
-Static int
+int
uaudio_mixer_set_port(void *addr, mixer_ctrl_t *cp)
{
struct uaudio_softc *sc = addr;
@@ -2422,7 +2422,7 @@ uaudio_mixer_set_port(void *addr, mixer_ctrl_t *cp)
return (0);
}
-Static int
+int
uaudio_trigger_input(void *addr, void *start, void *end, int blksize,
void (*intr)(void *), void *arg,
struct audio_params *param)
@@ -2464,7 +2464,7 @@ uaudio_trigger_input(void *addr, void *start, void *end, int blksize,
return (0);
}
-Static int
+int
uaudio_trigger_output(void *addr, void *start, void *end, int blksize,
void (*intr)(void *), void *arg,
struct audio_params *param)
@@ -2507,7 +2507,7 @@ uaudio_trigger_output(void *addr, void *start, void *end, int blksize,
}
/* Set up a pipe for a channel. */
-Static usbd_status
+usbd_status
uaudio_chan_open(struct uaudio_softc *sc, struct chan *ch)
{
struct as_info *as = &sc->sc_alts[ch->altidx];
@@ -2548,7 +2548,7 @@ uaudio_chan_open(struct uaudio_softc *sc, struct chan *ch)
return err;
}
-Static void
+void
uaudio_chan_close(struct uaudio_softc *sc, struct chan *ch)
{
struct as_info *as = &sc->sc_alts[ch->altidx];
@@ -2569,7 +2569,7 @@ uaudio_chan_close(struct uaudio_softc *sc, struct chan *ch)
}
}
-Static usbd_status
+usbd_status
uaudio_chan_alloc_buffers(struct uaudio_softc *sc, struct chan *ch)
{
usbd_xfer_handle xfer;
@@ -2600,7 +2600,7 @@ bad:
return (USBD_NOMEM);
}
-Static void
+void
uaudio_chan_free_buffers(struct uaudio_softc *sc, struct chan *ch)
{
int i;
@@ -2610,7 +2610,7 @@ uaudio_chan_free_buffers(struct uaudio_softc *sc, struct chan *ch)
}
/* Called at splusb() */
-Static void
+void
uaudio_chan_ptransfer(struct chan *ch)
{
struct chanbuf *cb;
@@ -2675,7 +2675,7 @@ uaudio_chan_ptransfer(struct chan *ch)
(void)usbd_transfer(cb->xfer);
}
-Static void
+void
uaudio_chan_pintr(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -2714,7 +2714,7 @@ uaudio_chan_pintr(usbd_xfer_handle xfer, usbd_private_handle priv,
}
/* Called at splusb() */
-Static void
+void
uaudio_chan_rtransfer(struct chan *ch)
{
struct chanbuf *cb;
@@ -2759,7 +2759,7 @@ uaudio_chan_rtransfer(struct chan *ch)
(void)usbd_transfer(cb->xfer);
}
-Static void
+void
uaudio_chan_rintr(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -2817,7 +2817,7 @@ uaudio_chan_rintr(usbd_xfer_handle xfer, usbd_private_handle priv,
uaudio_chan_rtransfer(ch);
}
-Static void
+void
uaudio_chan_init(struct chan *ch, int altidx, const struct audio_params *param,
int maxpktsize)
{
@@ -2838,7 +2838,7 @@ uaudio_chan_init(struct chan *ch, int altidx, const struct audio_params *param,
ch->residue = 0;
}
-Static void
+void
uaudio_chan_set_param(struct chan *ch, u_char *start, u_char *end, int blksize)
{
ch->start = start;
@@ -2850,7 +2850,7 @@ uaudio_chan_set_param(struct chan *ch, u_char *start, u_char *end, int blksize)
ch->curchanbuf = 0;
}
-Static void
+void
uaudio_get_minmax_rates(int nalts, const struct as_info *alts,
const struct audio_params *p, int mode,
u_long *min, u_long *max)
@@ -2892,7 +2892,7 @@ uaudio_get_minmax_rates(int nalts, const struct as_info *alts,
}
}
-Static int
+int
uaudio_match_alt_sub(int nalts, const struct as_info *alts,
const struct audio_params *p, int mode, u_long rate)
{
@@ -2931,7 +2931,7 @@ uaudio_match_alt_sub(int nalts, const struct as_info *alts,
return -1;
}
-Static int
+int
uaudio_match_alt_chan(int nalts, const struct as_info *alts,
struct audio_params *p, int mode)
{
@@ -2975,7 +2975,7 @@ uaudio_match_alt_chan(int nalts, const struct as_info *alts,
return -1;
}
-Static int
+int
uaudio_match_alt(int nalts, const struct as_info *alts,
struct audio_params *p, int mode)
{
@@ -2999,7 +2999,7 @@ uaudio_match_alt(int nalts, const struct as_info *alts,
return uaudio_match_alt_chan(nalts, alts, p, mode);
}
-Static int
+int
uaudio_set_params(void *addr, int setmode, int usemode,
struct audio_params *play, struct audio_params *rec)
{
@@ -3188,7 +3188,7 @@ uaudio_set_params(void *addr, int setmode, int usemode,
return (0);
}
-Static usbd_status
+usbd_status
uaudio_set_speed(struct uaudio_softc *sc, int endpt, u_int speed)
{
usb_device_request_t req;
diff --git a/sys/dev/usb/uberry.c b/sys/dev/usb/uberry.c
index f6a3616c6b9..1dc73c323f6 100644
--- a/sys/dev/usb/uberry.c
+++ b/sys/dev/usb/uberry.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uberry.c,v 1.4 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uberry.c,v 1.5 2007/06/05 08:43:55 mbalmer Exp $ */
/*-
* Copyright (c) 2006 Theo de Raadt <deraadt@openbsd.org>
@@ -45,7 +45,7 @@ struct uberry_softc {
#define UBERRY_CONFIG_NO 0
-Static struct usb_devno const uberry_devices[] = {
+struct usb_devno const uberry_devices[] = {
{ USB_VENDOR_RIM, USB_PRODUCT_RIM_BLACKBERRY }
};
@@ -99,7 +99,7 @@ uberry_detach(struct device *self, int flags)
return 0;
}
-Static int
+int
uberry_activate(device_ptr_t self, enum devact act)
{
switch (act) {
diff --git a/sys/dev/usb/ubsa.c b/sys/dev/usb/ubsa.c
index b8dc82e9311..6294a39bc53 100644
--- a/sys/dev/usb/ubsa.c
+++ b/sys/dev/usb/ubsa.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ubsa.c,v 1.23 2007/06/01 06:12:20 mbalmer Exp $ */
+/* $OpenBSD: ubsa.c,v 1.24 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: ubsa.c,v 1.5 2002/11/25 00:51:33 fvdl Exp $ */
/*-
* Copyright (c) 2002, Alexander Kabaev <kan.FreeBSD.org>.
@@ -94,7 +94,7 @@
#endif
#ifdef UBSA_DEBUG
-Static int ubsadebug = 0;
+int ubsadebug = 0;
#define DPRINTFN(n, x) do { if (ubsadebug > (n)) printf x; } while (0)
#else
@@ -180,23 +180,23 @@ struct ubsa_softc {
};
-Static void ubsa_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void ubsa_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void ubsa_get_status(void *, int, u_char *, u_char *);
-Static void ubsa_set(void *, int, int, int);
-Static int ubsa_param(void *, int, struct termios *);
-Static int ubsa_open(void *, int);
-Static void ubsa_close(void *, int);
+void ubsa_get_status(void *, int, u_char *, u_char *);
+void ubsa_set(void *, int, int, int);
+int ubsa_param(void *, int, struct termios *);
+int ubsa_open(void *, int);
+void ubsa_close(void *, int);
-Static void ubsa_break(struct ubsa_softc *sc, int onoff);
-Static int ubsa_request(struct ubsa_softc *, u_int8_t, u_int16_t);
-Static void ubsa_dtr(struct ubsa_softc *, int);
-Static void ubsa_rts(struct ubsa_softc *, int);
-Static void ubsa_baudrate(struct ubsa_softc *, speed_t);
-Static void ubsa_parity(struct ubsa_softc *, tcflag_t);
-Static void ubsa_databits(struct ubsa_softc *, tcflag_t);
-Static void ubsa_stopbits(struct ubsa_softc *, tcflag_t);
-Static void ubsa_flow(struct ubsa_softc *, tcflag_t, tcflag_t);
+void ubsa_break(struct ubsa_softc *sc, int onoff);
+int ubsa_request(struct ubsa_softc *, u_int8_t, u_int16_t);
+void ubsa_dtr(struct ubsa_softc *, int);
+void ubsa_rts(struct ubsa_softc *, int);
+void ubsa_baudrate(struct ubsa_softc *, speed_t);
+void ubsa_parity(struct ubsa_softc *, tcflag_t);
+void ubsa_databits(struct ubsa_softc *, tcflag_t);
+void ubsa_stopbits(struct ubsa_softc *, tcflag_t);
+void ubsa_flow(struct ubsa_softc *, tcflag_t, tcflag_t);
struct ucom_methods ubsa_methods = {
ubsa_get_status,
@@ -209,7 +209,7 @@ struct ucom_methods ubsa_methods = {
NULL
};
-Static const struct usb_devno ubsa_devs[] = {
+const struct usb_devno ubsa_devs[] = {
/* AnyDATA ADU-E100H */
{ USB_VENDOR_ANYDATA, USB_PRODUCT_ANYDATA_ADU_E100H },
/* BELKIN F5U103 */
@@ -431,7 +431,7 @@ ubsa_activate(device_ptr_t self, enum devact act)
return (rv);
}
-Static int
+int
ubsa_request(struct ubsa_softc *sc, u_int8_t request, u_int16_t value)
{
usb_device_request_t req;
@@ -450,7 +450,7 @@ ubsa_request(struct ubsa_softc *sc, u_int8_t request, u_int16_t value)
return (err);
}
-Static void
+void
ubsa_dtr(struct ubsa_softc *sc, int onoff)
{
@@ -463,7 +463,7 @@ ubsa_dtr(struct ubsa_softc *sc, int onoff)
ubsa_request(sc, UBSA_SET_DTR, onoff ? 1 : 0);
}
-Static void
+void
ubsa_rts(struct ubsa_softc *sc, int onoff)
{
@@ -476,7 +476,7 @@ ubsa_rts(struct ubsa_softc *sc, int onoff)
ubsa_request(sc, UBSA_SET_RTS, onoff ? 1 : 0);
}
-Static void
+void
ubsa_break(struct ubsa_softc *sc, int onoff)
{
@@ -485,7 +485,7 @@ ubsa_break(struct ubsa_softc *sc, int onoff)
ubsa_request(sc, UBSA_SET_BREAK, onoff ? 1 : 0);
}
-Static void
+void
ubsa_set(void *addr, int portno, int reg, int onoff)
{
struct ubsa_softc *sc;
@@ -506,7 +506,7 @@ ubsa_set(void *addr, int portno, int reg, int onoff)
}
}
-Static void
+void
ubsa_baudrate(struct ubsa_softc *sc, speed_t speed)
{
u_int16_t value = 0;
@@ -545,7 +545,7 @@ ubsa_baudrate(struct ubsa_softc *sc, speed_t speed)
ubsa_request(sc, UBSA_SET_BAUDRATE, value);
}
-Static void
+void
ubsa_parity(struct ubsa_softc *sc, tcflag_t cflag)
{
int value;
@@ -560,7 +560,7 @@ ubsa_parity(struct ubsa_softc *sc, tcflag_t cflag)
ubsa_request(sc, UBSA_SET_PARITY, value);
}
-Static void
+void
ubsa_databits(struct ubsa_softc *sc, tcflag_t cflag)
{
int value;
@@ -582,7 +582,7 @@ ubsa_databits(struct ubsa_softc *sc, tcflag_t cflag)
ubsa_request(sc, UBSA_SET_DATA_BITS, value);
}
-Static void
+void
ubsa_stopbits(struct ubsa_softc *sc, tcflag_t cflag)
{
int value;
@@ -594,7 +594,7 @@ ubsa_stopbits(struct ubsa_softc *sc, tcflag_t cflag)
ubsa_request(sc, UBSA_SET_STOP_BITS, value);
}
-Static void
+void
ubsa_flow(struct ubsa_softc *sc, tcflag_t cflag, tcflag_t iflag)
{
int value;
@@ -610,7 +610,7 @@ ubsa_flow(struct ubsa_softc *sc, tcflag_t cflag, tcflag_t iflag)
ubsa_request(sc, UBSA_SET_FLOW_CTRL, value);
}
-Static int
+int
ubsa_param(void *addr, int portno, struct termios *ti)
{
struct ubsa_softc *sc = addr;
@@ -626,7 +626,7 @@ ubsa_param(void *addr, int portno, struct termios *ti)
return (0);
}
-Static int
+int
ubsa_open(void *addr, int portno)
{
struct ubsa_softc *sc = addr;
@@ -659,7 +659,7 @@ ubsa_open(void *addr, int portno)
return (0);
}
-Static void
+void
ubsa_close(void *addr, int portno)
{
struct ubsa_softc *sc = addr;
@@ -686,7 +686,7 @@ ubsa_close(void *addr, int portno)
}
}
-Static void
+void
ubsa_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct ubsa_softc *sc = priv;
@@ -716,7 +716,7 @@ ubsa_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
ucom_status_change((struct ucom_softc *)sc->sc_subdev);
}
-Static void
+void
ubsa_get_status(void *addr, int portno, u_char *lsr, u_char *msr)
{
struct ubsa_softc *sc = addr;
diff --git a/sys/dev/usb/ucom.c b/sys/dev/usb/ucom.c
index 24b76b0dd8f..0d63ee86d8a 100644
--- a/sys/dev/usb/ucom.c
+++ b/sys/dev/usb/ucom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ucom.c,v 1.34 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: ucom.c,v 1.35 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: ucom.c,v 1.49 2003/01/01 00:10:25 thorpej Exp $ */
/*
@@ -130,34 +130,34 @@ struct ucom_softc {
u_char sc_dying; /* disconnecting */
};
-Static void ucom_cleanup(struct ucom_softc *);
-Static void ucom_hwiflow(struct ucom_softc *);
-Static int ucomparam(struct tty *, struct termios *);
-Static void ucomstart(struct tty *);
-Static void ucom_shutdown(struct ucom_softc *);
-Static int ucom_do_ioctl(struct ucom_softc *, u_long, caddr_t,
+void ucom_cleanup(struct ucom_softc *);
+void ucom_hwiflow(struct ucom_softc *);
+int ucomparam(struct tty *, struct termios *);
+void ucomstart(struct tty *);
+void ucom_shutdown(struct ucom_softc *);
+int ucom_do_ioctl(struct ucom_softc *, u_long, caddr_t,
int, usb_proc_ptr);
-Static void ucom_dtr(struct ucom_softc *, int);
-Static void ucom_rts(struct ucom_softc *, int);
-Static void ucom_break(struct ucom_softc *, int);
-Static usbd_status ucomstartread(struct ucom_softc *);
-Static void ucomreadcb(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void ucomwritecb(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void tiocm_to_ucom(struct ucom_softc *, u_long, int);
-Static int ucom_to_tiocm(struct ucom_softc *);
-Static void ucom_lock(struct ucom_softc *);
-Static void ucom_unlock(struct ucom_softc *);
+void ucom_dtr(struct ucom_softc *, int);
+void ucom_rts(struct ucom_softc *, int);
+void ucom_break(struct ucom_softc *, int);
+usbd_status ucomstartread(struct ucom_softc *);
+void ucomreadcb(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void ucomwritecb(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void tiocm_to_ucom(struct ucom_softc *, u_long, int);
+int ucom_to_tiocm(struct ucom_softc *);
+void ucom_lock(struct ucom_softc *);
+void ucom_unlock(struct ucom_softc *);
USB_DECLARE_DRIVER(ucom);
-Static void
+void
ucom_lock(struct ucom_softc *sc)
{
sc->sc_refcnt++;
rw_enter_write(&sc->sc_lock);
}
-Static void
+void
ucom_unlock(struct ucom_softc *sc)
{
rw_exit_write(&sc->sc_lock);
@@ -618,7 +618,7 @@ ucomioctl(dev_t dev, u_long cmd, caddr_t data, int flag, usb_proc_ptr p)
return (error);
}
-Static int
+int
ucom_do_ioctl(struct ucom_softc *sc, u_long cmd, caddr_t data,
int flag, usb_proc_ptr p)
{
@@ -699,7 +699,7 @@ ucom_do_ioctl(struct ucom_softc *sc, u_long cmd, caddr_t data,
return (error);
}
-Static void
+void
tiocm_to_ucom(struct ucom_softc *sc, u_long how, int ttybits)
{
u_char combits;
@@ -731,7 +731,7 @@ tiocm_to_ucom(struct ucom_softc *sc, u_long how, int ttybits)
ucom_rts(sc, (sc->sc_mcr & UMCR_RTS) != 0);
}
-Static int
+int
ucom_to_tiocm(struct ucom_softc *sc)
{
u_char combits;
@@ -762,7 +762,7 @@ XXX;
return (ttybits);
}
-Static void
+void
ucom_break(sc, onoff)
struct ucom_softc *sc;
int onoff;
@@ -774,7 +774,7 @@ ucom_break(sc, onoff)
UCOM_SET_BREAK, onoff);
}
-Static void
+void
ucom_dtr(struct ucom_softc *sc, int onoff)
{
DPRINTF(("ucom_dtr: onoff=%d\n", onoff));
@@ -788,7 +788,7 @@ ucom_dtr(struct ucom_softc *sc, int onoff)
}
}
-Static void
+void
ucom_rts(struct ucom_softc *sc, int onoff)
{
DPRINTF(("ucom_rts: onoff=%d\n", onoff));
@@ -821,7 +821,7 @@ ucom_status_change(struct ucom_softc *sc)
}
}
-Static int
+int
ucomparam(struct tty *tp, struct termios *t)
{
struct ucom_softc *sc = ucom_cd.cd_devs[UCOMUNIT(tp->t_dev)];
@@ -892,7 +892,7 @@ XXX what if the hardware is not open
/*
* (un)block input via hw flowcontrol
*/
-Static void
+void
ucom_hwiflow(struct ucom_softc *sc)
{
DPRINTF(("ucom_hwiflow:\n"));
@@ -915,7 +915,7 @@ XXX
#endif
}
-Static void
+void
ucomstart(struct tty *tp)
{
struct ucom_softc *sc = ucom_cd.cd_devs[UCOMUNIT(tp->t_dev)];
@@ -1013,7 +1013,7 @@ ucomstop(struct tty *tp, int flag)
return (0);
}
-Static void
+void
ucomwritecb(usbd_xfer_handle xfer, usbd_private_handle p, usbd_status status)
{
struct ucom_softc *sc = (struct ucom_softc *)p;
@@ -1058,7 +1058,7 @@ error:
splx(s);
}
-Static usbd_status
+usbd_status
ucomstartread(struct ucom_softc *sc)
{
usbd_status err;
@@ -1087,7 +1087,7 @@ ucomstartread(struct ucom_softc *sc)
return (USBD_NORMAL_COMPLETION);
}
-Static void
+void
ucomreadcb(usbd_xfer_handle xfer, usbd_private_handle p, usbd_status status)
{
struct ucom_softc *sc = (struct ucom_softc *)p;
@@ -1145,7 +1145,7 @@ ucomreadcb(usbd_xfer_handle xfer, usbd_private_handle p, usbd_status status)
}
}
-Static void
+void
ucom_cleanup(struct ucom_softc *sc)
{
if (--sc->sc_open == 0) {
diff --git a/sys/dev/usb/ucycom.c b/sys/dev/usb/ucycom.c
index 52c0aa4a811..064fc6142af 100644
--- a/sys/dev/usb/ucycom.c
+++ b/sys/dev/usb/ucycom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ucycom.c,v 1.6 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: ucycom.c,v 1.7 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: ucycom.c,v 1.3 2005/08/05 07:27:47 skrll Exp $ */
/*
@@ -135,13 +135,13 @@ struct ucycom_softc {
};
/* Callback routines */
-Static void ucycom_set(void *, int, int, int);
-Static int ucycom_param(void *, int, struct termios *);
-Static void ucycom_get_status(void *, int, u_char *, u_char *);
-Static int ucycom_open(void *, int);
-Static void ucycom_close(void *, int);
-Static void ucycom_write(void *, int, u_char *, u_char *, u_int32_t *);
-Static void ucycom_read(void *, int, u_char **, u_int32_t *);
+void ucycom_set(void *, int, int, int);
+int ucycom_param(void *, int, struct termios *);
+void ucycom_get_status(void *, int, u_char *, u_char *);
+int ucycom_open(void *, int);
+void ucycom_close(void *, int);
+void ucycom_write(void *, int, u_char *, u_char *, u_int32_t *);
+void ucycom_read(void *, int, u_char **, u_int32_t *);
struct ucom_methods ucycom_methods = {
NULL, /* ucycom_get_status, */
@@ -154,11 +154,11 @@ struct ucom_methods ucycom_methods = {
ucycom_write,
};
-Static void ucycom_intr(struct uhidev *, void *, u_int);
+void ucycom_intr(struct uhidev *, void *, u_int);
-Static void ucycom_get_cfg(struct ucycom_softc *);
+void ucycom_get_cfg(struct ucycom_softc *);
-Static const struct usb_devno ucycom_devs[] = {
+const struct usb_devno ucycom_devs[] = {
{ USB_VENDOR_CYPRESS, USB_PRODUCT_CYPRESS_USBRS232 },
{ USB_VENDOR_DELORME, USB_PRODUCT_DELORME_EMUSB },
{ USB_VENDOR_DELORME, USB_PRODUCT_DELORME_EMLT20 },
@@ -311,7 +311,7 @@ ucycom_close(void *addr, int portno)
splx(s);
}
-Static void
+void
ucycom_read(void *addr, int portno, u_char **ptr, u_int32_t *count)
{
struct ucycom_softc *sc = addr;
@@ -328,7 +328,7 @@ ucycom_read(void *addr, int portno, u_char **ptr, u_int32_t *count)
*count = sc->sc_icnt;
}
-Static void
+void
ucycom_write(void *addr, int portno, u_char *to, u_char *data, u_int32_t *cnt)
{
struct ucycom_softc *sc = addr;
@@ -383,7 +383,7 @@ ucycom_write(void *addr, int portno, u_char *to, u_char *data, u_int32_t *cnt)
DPRINTFN(4,("ucycomstart: req %d chars did %d chars\n", want, len));
}
-Static int
+int
ucycom_param(void *addr, int portno, struct termios *t)
{
struct ucycom_softc *sc = addr;
@@ -469,7 +469,7 @@ ucycom_param(void *addr, int portno, struct termios *t)
return (err);
}
-Static void
+void
ucycom_intr(struct uhidev *addr, void *ibuf, u_int len)
{
extern void ucomreadcb(usbd_xfer_handle, usbd_private_handle, usbd_status);
@@ -524,7 +524,7 @@ ucycom_intr(struct uhidev *addr, void *ibuf, u_int len)
}
}
-Static void
+void
ucycom_set(void *addr, int portno, int reg, int onoff)
{
struct ucycom_softc *sc = addr;
@@ -555,7 +555,7 @@ ucycom_set(void *addr, int portno, int reg, int onoff)
DPRINTF(("ucycom_set_status: err=%d\n", err));
}
-Static void
+void
ucycom_get_cfg(struct ucycom_softc *sc)
{
int err, cfg, baud;
diff --git a/sys/dev/usb/udsbr.c b/sys/dev/usb/udsbr.c
index 92ac2bc6e5c..689796598dd 100644
--- a/sys/dev/usb/udsbr.c
+++ b/sys/dev/usb/udsbr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: udsbr.c,v 1.11 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: udsbr.c,v 1.12 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: udsbr.c,v 1.7 2002/07/11 21:14:27 augustss Exp $ */
/*
@@ -70,8 +70,8 @@ int udsbrdebug = 0;
#define UDSBR_CONFIG_NO 1
-Static int udsbr_get_info(void *, struct radio_info *);
-Static int udsbr_set_info(void *, struct radio_info *);
+int udsbr_get_info(void *, struct radio_info *);
+int udsbr_set_info(void *, struct radio_info *);
struct radio_hw_if udsbr_hw_if = {
NULL, /* open */
@@ -94,12 +94,12 @@ struct udsbr_softc {
char sc_dying;
};
-Static int udsbr_req(struct udsbr_softc *sc, int ureq, int value,
+ int udsbr_req(struct udsbr_softc *sc, int ureq, int value,
int index);
-Static void udsbr_start(struct udsbr_softc *sc);
-Static void udsbr_stop(struct udsbr_softc *sc);
-Static void udsbr_setfreq(struct udsbr_softc *sc, int freq);
-Static int udsbr_status(struct udsbr_softc *sc);
+ void udsbr_start(struct udsbr_softc *sc);
+ void udsbr_stop(struct udsbr_softc *sc);
+ void udsbr_setfreq(struct udsbr_softc *sc, int freq);
+ int udsbr_status(struct udsbr_softc *sc);
USB_DECLARE_DRIVER(udsbr);
diff --git a/sys/dev/usb/ueagle.c b/sys/dev/usb/ueagle.c
index 4a06d5dbc9c..bd0014966e5 100644
--- a/sys/dev/usb/ueagle.c
+++ b/sys/dev/usb/ueagle.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ueagle.c,v 1.14 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: ueagle.c,v 1.15 2007/06/05 08:43:55 mbalmer Exp $ */
/*-
* Copyright (c) 2003-2006
@@ -89,41 +89,41 @@ static const struct ueagle_type {
#define ueagle_lookup(v, p) \
((struct ueagle_type *)usb_lookup(ueagle_devs, v, p))
-Static void ueagle_attachhook(void *);
-Static int ueagle_getesi(struct ueagle_softc *, uint8_t *);
-Static void ueagle_loadpage(void *);
-Static void ueagle_request(struct ueagle_softc *, uint16_t, uint16_t,
+void ueagle_attachhook(void *);
+int ueagle_getesi(struct ueagle_softc *, uint8_t *);
+void ueagle_loadpage(void *);
+void ueagle_request(struct ueagle_softc *, uint16_t, uint16_t,
void *, int);
#ifdef USB_DEBUG
-Static void ueagle_dump_cmv(struct ueagle_softc *, struct ueagle_cmv *);
+void ueagle_dump_cmv(struct ueagle_softc *, struct ueagle_cmv *);
#endif
-Static int ueagle_cr(struct ueagle_softc *, uint32_t, uint16_t,
+int ueagle_cr(struct ueagle_softc *, uint32_t, uint16_t,
uint32_t *);
-Static int ueagle_cw(struct ueagle_softc *, uint32_t, uint16_t, uint32_t);
-Static int ueagle_stat(struct ueagle_softc *);
-Static void ueagle_stat_thread(void *);
-Static int ueagle_boot(struct ueagle_softc *);
-Static void ueagle_swap_intr(struct ueagle_softc *, struct ueagle_swap *);
-Static void ueagle_cmv_intr(struct ueagle_softc *, struct ueagle_cmv *);
-Static void ueagle_intr(usbd_xfer_handle, usbd_private_handle,
+int ueagle_cw(struct ueagle_softc *, uint32_t, uint16_t, uint32_t);
+int ueagle_stat(struct ueagle_softc *);
+void ueagle_stat_thread(void *);
+int ueagle_boot(struct ueagle_softc *);
+void ueagle_swap_intr(struct ueagle_softc *, struct ueagle_swap *);
+void ueagle_cmv_intr(struct ueagle_softc *, struct ueagle_cmv *);
+void ueagle_intr(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static uint32_t ueagle_crc_update(uint32_t, uint8_t *, int);
-Static void ueagle_push_cell(struct ueagle_softc *, uint8_t *);
-Static void ueagle_rxeof(usbd_xfer_handle, usbd_private_handle,
+uint32_t ueagle_crc_update(uint32_t, uint8_t *, int);
+void ueagle_push_cell(struct ueagle_softc *, uint8_t *);
+void ueagle_rxeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static void ueagle_txeof(usbd_xfer_handle, usbd_private_handle,
+void ueagle_txeof(usbd_xfer_handle, usbd_private_handle,
usbd_status);
-Static int ueagle_encap(struct ueagle_softc *, struct mbuf *);
-Static void ueagle_start(struct ifnet *);
-Static int ueagle_open_vcc(struct ueagle_softc *,
+int ueagle_encap(struct ueagle_softc *, struct mbuf *);
+void ueagle_start(struct ifnet *);
+int ueagle_open_vcc(struct ueagle_softc *,
struct atm_pseudoioctl *);
-Static int ueagle_close_vcc(struct ueagle_softc *,
+int ueagle_close_vcc(struct ueagle_softc *,
struct atm_pseudoioctl *);
-Static int ueagle_ioctl(struct ifnet *, u_long, caddr_t);
-Static int ueagle_open_pipes(struct ueagle_softc *);
-Static void ueagle_close_pipes(struct ueagle_softc *);
-Static int ueagle_init(struct ifnet *);
-Static void ueagle_stop(struct ifnet *, int);
+int ueagle_ioctl(struct ifnet *, u_long, caddr_t);
+int ueagle_open_pipes(struct ueagle_softc *);
+void ueagle_close_pipes(struct ueagle_softc *);
+int ueagle_init(struct ifnet *);
+void ueagle_stop(struct ifnet *, int);
USB_DECLARE_DRIVER(ueagle);
@@ -139,7 +139,7 @@ ueagle_match(struct device *parent, void *match, void *aux)
UMATCH_VENDOR_PRODUCT : UMATCH_NONE;
}
-Static void
+void
ueagle_attachhook(void *xsc)
{
char *firmwares[2];
@@ -261,7 +261,7 @@ ueagle_detach(struct device *self, int flags)
/*
* Retrieve the device End System Identifier (MAC address).
*/
-Static int
+int
ueagle_getesi(struct ueagle_softc *sc, uint8_t *addr)
{
usb_string_descriptor_t us;
@@ -298,7 +298,7 @@ ueagle_getesi(struct ueagle_softc *sc, uint8_t *addr)
return 0;
}
-Static void
+void
ueagle_loadpage(void *xsc)
{
struct ueagle_softc *sc = xsc;
@@ -374,7 +374,7 @@ ueagle_loadpage(void *xsc)
usbd_free_xfer(xfer);
}
-Static void
+void
ueagle_request(struct ueagle_softc *sc, uint16_t val, uint16_t index,
void *data, int len)
{
@@ -393,7 +393,7 @@ ueagle_request(struct ueagle_softc *sc, uint16_t val, uint16_t index,
}
#ifdef USB_DEBUG
-Static void
+void
ueagle_dump_cmv(struct ueagle_softc *sc, struct ueagle_cmv *cmv)
{
printf(" Preamble: 0x%04x\n", UGETW(cmv->wPreamble));
@@ -410,7 +410,7 @@ ueagle_dump_cmv(struct ueagle_softc *sc, struct ueagle_cmv *cmv)
}
#endif
-Static int
+int
ueagle_cr(struct ueagle_softc *sc, uint32_t address, uint16_t offset,
uint32_t *data)
{
@@ -452,7 +452,7 @@ ueagle_cr(struct ueagle_softc *sc, uint32_t address, uint16_t offset,
return 0;
}
-Static int
+int
ueagle_cw(struct ueagle_softc *sc, uint32_t address, uint16_t offset,
uint32_t data)
{
@@ -493,7 +493,7 @@ ueagle_cw(struct ueagle_softc *sc, uint32_t address, uint16_t offset,
return 0;
}
-Static int
+int
ueagle_stat(struct ueagle_softc *sc)
{
struct ifnet *ifp = &sc->sc_if;
@@ -560,7 +560,7 @@ ueagle_stat(struct ueagle_softc *sc)
#undef CR
}
-Static void
+void
ueagle_stat_thread(void *arg)
{
struct ueagle_softc *sc = arg;
@@ -577,7 +577,7 @@ ueagle_stat_thread(void *arg)
kthread_exit(0);
}
-Static int
+int
ueagle_boot(struct ueagle_softc *sc)
{
uint16_t zero = 0; /* ;-) */
@@ -626,7 +626,7 @@ ueagle_boot(struct ueagle_softc *sc)
#undef CW
}
-Static void
+void
ueagle_swap_intr(struct ueagle_softc *sc, struct ueagle_swap *swap)
{
#define rotbr(v, n) ((v) >> (n) | (v) << (8 - (n)))
@@ -641,7 +641,7 @@ ueagle_swap_intr(struct ueagle_softc *sc, struct ueagle_swap *swap)
* This function handles spontaneous CMVs and CMV acknowledgements sent by the
* modem on the interrupt pipe.
*/
-Static void
+void
ueagle_cmv_intr(struct ueagle_softc *sc, struct ueagle_cmv *cmv)
{
#ifdef USB_DEBUG
@@ -680,7 +680,7 @@ ueagle_cmv_intr(struct ueagle_softc *sc, struct ueagle_cmv *cmv)
}
}
-Static void
+void
ueagle_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct ueagle_softc *sc = priv;
@@ -770,7 +770,7 @@ static const uint32_t ueagle_crc32_table[256] = {
0xb1f740b4
};
-Static uint32_t
+uint32_t
ueagle_crc_update(uint32_t crc, uint8_t *buf, int len)
{
for (; len != 0; len--, buf++)
@@ -782,7 +782,7 @@ ueagle_crc_update(uint32_t crc, uint8_t *buf, int len)
/*
* Reassembly part of the software ATM AAL5 SAR.
*/
-Static void
+void
ueagle_push_cell(struct ueagle_softc *sc, uint8_t *cell)
{
struct ueagle_vcc *vcc = &sc->vcc;
@@ -893,7 +893,7 @@ fail: m_freem(vcc->m);
vcc->m = NULL;
}
-Static void
+void
ueagle_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -929,7 +929,7 @@ ueagle_rxeof(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_transfer(xfer);
}
-Static void
+void
ueagle_txeof(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -964,7 +964,7 @@ ueagle_txeof(usbd_xfer_handle xfer, usbd_private_handle priv,
/*
* Segmentation part of the software ATM AAL5 SAR.
*/
-Static int
+int
ueagle_encap(struct ueagle_softc *sc, struct mbuf *m0)
{
struct ueagle_vcc *vcc = &sc->vcc;
@@ -1064,7 +1064,7 @@ ueagle_encap(struct ueagle_softc *sc, struct mbuf *m0)
return 0;
}
-Static void
+void
ueagle_start(struct ifnet *ifp)
{
struct ueagle_softc *sc = ifp->if_softc;
@@ -1097,7 +1097,7 @@ ueagle_start(struct ifnet *ifp)
ifp->if_flags |= IFF_OACTIVE;
}
-Static int
+int
ueagle_open_vcc(struct ueagle_softc *sc, struct atm_pseudoioctl *api)
{
struct ueagle_vcc *vcc = &sc->vcc;
@@ -1117,7 +1117,7 @@ ueagle_open_vcc(struct ueagle_softc *sc, struct atm_pseudoioctl *api)
return 0;
}
-Static int
+int
ueagle_close_vcc(struct ueagle_softc *sc, struct atm_pseudoioctl *api)
{
DPRINTF(("%s: closing ATM VCC\n", USBDEVNAME(sc->sc_dev)));
@@ -1127,7 +1127,7 @@ ueagle_close_vcc(struct ueagle_softc *sc, struct atm_pseudoioctl *api)
return 0;
}
-Static int
+int
ueagle_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct ueagle_softc *sc = ifp->if_softc;
@@ -1187,7 +1187,7 @@ ueagle_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
return error;
}
-Static int
+int
ueagle_open_pipes(struct ueagle_softc *sc)
{
usb_endpoint_descriptor_t *edesc;
@@ -1309,7 +1309,7 @@ fail: ueagle_close_pipes(sc);
return error;
}
-Static void
+void
ueagle_close_pipes(struct ueagle_softc *sc)
{
int i;
@@ -1345,7 +1345,7 @@ ueagle_close_pipes(struct ueagle_softc *sc)
}
}
-Static int
+int
ueagle_init(struct ifnet *ifp)
{
struct ueagle_softc *sc = ifp->if_softc;
@@ -1414,7 +1414,7 @@ fail: ueagle_stop(ifp, 1);
return error;
}
-Static void
+void
ueagle_stop(struct ifnet *ifp, int disable)
{
struct ueagle_softc *sc = ifp->if_softc;
@@ -1451,7 +1451,7 @@ ueagle_stop(struct ifnet *ifp, int disable)
ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE);
}
-Static int
+int
ueagle_activate(device_ptr_t self, enum devact act)
{
struct ueagle_softc *sc = (struct ueagle_softc *)self;
diff --git a/sys/dev/usb/uftdi.c b/sys/dev/usb/uftdi.c
index ebb1e7f78db..bf3c4dadefe 100644
--- a/sys/dev/usb/uftdi.c
+++ b/sys/dev/usb/uftdi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uftdi.c,v 1.34 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uftdi.c,v 1.35 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: uftdi.c,v 1.14 2003/02/23 04:20:07 simonb Exp $ */
/*
@@ -102,16 +102,16 @@ struct uftdi_softc {
u_int last_lcr;
};
-Static void uftdi_get_status(void *, int portno, u_char *lsr, u_char *msr);
-Static void uftdi_set(void *, int, int, int);
-Static int uftdi_param(void *, int, struct termios *);
-Static int uftdi_open(void *sc, int portno);
-Static void uftdi_read(void *sc, int portno, u_char **ptr,
+void uftdi_get_status(void *, int portno, u_char *lsr, u_char *msr);
+void uftdi_set(void *, int, int, int);
+int uftdi_param(void *, int, struct termios *);
+int uftdi_open(void *sc, int portno);
+void uftdi_read(void *sc, int portno, u_char **ptr,
u_int32_t *count);
-Static void uftdi_write(void *sc, int portno, u_char *to, u_char *from,
+void uftdi_write(void *sc, int portno, u_char *to, u_char *from,
u_int32_t *count);
-Static void uftdi_break(void *sc, int portno, int onoff);
-Static int uftdi_8u232am_getrate(speed_t speed, int *rate);
+void uftdi_break(void *sc, int portno, int onoff);
+int uftdi_8u232am_getrate(speed_t speed, int *rate);
struct ucom_methods uftdi_methods = {
uftdi_get_status,
@@ -416,7 +416,7 @@ uftdi_detach(device_ptr_t self, int flags)
return (0);
}
-Static int
+int
uftdi_open(void *vsc, int portno)
{
struct uftdi_softc *sc = vsc;
@@ -457,7 +457,7 @@ uftdi_open(void *vsc, int portno)
return (0);
}
-Static void
+void
uftdi_read(void *vsc, int portno, u_char **ptr, u_int32_t *count)
{
struct uftdi_softc *sc = vsc;
@@ -490,7 +490,7 @@ uftdi_read(void *vsc, int portno, u_char **ptr, u_int32_t *count)
*count -= 2;
}
-Static void
+void
uftdi_write(void *vsc, int portno, u_char *to, u_char *from, u_int32_t *count)
{
struct uftdi_softc *sc = vsc;
@@ -506,7 +506,7 @@ uftdi_write(void *vsc, int portno, u_char *to, u_char *from, u_int32_t *count)
*count += sc->sc_hdrlen;
}
-Static void
+void
uftdi_set(void *vsc, int portno, int reg, int onoff)
{
struct uftdi_softc *sc = vsc;
@@ -540,7 +540,7 @@ uftdi_set(void *vsc, int portno, int reg, int onoff)
(void)usbd_do_request(sc->sc_udev, &req, NULL);
}
-Static int
+int
uftdi_param(void *vsc, int portno, struct termios *t)
{
struct uftdi_softc *sc = vsc;
@@ -686,7 +686,7 @@ uftdi_break(void *vsc, int portno, int onoff)
(void)usbd_do_request(sc->sc_udev, &req, NULL);
}
-Static int
+int
uftdi_8u232am_getrate(speed_t speed, int *rate)
{
/* Table of the nearest even powers-of-2 for values 0..15. */
diff --git a/sys/dev/usb/ugen.c b/sys/dev/usb/ugen.c
index f6a0157c7f7..83fe2f8ce3e 100644
--- a/sys/dev/usb/ugen.c
+++ b/sys/dev/usb/ugen.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ugen.c,v 1.39 2007/05/31 17:35:45 mbalmer Exp $ */
+/* $OpenBSD: ugen.c,v 1.40 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: ugen.c,v 1.63 2002/11/26 18:49:48 christos Exp $ */
/* $FreeBSD: src/sys/dev/usb/ugen.c,v 1.26 1999/11/17 22:33:41 n_hibma Exp $ */
@@ -112,19 +112,19 @@ struct ugen_softc {
u_char sc_dying;
};
-Static void ugenintr(usbd_xfer_handle xfer, usbd_private_handle addr,
+void ugenintr(usbd_xfer_handle xfer, usbd_private_handle addr,
usbd_status status);
-Static void ugen_isoc_rintr(usbd_xfer_handle xfer, usbd_private_handle addr,
+void ugen_isoc_rintr(usbd_xfer_handle xfer, usbd_private_handle addr,
usbd_status status);
-Static int ugen_do_read(struct ugen_softc *, int, struct uio *, int);
-Static int ugen_do_write(struct ugen_softc *, int, struct uio *, int);
-Static int ugen_do_ioctl(struct ugen_softc *, int, u_long,
+int ugen_do_read(struct ugen_softc *, int, struct uio *, int);
+int ugen_do_write(struct ugen_softc *, int, struct uio *, int);
+int ugen_do_ioctl(struct ugen_softc *, int, u_long,
caddr_t, int, usb_proc_ptr);
-Static int ugen_set_config(struct ugen_softc *sc, int configno);
-Static usb_config_descriptor_t *ugen_get_cdesc(struct ugen_softc *sc,
+int ugen_set_config(struct ugen_softc *sc, int configno);
+usb_config_descriptor_t *ugen_get_cdesc(struct ugen_softc *sc,
int index, int *lenp);
-Static usbd_status ugen_set_interface(struct ugen_softc *, int, int);
-Static int ugen_get_alt_index(struct ugen_softc *sc, int ifaceidx);
+usbd_status ugen_set_interface(struct ugen_softc *, int, int);
+int ugen_get_alt_index(struct ugen_softc *sc, int ifaceidx);
#define UGENUNIT(n) ((minor(n) >> 4) & 0xf)
#define UGENENDPOINT(n) (minor(n) & 0xf)
@@ -197,7 +197,7 @@ ugen_attach(struct device *parent, struct device *self, void *aux)
USBDEV(sc->sc_dev));
}
-Static int
+int
ugen_set_config(struct ugen_softc *sc, int configno)
{
usbd_device_handle dev = sc->sc_udev;
@@ -464,7 +464,7 @@ ugenclose(dev_t dev, int flag, int mode, usb_proc_ptr p)
return (0);
}
-Static int
+int
ugen_do_read(struct ugen_softc *sc, int endpt, struct uio *uio, int flag)
{
struct ugen_endpoint *sce = &sc->sc_endpoints[endpt][IN];
@@ -622,7 +622,7 @@ ugenread(dev_t dev, struct uio *uio, int flag)
return (error);
}
-Static int
+int
ugen_do_write(struct ugen_softc *sc, int endpt, struct uio *uio, int flag)
{
struct ugen_endpoint *sce = &sc->sc_endpoints[endpt][OUT];
@@ -783,7 +783,7 @@ ugen_detach(struct device *self, int flags)
return (0);
}
-Static void
+void
ugenintr(usbd_xfer_handle xfer, usbd_private_handle addr, usbd_status status)
{
struct ugen_endpoint *sce = addr;
@@ -819,7 +819,7 @@ ugenintr(usbd_xfer_handle xfer, usbd_private_handle addr, usbd_status status)
selwakeup(&sce->rsel);
}
-Static void
+void
ugen_isoc_rintr(usbd_xfer_handle xfer, usbd_private_handle addr,
usbd_status status)
{
@@ -878,7 +878,7 @@ ugen_isoc_rintr(usbd_xfer_handle xfer, usbd_private_handle addr,
selwakeup(&sce->rsel);
}
-Static usbd_status
+usbd_status
ugen_set_interface(struct ugen_softc *sc, int ifaceidx, int altno)
{
usbd_interface_handle iface;
@@ -934,7 +934,7 @@ ugen_set_interface(struct ugen_softc *sc, int ifaceidx, int altno)
}
/* Retrieve a complete descriptor for a certain device and index. */
-Static usb_config_descriptor_t *
+usb_config_descriptor_t *
ugen_get_cdesc(struct ugen_softc *sc, int index, int *lenp)
{
usb_config_descriptor_t *cdesc, *tdesc, cdescr;
@@ -968,7 +968,7 @@ ugen_get_cdesc(struct ugen_softc *sc, int index, int *lenp)
return (cdesc);
}
-Static int
+int
ugen_get_alt_index(struct ugen_softc *sc, int ifaceidx)
{
usbd_interface_handle iface;
@@ -980,7 +980,7 @@ ugen_get_alt_index(struct ugen_softc *sc, int ifaceidx)
return (usbd_get_interface_altindex(iface));
}
-Static int
+int
ugen_do_ioctl(struct ugen_softc *sc, int endpt, u_long cmd,
caddr_t addr, int flag, usb_proc_ptr p)
{
@@ -1328,12 +1328,12 @@ ugenpoll(dev_t dev, int events, usb_proc_ptr p)
return (revents);
}
-Static void filt_ugenrdetach(struct knote *);
-Static int filt_ugenread_intr(struct knote *, long);
-Static int filt_ugenread_isoc(struct knote *, long);
+void filt_ugenrdetach(struct knote *);
+int filt_ugenread_intr(struct knote *, long);
+int filt_ugenread_isoc(struct knote *, long);
int ugenkqfilter(dev_t, struct knote *);
-Static void
+void
filt_ugenrdetach(struct knote *kn)
{
struct ugen_endpoint *sce = (void *)kn->kn_hook;
@@ -1344,7 +1344,7 @@ filt_ugenrdetach(struct knote *kn)
splx(s);
}
-Static int
+int
filt_ugenread_intr(struct knote *kn, long hint)
{
struct ugen_endpoint *sce = (void *)kn->kn_hook;
@@ -1353,7 +1353,7 @@ filt_ugenread_intr(struct knote *kn, long hint)
return (kn->kn_data > 0);
}
-Static int
+int
filt_ugenread_isoc(struct knote *kn, long hint)
{
struct ugen_endpoint *sce = (void *)kn->kn_hook;
@@ -1370,13 +1370,13 @@ filt_ugenread_isoc(struct knote *kn, long hint)
return (1);
}
-Static struct filterops ugenread_intr_filtops =
+struct filterops ugenread_intr_filtops =
{ 1, NULL, filt_ugenrdetach, filt_ugenread_intr };
-Static struct filterops ugenread_isoc_filtops =
+struct filterops ugenread_isoc_filtops =
{ 1, NULL, filt_ugenrdetach, filt_ugenread_isoc };
-Static struct filterops ugen_seltrue_filtops =
+struct filterops ugen_seltrue_filtops =
{ 1, NULL, filt_ugenrdetach, filt_seltrue };
int
diff --git a/sys/dev/usb/uhci.c b/sys/dev/usb/uhci.c
index 5a2275dbacb..983d09d9e54 100644
--- a/sys/dev/usb/uhci.c
+++ b/sys/dev/usb/uhci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uhci.c,v 1.54 2007/05/21 06:10:43 jsg Exp $ */
+/* $OpenBSD: uhci.c,v 1.55 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: uhci.c,v 1.172 2003/02/23 04:19:26 simonb Exp $ */
/* $FreeBSD: src/sys/dev/usb/uhci.c,v 1.33 1999/11/17 22:33:41 n_hibma Exp $ */
@@ -130,116 +130,116 @@ struct uhci_pipe {
} u;
};
-Static void uhci_globalreset(uhci_softc_t *);
-Static usbd_status uhci_portreset(uhci_softc_t*, int);
-Static void uhci_reset(uhci_softc_t *);
-Static void uhci_shutdown(void *v);
-Static void uhci_power(int, void *);
-Static usbd_status uhci_run(uhci_softc_t *, int run);
-Static uhci_soft_td_t *uhci_alloc_std(uhci_softc_t *);
-Static void uhci_free_std(uhci_softc_t *, uhci_soft_td_t *);
-Static uhci_soft_qh_t *uhci_alloc_sqh(uhci_softc_t *);
-Static void uhci_free_sqh(uhci_softc_t *, uhci_soft_qh_t *);
+void uhci_globalreset(uhci_softc_t *);
+usbd_status uhci_portreset(uhci_softc_t*, int);
+void uhci_reset(uhci_softc_t *);
+void uhci_shutdown(void *v);
+void uhci_power(int, void *);
+usbd_status uhci_run(uhci_softc_t *, int run);
+uhci_soft_td_t *uhci_alloc_std(uhci_softc_t *);
+void uhci_free_std(uhci_softc_t *, uhci_soft_td_t *);
+uhci_soft_qh_t *uhci_alloc_sqh(uhci_softc_t *);
+void uhci_free_sqh(uhci_softc_t *, uhci_soft_qh_t *);
#if 0
-Static void uhci_enter_ctl_q(uhci_softc_t *, uhci_soft_qh_t *,
+void uhci_enter_ctl_q(uhci_softc_t *, uhci_soft_qh_t *,
uhci_intr_info_t *);
-Static void uhci_exit_ctl_q(uhci_softc_t *, uhci_soft_qh_t *);
+void uhci_exit_ctl_q(uhci_softc_t *, uhci_soft_qh_t *);
#endif
-Static void uhci_free_std_chain(uhci_softc_t *,
+void uhci_free_std_chain(uhci_softc_t *,
uhci_soft_td_t *, uhci_soft_td_t *);
-Static usbd_status uhci_alloc_std_chain(struct uhci_pipe *,
+usbd_status uhci_alloc_std_chain(struct uhci_pipe *,
uhci_softc_t *, int, int, u_int16_t, usb_dma_t *,
uhci_soft_td_t **, uhci_soft_td_t **);
-Static void uhci_poll_hub(void *);
-Static void uhci_waitintr(uhci_softc_t *, usbd_xfer_handle);
-Static void uhci_check_intr(uhci_softc_t *, uhci_intr_info_t *);
-Static void uhci_idone(uhci_intr_info_t *);
-
-Static void uhci_abort_xfer(usbd_xfer_handle, usbd_status status);
-
-Static void uhci_timeout(void *);
-Static void uhci_timeout_task(void *);
-Static void uhci_add_ls_ctrl(uhci_softc_t *, uhci_soft_qh_t *);
-Static void uhci_add_hs_ctrl(uhci_softc_t *, uhci_soft_qh_t *);
-Static void uhci_add_bulk(uhci_softc_t *, uhci_soft_qh_t *);
-Static void uhci_remove_ls_ctrl(uhci_softc_t *,uhci_soft_qh_t *);
-Static void uhci_remove_hs_ctrl(uhci_softc_t *,uhci_soft_qh_t *);
-Static void uhci_remove_bulk(uhci_softc_t *,uhci_soft_qh_t *);
-Static int uhci_str(usb_string_descriptor_t *, int, char *);
-Static void uhci_add_loop(uhci_softc_t *sc);
-Static void uhci_rem_loop(uhci_softc_t *sc);
-
-Static usbd_status uhci_setup_isoc(usbd_pipe_handle pipe);
-Static void uhci_device_isoc_enter(usbd_xfer_handle);
-
-Static usbd_status uhci_allocm(struct usbd_bus *, usb_dma_t *, u_int32_t);
-Static void uhci_freem(struct usbd_bus *, usb_dma_t *);
-
-Static usbd_xfer_handle uhci_allocx(struct usbd_bus *);
-Static void uhci_freex(struct usbd_bus *, usbd_xfer_handle);
-
-Static usbd_status uhci_device_ctrl_transfer(usbd_xfer_handle);
-Static usbd_status uhci_device_ctrl_start(usbd_xfer_handle);
-Static void uhci_device_ctrl_abort(usbd_xfer_handle);
-Static void uhci_device_ctrl_close(usbd_pipe_handle);
-Static void uhci_device_ctrl_done(usbd_xfer_handle);
-
-Static usbd_status uhci_device_intr_transfer(usbd_xfer_handle);
-Static usbd_status uhci_device_intr_start(usbd_xfer_handle);
-Static void uhci_device_intr_abort(usbd_xfer_handle);
-Static void uhci_device_intr_close(usbd_pipe_handle);
-Static void uhci_device_intr_done(usbd_xfer_handle);
-
-Static usbd_status uhci_device_bulk_transfer(usbd_xfer_handle);
-Static usbd_status uhci_device_bulk_start(usbd_xfer_handle);
-Static void uhci_device_bulk_abort(usbd_xfer_handle);
-Static void uhci_device_bulk_close(usbd_pipe_handle);
-Static void uhci_device_bulk_done(usbd_xfer_handle);
-
-Static usbd_status uhci_device_isoc_transfer(usbd_xfer_handle);
-Static usbd_status uhci_device_isoc_start(usbd_xfer_handle);
-Static void uhci_device_isoc_abort(usbd_xfer_handle);
-Static void uhci_device_isoc_close(usbd_pipe_handle);
-Static void uhci_device_isoc_done(usbd_xfer_handle);
-
-Static usbd_status uhci_root_ctrl_transfer(usbd_xfer_handle);
-Static usbd_status uhci_root_ctrl_start(usbd_xfer_handle);
-Static void uhci_root_ctrl_abort(usbd_xfer_handle);
-Static void uhci_root_ctrl_close(usbd_pipe_handle);
-Static void uhci_root_ctrl_done(usbd_xfer_handle);
-
-Static usbd_status uhci_root_intr_transfer(usbd_xfer_handle);
-Static usbd_status uhci_root_intr_start(usbd_xfer_handle);
-Static void uhci_root_intr_abort(usbd_xfer_handle);
-Static void uhci_root_intr_close(usbd_pipe_handle);
-Static void uhci_root_intr_done(usbd_xfer_handle);
-
-Static usbd_status uhci_open(usbd_pipe_handle);
-Static void uhci_poll(struct usbd_bus *);
-Static void uhci_softintr(void *);
-
-Static usbd_status uhci_device_request(usbd_xfer_handle xfer);
-
-Static void uhci_add_intr(uhci_softc_t *, uhci_soft_qh_t *);
-Static void uhci_remove_intr(uhci_softc_t *, uhci_soft_qh_t *);
-Static usbd_status uhci_device_setintr(uhci_softc_t *sc,
+void uhci_poll_hub(void *);
+void uhci_waitintr(uhci_softc_t *, usbd_xfer_handle);
+void uhci_check_intr(uhci_softc_t *, uhci_intr_info_t *);
+void uhci_idone(uhci_intr_info_t *);
+
+void uhci_abort_xfer(usbd_xfer_handle, usbd_status status);
+
+void uhci_timeout(void *);
+void uhci_timeout_task(void *);
+void uhci_add_ls_ctrl(uhci_softc_t *, uhci_soft_qh_t *);
+void uhci_add_hs_ctrl(uhci_softc_t *, uhci_soft_qh_t *);
+void uhci_add_bulk(uhci_softc_t *, uhci_soft_qh_t *);
+void uhci_remove_ls_ctrl(uhci_softc_t *,uhci_soft_qh_t *);
+void uhci_remove_hs_ctrl(uhci_softc_t *,uhci_soft_qh_t *);
+void uhci_remove_bulk(uhci_softc_t *,uhci_soft_qh_t *);
+int uhci_str(usb_string_descriptor_t *, int, char *);
+void uhci_add_loop(uhci_softc_t *sc);
+void uhci_rem_loop(uhci_softc_t *sc);
+
+usbd_status uhci_setup_isoc(usbd_pipe_handle pipe);
+void uhci_device_isoc_enter(usbd_xfer_handle);
+
+usbd_status uhci_allocm(struct usbd_bus *, usb_dma_t *, u_int32_t);
+void uhci_freem(struct usbd_bus *, usb_dma_t *);
+
+usbd_xfer_handle uhci_allocx(struct usbd_bus *);
+void uhci_freex(struct usbd_bus *, usbd_xfer_handle);
+
+usbd_status uhci_device_ctrl_transfer(usbd_xfer_handle);
+usbd_status uhci_device_ctrl_start(usbd_xfer_handle);
+void uhci_device_ctrl_abort(usbd_xfer_handle);
+void uhci_device_ctrl_close(usbd_pipe_handle);
+void uhci_device_ctrl_done(usbd_xfer_handle);
+
+usbd_status uhci_device_intr_transfer(usbd_xfer_handle);
+usbd_status uhci_device_intr_start(usbd_xfer_handle);
+void uhci_device_intr_abort(usbd_xfer_handle);
+void uhci_device_intr_close(usbd_pipe_handle);
+void uhci_device_intr_done(usbd_xfer_handle);
+
+usbd_status uhci_device_bulk_transfer(usbd_xfer_handle);
+usbd_status uhci_device_bulk_start(usbd_xfer_handle);
+void uhci_device_bulk_abort(usbd_xfer_handle);
+void uhci_device_bulk_close(usbd_pipe_handle);
+void uhci_device_bulk_done(usbd_xfer_handle);
+
+usbd_status uhci_device_isoc_transfer(usbd_xfer_handle);
+usbd_status uhci_device_isoc_start(usbd_xfer_handle);
+void uhci_device_isoc_abort(usbd_xfer_handle);
+void uhci_device_isoc_close(usbd_pipe_handle);
+void uhci_device_isoc_done(usbd_xfer_handle);
+
+usbd_status uhci_root_ctrl_transfer(usbd_xfer_handle);
+usbd_status uhci_root_ctrl_start(usbd_xfer_handle);
+void uhci_root_ctrl_abort(usbd_xfer_handle);
+void uhci_root_ctrl_close(usbd_pipe_handle);
+void uhci_root_ctrl_done(usbd_xfer_handle);
+
+usbd_status uhci_root_intr_transfer(usbd_xfer_handle);
+usbd_status uhci_root_intr_start(usbd_xfer_handle);
+void uhci_root_intr_abort(usbd_xfer_handle);
+void uhci_root_intr_close(usbd_pipe_handle);
+void uhci_root_intr_done(usbd_xfer_handle);
+
+usbd_status uhci_open(usbd_pipe_handle);
+void uhci_poll(struct usbd_bus *);
+void uhci_softintr(void *);
+
+usbd_status uhci_device_request(usbd_xfer_handle xfer);
+
+void uhci_add_intr(uhci_softc_t *, uhci_soft_qh_t *);
+void uhci_remove_intr(uhci_softc_t *, uhci_soft_qh_t *);
+usbd_status uhci_device_setintr(uhci_softc_t *sc,
struct uhci_pipe *pipe, int ival);
-Static void uhci_device_clear_toggle(usbd_pipe_handle pipe);
-Static void uhci_noop(usbd_pipe_handle pipe);
+void uhci_device_clear_toggle(usbd_pipe_handle pipe);
+void uhci_noop(usbd_pipe_handle pipe);
-Static __inline__ uhci_soft_qh_t *uhci_find_prev_qh(uhci_soft_qh_t *,
+__inline__ uhci_soft_qh_t *uhci_find_prev_qh(uhci_soft_qh_t *,
uhci_soft_qh_t *);
#ifdef UHCI_DEBUG
-Static void uhci_dump_all(uhci_softc_t *);
-Static void uhci_dumpregs(uhci_softc_t *);
-Static void uhci_dump_qhs(uhci_soft_qh_t *);
-Static void uhci_dump_qh(uhci_soft_qh_t *);
-Static void uhci_dump_tds(uhci_soft_td_t *);
-Static void uhci_dump_td(uhci_soft_td_t *);
-Static void uhci_dump_ii(uhci_intr_info_t *ii);
+void uhci_dump_all(uhci_softc_t *);
+void uhci_dumpregs(uhci_softc_t *);
+void uhci_dump_qhs(uhci_soft_qh_t *);
+void uhci_dump_qh(uhci_soft_qh_t *);
+void uhci_dump_tds(uhci_soft_td_t *);
+void uhci_dump_td(uhci_soft_td_t *);
+void uhci_dump_ii(uhci_intr_info_t *ii);
void uhci_dump(void);
#endif
@@ -340,7 +340,7 @@ struct usbd_pipe_methods uhci_device_isoc_methods = {
} while (0)
#define uhci_active_intr_info(ii) ((ii)->list.le_prev != NULL)
-Static __inline__ uhci_soft_qh_t *
+__inline__ uhci_soft_qh_t *
uhci_find_prev_qh(uhci_soft_qh_t *pqh, uhci_soft_qh_t *sqh)
{
DPRINTFN(15,("uhci_find_prev_qh: pqh=%p sqh=%p\n", pqh, sqh));
@@ -738,7 +738,7 @@ uhci_power(int why, void *v)
}
#ifdef UHCI_DEBUG
-Static void
+void
uhci_dumpregs(uhci_softc_t *sc)
{
DPRINTFN(-1,("%s regs: cmd=%04x, sts=%04x, intr=%04x, frnum=%04x, "
@@ -860,7 +860,7 @@ uhci_dump_tds(uhci_soft_td_t *std)
}
}
-Static void
+void
uhci_dump_ii(uhci_intr_info_t *ii)
{
usbd_pipe_handle pipe;
@@ -1135,7 +1135,7 @@ uhci_remove_bulk(uhci_softc_t *sc, uhci_soft_qh_t *sqh)
sc->sc_bulk_end = pqh;
}
-Static int uhci_intr1(uhci_softc_t *);
+int uhci_intr1(uhci_softc_t *);
int
uhci_intr(void *arg)
@@ -2976,7 +2976,7 @@ uhci_str(usb_string_descriptor_t *p, int l, char *s)
* outstanding "port enable change" and "connection status change"
* events have been reset.
*/
-Static usbd_status
+usbd_status
uhci_portreset(uhci_softc_t *sc, int index)
{
int lim, port, x;
diff --git a/sys/dev/usb/uhid.c b/sys/dev/usb/uhid.c
index e00dd185405..5aa478acd1c 100644
--- a/sys/dev/usb/uhid.c
+++ b/sys/dev/usb/uhid.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uhid.c,v 1.33 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: uhid.c,v 1.34 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: uhid.c,v 1.57 2003/03/11 16:44:00 augustss Exp $ */
/*
@@ -101,11 +101,11 @@ struct uhid_softc {
#define UHID_CHUNK 128 /* chunk size for read */
#define UHID_BSIZE 1020 /* buffer size */
-Static void uhid_intr(struct uhidev *, void *, u_int len);
+void uhid_intr(struct uhidev *, void *, u_int len);
-Static int uhid_do_read(struct uhid_softc *, struct uio *uio, int);
-Static int uhid_do_write(struct uhid_softc *, struct uio *uio, int);
-Static int uhid_do_ioctl(struct uhid_softc*, u_long, caddr_t, int,
+int uhid_do_read(struct uhid_softc *, struct uio *uio, int);
+int uhid_do_write(struct uhid_softc *, struct uio *uio, int);
+int uhid_do_ioctl(struct uhid_softc*, u_long, caddr_t, int,
usb_proc_ptr);
USB_DECLARE_DRIVER(uhid);
@@ -548,11 +548,11 @@ uhidpoll(dev_t dev, int events, usb_proc_ptr p)
return (revents);
}
-Static void filt_uhidrdetach(struct knote *);
-Static int filt_uhidread(struct knote *, long);
+void filt_uhidrdetach(struct knote *);
+int filt_uhidread(struct knote *, long);
int uhidkqfilter(dev_t, struct knote *);
-Static void
+void
filt_uhidrdetach(struct knote *kn)
{
struct uhid_softc *sc = (void *)kn->kn_hook;
@@ -563,7 +563,7 @@ filt_uhidrdetach(struct knote *kn)
splx(s);
}
-Static int
+int
filt_uhidread(struct knote *kn, long hint)
{
struct uhid_softc *sc = (void *)kn->kn_hook;
@@ -572,10 +572,10 @@ filt_uhidread(struct knote *kn, long hint)
return (kn->kn_data > 0);
}
-Static struct filterops uhidread_filtops =
+struct filterops uhidread_filtops =
{ 1, NULL, filt_uhidrdetach, filt_uhidread };
-Static struct filterops uhid_seltrue_filtops =
+struct filterops uhid_seltrue_filtops =
{ 1, NULL, filt_uhidrdetach, filt_seltrue };
int
diff --git a/sys/dev/usb/uhidev.c b/sys/dev/usb/uhidev.c
index 27f5df90a0c..0ddaea1a9a2 100644
--- a/sys/dev/usb/uhidev.c
+++ b/sys/dev/usb/uhidev.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uhidev.c,v 1.22 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: uhidev.c,v 1.23 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: uhidev.c,v 1.14 2003/03/11 16:44:00 augustss Exp $ */
/*
@@ -74,11 +74,11 @@ int uhidevdebug = 0;
#define DPRINTFN(n,x)
#endif
-Static void uhidev_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void uhidev_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static int uhidev_maxrepid(void *buf, int len);
-Static int uhidevprint(void *aux, const char *pnp);
-Static int uhidevsubmatch(struct device *parent, void *cf, void *aux);
+int uhidev_maxrepid(void *buf, int len);
+int uhidevprint(void *aux, const char *pnp);
+int uhidevsubmatch(struct device *parent, void *cf, void *aux);
USB_DECLARE_DRIVER(uhidev);
@@ -324,7 +324,7 @@ uhidevprint(void *aux, const char *pnp)
return (UNCONF);
}
-Static int uhidevsubmatch(struct device *parent, void *match, void *aux)
+int uhidevsubmatch(struct device *parent, void *match, void *aux)
{
struct uhidev_attach_arg *uha = aux;
struct cfdata *cf = match;
diff --git a/sys/dev/usb/uhub.c b/sys/dev/usb/uhub.c
index 375c5a9f923..2acb773ebdf 100644
--- a/sys/dev/usb/uhub.c
+++ b/sys/dev/usb/uhub.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uhub.c,v 1.40 2007/06/01 06:12:20 mbalmer Exp $ */
+/* $OpenBSD: uhub.c,v 1.41 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: uhub.c,v 1.64 2003/02/08 03:32:51 ichiro Exp $ */
/* $FreeBSD: src/sys/dev/usb/uhub.c,v 1.18 1999/11/17 22:33:43 n_hibma Exp $ */
@@ -79,8 +79,8 @@ struct uhub_softc {
#define UHUB_IS_HIGH_SPEED(sc) (UHUB_PROTO(sc) != UDPROTO_FSHUB)
#define UHUB_IS_SINGLE_TT(sc) (UHUB_PROTO(sc) == UDPROTO_HSHUBSTT)
-Static usbd_status uhub_explore(usbd_device_handle hub);
-Static void uhub_intr(usbd_xfer_handle, usbd_private_handle,usbd_status);
+usbd_status uhub_explore(usbd_device_handle hub);
+void uhub_intr(usbd_xfer_handle, usbd_private_handle,usbd_status);
/*
* We need two attachment points:
diff --git a/sys/dev/usb/uipaq.c b/sys/dev/usb/uipaq.c
index 6ac9ee84588..439b88a6be5 100644
--- a/sys/dev/usb/uipaq.c
+++ b/sys/dev/usb/uipaq.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uipaq.c,v 1.5 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uipaq.c,v 1.6 2007/06/05 08:43:55 mbalmer Exp $ */
/*
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -94,14 +94,14 @@ struct uipaq_softc {
};
/* Callback routines */
-Static void uipaq_set(void *, int, int, int);
+void uipaq_set(void *, int, int, int);
/* Support routines. */
/* based on uppc module by Sam Lawrance */
-Static void uipaq_dtr(struct uipaq_softc *sc, int onoff);
-Static void uipaq_rts(struct uipaq_softc *sc, int onoff);
-Static void uipaq_break(struct uipaq_softc* sc, int onoff);
+void uipaq_dtr(struct uipaq_softc *sc, int onoff);
+void uipaq_rts(struct uipaq_softc *sc, int onoff);
+void uipaq_break(struct uipaq_softc* sc, int onoff);
struct ucom_methods uipaq_methods = {
diff --git a/sys/dev/usb/ukbd.c b/sys/dev/usb/ukbd.c
index afedb1bb784..660ca6f81ae 100644
--- a/sys/dev/usb/ukbd.c
+++ b/sys/dev/usb/ukbd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ukbd.c,v 1.30 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: ukbd.c,v 1.31 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: ukbd.c,v 1.85 2003/03/11 16:44:00 augustss Exp $ */
/*
@@ -100,7 +100,7 @@ struct ukbd_data {
*
* See http://www.microsoft.com/whdc/device/input/Scancode.mspx
*/
-Static const u_int8_t ukbd_trtab[256] = {
+const u_int8_t ukbd_trtab[256] = {
NN, NN, NN, NN, 0x1e, 0x30, 0x2e, 0x20, /* 00 - 07 */
0x12, 0x21, 0x22, 0x23, 0x17, 0x24, 0x25, 0x26, /* 08 - 0f */
0x32, 0x31, 0x18, 0x19, 0x10, 0x13, 0x1f, 0x14, /* 10 - 17 */
@@ -292,28 +292,28 @@ ukbdtracedump(void)
#define UKBD_CHUNK 128 /* chunk size for read */
#define UKBD_BSIZE 1020 /* buffer size */
-Static int ukbd_is_console;
+int ukbd_is_console;
-Static void ukbd_cngetc(void *, u_int *, int *);
-Static void ukbd_cnpollc(void *, int);
+void ukbd_cngetc(void *, u_int *, int *);
+void ukbd_cnpollc(void *, int);
const struct wskbd_consops ukbd_consops = {
ukbd_cngetc,
ukbd_cnpollc,
};
-Static const char *ukbd_parse_desc(struct ukbd_softc *sc);
+const char *ukbd_parse_desc(struct ukbd_softc *sc);
-Static void ukbd_intr(struct uhidev *addr, void *ibuf, u_int len);
-Static void ukbd_decode(struct ukbd_softc *sc, struct ukbd_data *ud);
-Static void ukbd_delayed_decode(void *addr);
+void ukbd_intr(struct uhidev *addr, void *ibuf, u_int len);
+void ukbd_decode(struct ukbd_softc *sc, struct ukbd_data *ud);
+void ukbd_delayed_decode(void *addr);
-Static int ukbd_enable(void *, int);
-Static void ukbd_set_leds(void *, int);
+int ukbd_enable(void *, int);
+void ukbd_set_leds(void *, int);
-Static int ukbd_ioctl(void *, u_long, caddr_t, int, usb_proc_ptr );
+int ukbd_ioctl(void *, u_long, caddr_t, int, usb_proc_ptr );
#ifdef WSDISPLAY_COMPAT_RAWKBD
-Static void ukbd_rawrepeat(void *v);
+void ukbd_rawrepeat(void *v);
#endif
const struct wskbd_accessops ukbd_accessops = {
diff --git a/sys/dev/usb/umass.c b/sys/dev/usb/umass.c
index 42d9acb75cc..a3cef5dd2a8 100644
--- a/sys/dev/usb/umass.c
+++ b/sys/dev/usb/umass.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: umass.c,v 1.46 2007/06/01 06:12:20 mbalmer Exp $ */
+/* $OpenBSD: umass.c,v 1.47 2007/06/05 08:43:55 mbalmer Exp $ */
/* $NetBSD: umass.c,v 1.116 2004/06/30 05:53:46 mycroft Exp $ */
/*
@@ -186,41 +186,41 @@ char *states[TSTATE_STATES+1] = {
/* USB device probe/attach/detach functions */
USB_DECLARE_DRIVER(umass);
-Static void umass_disco(struct umass_softc *sc);
+void umass_disco(struct umass_softc *sc);
/* generic transfer functions */
-Static usbd_status umass_polled_transfer(struct umass_softc *sc,
+usbd_status umass_polled_transfer(struct umass_softc *sc,
usbd_xfer_handle xfer);
-Static usbd_status umass_setup_transfer(struct umass_softc *sc,
+usbd_status umass_setup_transfer(struct umass_softc *sc,
usbd_pipe_handle pipe,
void *buffer, int buflen, int flags,
usbd_xfer_handle xfer);
-Static usbd_status umass_setup_ctrl_transfer(struct umass_softc *sc,
+usbd_status umass_setup_ctrl_transfer(struct umass_softc *sc,
usb_device_request_t *req,
void *buffer, int buflen, int flags,
usbd_xfer_handle xfer);
-Static void umass_clear_endpoint_stall(struct umass_softc *sc, int endpt,
+void umass_clear_endpoint_stall(struct umass_softc *sc, int endpt,
usbd_xfer_handle xfer);
-Static void umass_adjust_transfer(struct umass_softc *);
+void umass_adjust_transfer(struct umass_softc *);
#if 0
-Static void umass_reset(struct umass_softc *sc, transfer_cb_f cb, void *priv);
+void umass_reset(struct umass_softc *sc, transfer_cb_f cb, void *priv);
#endif
/* Bulk-Only related functions */
-Static void umass_bbb_transfer(struct umass_softc *, int, void *, int, void *,
+void umass_bbb_transfer(struct umass_softc *, int, void *, int, void *,
int, int, u_int, umass_callback, void *);
-Static void umass_bbb_reset(struct umass_softc *, int);
-Static void umass_bbb_state(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void umass_bbb_reset(struct umass_softc *, int);
+void umass_bbb_state(usbd_xfer_handle, usbd_private_handle, usbd_status);
usbd_status umass_bbb_get_max_lun(struct umass_softc *, u_int8_t *);
/* CBI related functions */
-Static void umass_cbi_transfer(struct umass_softc *, int, void *, int, void *,
+void umass_cbi_transfer(struct umass_softc *, int, void *, int, void *,
int, int, u_int, umass_callback, void *);
-Static void umass_cbi_reset(struct umass_softc *, int);
-Static void umass_cbi_state(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void umass_cbi_reset(struct umass_softc *, int);
+void umass_cbi_state(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static int umass_cbi_adsc(struct umass_softc *, char *, int, usbd_xfer_handle);
+int umass_cbi_adsc(struct umass_softc *, char *, int, usbd_xfer_handle);
const struct umass_wire_methods umass_bbb_methods = {
umass_bbb_transfer,
@@ -236,11 +236,11 @@ const struct umass_wire_methods umass_cbi_methods = {
#ifdef UMASS_DEBUG
/* General debugging functions */
-Static void umass_bbb_dump_cbw(struct umass_softc *sc,
+void umass_bbb_dump_cbw(struct umass_softc *sc,
umass_bbb_cbw_t *cbw);
-Static void umass_bbb_dump_csw(struct umass_softc *sc,
+void umass_bbb_dump_csw(struct umass_softc *sc,
umass_bbb_csw_t *csw);
-Static void umass_dump_buffer(struct umass_softc *sc, u_int8_t *buffer,
+void umass_dump_buffer(struct umass_softc *sc, u_int8_t *buffer,
int buflen, int printlen);
#endif
@@ -701,7 +701,7 @@ umass_activate(struct device *dev, enum devact act)
return (rv);
}
-Static void
+void
umass_disco(struct umass_softc *sc)
{
int i;
@@ -728,7 +728,7 @@ umass_disco(struct umass_softc *sc)
* Generic functions to handle transfers
*/
-Static usbd_status
+usbd_status
umass_polled_transfer(struct umass_softc *sc, usbd_xfer_handle xfer)
{
usbd_status err;
@@ -787,7 +787,7 @@ start_next_xfer:
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
umass_setup_transfer(struct umass_softc *sc, usbd_pipe_handle pipe,
void *buffer, int buflen, int flags,
usbd_xfer_handle xfer)
@@ -823,7 +823,7 @@ umass_setup_transfer(struct umass_softc *sc, usbd_pipe_handle pipe,
}
-Static usbd_status
+usbd_status
umass_setup_ctrl_transfer(struct umass_softc *sc, usb_device_request_t *req,
void *buffer, int buflen, int flags, usbd_xfer_handle xfer)
{
@@ -860,7 +860,7 @@ umass_setup_ctrl_transfer(struct umass_softc *sc, usb_device_request_t *req,
return (USBD_NORMAL_COMPLETION);
}
-Static void
+void
umass_adjust_transfer(struct umass_softc *sc)
{
switch (sc->sc_cmd) {
@@ -895,7 +895,7 @@ umass_adjust_transfer(struct umass_softc *sc)
}
}
-Static void
+void
umass_clear_endpoint_stall(struct umass_softc *sc, int endpt,
usbd_xfer_handle xfer)
{
@@ -916,7 +916,7 @@ umass_clear_endpoint_stall(struct umass_softc *sc, int endpt,
}
#if 0
-Static void
+void
umass_reset(struct umass_softc *sc, transfer_cb_f cb, void *priv)
{
sc->transfer_cb = cb;
@@ -931,7 +931,7 @@ umass_reset(struct umass_softc *sc, transfer_cb_f cb, void *priv)
* Bulk protocol specific functions
*/
-Static void
+void
umass_bbb_reset(struct umass_softc *sc, int status)
{
KASSERT(sc->sc_wire & UMASS_WPROTO_BBB,
@@ -973,7 +973,7 @@ umass_bbb_reset(struct umass_softc *sc, int status)
sc->transfer_xfer[XFER_BBB_RESET1]);
}
-Static void
+void
umass_bbb_transfer(struct umass_softc *sc, int lun, void *cmd, int cmdlen,
void *data, int datalen, int dir, u_int timeout,
umass_callback cb, void *priv)
@@ -1094,7 +1094,7 @@ umass_bbb_transfer(struct umass_softc *sc, int lun, void *cmd, int cmdlen,
sc->polled_xfer_status = err;
}
-Static void
+void
umass_bbb_state(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status err)
{
@@ -1406,7 +1406,7 @@ umass_bbb_state(usbd_xfer_handle xfer, usbd_private_handle priv,
* Command/Bulk/Interrupt (CBI) specific functions
*/
-Static int
+int
umass_cbi_adsc(struct umass_softc *sc, char *buffer, int buflen,
usbd_xfer_handle xfer)
{
@@ -1424,7 +1424,7 @@ umass_cbi_adsc(struct umass_softc *sc, char *buffer, int buflen,
}
-Static void
+void
umass_cbi_reset(struct umass_softc *sc, int status)
{
int i;
@@ -1476,7 +1476,7 @@ umass_cbi_reset(struct umass_softc *sc, int status)
/* XXX if the command fails we should reset the port on the bub */
}
-Static void
+void
umass_cbi_transfer(struct umass_softc *sc, int lun,
void *cmd, int cmdlen, void *data, int datalen, int dir,
u_int timeout, umass_callback cb, void *priv)
@@ -1547,7 +1547,7 @@ umass_cbi_transfer(struct umass_softc *sc, int lun,
sc->polled_xfer_status = err;
}
-Static void
+void
umass_cbi_state(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status err)
{
@@ -1889,7 +1889,7 @@ umass_bbb_get_max_lun(struct umass_softc *sc, u_int8_t *maxlun)
}
#ifdef UMASS_DEBUG
-Static void
+void
umass_bbb_dump_cbw(struct umass_softc *sc, umass_bbb_cbw_t *cbw)
{
int clen = cbw->bCDBLength;
@@ -1909,7 +1909,7 @@ umass_bbb_dump_cbw(struct umass_softc *sc, umass_bbb_cbw_t *cbw)
(flags == CBWFLAGS_OUT? "out":"<invalid>"))));
}
-Static void
+void
umass_bbb_dump_csw(struct umass_softc *sc, umass_bbb_csw_t *csw)
{
int sig = UGETDW(csw->dCSWSignature);
@@ -1926,7 +1926,7 @@ umass_bbb_dump_csw(struct umass_softc *sc, umass_bbb_csw_t *csw)
(status == CSWSTATUS_PHASE? "phase":"<invalid>")))));
}
-Static void
+void
umass_dump_buffer(struct umass_softc *sc, u_int8_t *buffer, int buflen,
int printlen)
{
diff --git a/sys/dev/usb/umass_quirks.c b/sys/dev/usb/umass_quirks.c
index c219e5626b5..a192316e12f 100644
--- a/sys/dev/usb/umass_quirks.c
+++ b/sys/dev/usb/umass_quirks.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: umass_quirks.c,v 1.26 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: umass_quirks.c,v 1.27 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: umass_quirks.c,v 1.67 2004/06/28 07:49:16 mycroft Exp $ */
/*
@@ -52,13 +52,13 @@
#include <dev/usb/umassvar.h>
#include <dev/usb/umass_quirks.h>
-Static usbd_status umass_init_insystem(struct umass_softc *);
-Static usbd_status umass_init_shuttle(struct umass_softc *);
+usbd_status umass_init_insystem(struct umass_softc *);
+usbd_status umass_init_shuttle(struct umass_softc *);
-Static void umass_fixup_sony(struct umass_softc *);
-Static void umass_fixup_yedata(struct umass_softc *);
+void umass_fixup_sony(struct umass_softc *);
+void umass_fixup_yedata(struct umass_softc *);
-Static const struct umass_quirk umass_quirks[] = {
+const struct umass_quirk umass_quirks[] = {
{ { USB_VENDOR_ATI, USB_PRODUCT_ATI2_205 },
UMASS_WPROTO_BBB, UMASS_CPROTO_ISD_ATA,
0,
@@ -473,7 +473,7 @@ umass_lookup(u_int16_t vendor, u_int16_t product)
usb_lookup(umass_quirks, vendor, product));
}
-Static usbd_status
+usbd_status
umass_init_insystem(struct umass_softc *sc)
{
usbd_status err;
@@ -489,7 +489,7 @@ umass_init_insystem(struct umass_softc *sc)
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
umass_init_shuttle(struct umass_softc *sc)
{
usb_device_request_t req;
@@ -505,7 +505,7 @@ umass_init_shuttle(struct umass_softc *sc)
return (usbd_do_request(sc->sc_udev, &req, &status));
}
-Static void
+void
umass_fixup_sony(struct umass_softc *sc)
{
usb_interface_descriptor_t *id;
@@ -530,7 +530,7 @@ umass_fixup_sony(struct umass_softc *sc)
}
}
-Static void
+void
umass_fixup_yedata(struct umass_softc *sc)
{
usb_device_descriptor_t *dd;
diff --git a/sys/dev/usb/umct.c b/sys/dev/usb/umct.c
index 1b229266558..0f05197e0c8 100644
--- a/sys/dev/usb/umct.c
+++ b/sys/dev/usb/umct.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: umct.c,v 1.19 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: umct.c,v 1.20 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: umct.c,v 1.10 2003/02/23 04:20:07 simonb Exp $ */
/*
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -116,20 +116,20 @@ struct umct_softc {
#define UMCTIBUFSIZE 256
#define UMCTOBUFSIZE 256
-Static void umct_init(struct umct_softc *);
-Static void umct_set_baudrate(struct umct_softc *, u_int);
-Static void umct_set_lcr(struct umct_softc *, u_int);
-Static void umct_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-
-Static void umct_set(void *, int, int, int);
-Static void umct_dtr(struct umct_softc *, int);
-Static void umct_rts(struct umct_softc *, int);
-Static void umct_break(struct umct_softc *, int);
-Static void umct_set_line_state(struct umct_softc *);
-Static void umct_get_status(void *, int portno, u_char *lsr, u_char *msr);
-Static int umct_param(void *, int, struct termios *);
-Static int umct_open(void *, int);
-Static void umct_close(void *, int);
+void umct_init(struct umct_softc *);
+void umct_set_baudrate(struct umct_softc *, u_int);
+void umct_set_lcr(struct umct_softc *, u_int);
+void umct_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+
+void umct_set(void *, int, int, int);
+void umct_dtr(struct umct_softc *, int);
+void umct_rts(struct umct_softc *, int);
+void umct_break(struct umct_softc *, int);
+void umct_set_line_state(struct umct_softc *);
+void umct_get_status(void *, int portno, u_char *lsr, u_char *msr);
+int umct_param(void *, int, struct termios *);
+int umct_open(void *, int);
+void umct_close(void *, int);
struct ucom_methods umct_methods = {
umct_get_status,
diff --git a/sys/dev/usb/umodem.c b/sys/dev/usb/umodem.c
index f6c3025fbdb..9d9785b82a9 100644
--- a/sys/dev/usb/umodem.c
+++ b/sys/dev/usb/umodem.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: umodem.c,v 1.25 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: umodem.c,v 1.26 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: umodem.c,v 1.45 2002/09/23 05:51:23 simonb Exp $ */
/*
@@ -122,24 +122,24 @@ struct umodem_softc {
u_char sc_msr; /* Modem status register */
};
-Static usbd_status umodem_set_comm_feature(struct umodem_softc *sc,
+usbd_status umodem_set_comm_feature(struct umodem_softc *sc,
int feature, int state);
-Static usbd_status umodem_set_line_coding(struct umodem_softc *sc,
+usbd_status umodem_set_line_coding(struct umodem_softc *sc,
usb_cdc_line_state_t *state);
-Static void umodem_get_status(void *, int portno, u_char *lsr, u_char *msr);
-Static void umodem_set(void *, int, int, int);
-Static void umodem_dtr(struct umodem_softc *, int);
-Static void umodem_rts(struct umodem_softc *, int);
-Static void umodem_break(struct umodem_softc *, int);
-Static void umodem_set_line_state(struct umodem_softc *);
-Static int umodem_param(void *, int, struct termios *);
-Static int umodem_ioctl(void *, int, u_long, caddr_t, int, usb_proc_ptr);
-Static int umodem_open(void *, int portno);
-Static void umodem_close(void *, int portno);
-Static void umodem_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-
-Static struct ucom_methods umodem_methods = {
+void umodem_get_status(void *, int portno, u_char *lsr, u_char *msr);
+void umodem_set(void *, int, int, int);
+void umodem_dtr(struct umodem_softc *, int);
+void umodem_rts(struct umodem_softc *, int);
+void umodem_break(struct umodem_softc *, int);
+void umodem_set_line_state(struct umodem_softc *);
+int umodem_param(void *, int, struct termios *);
+int umodem_ioctl(void *, int, u_long, caddr_t, int, usb_proc_ptr);
+int umodem_open(void *, int portno);
+void umodem_close(void *, int portno);
+void umodem_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+
+struct ucom_methods umodem_methods = {
umodem_get_status,
umodem_set,
umodem_param,
@@ -377,7 +377,7 @@ umodem_attach(struct device *parent, struct device *self, void *aux)
sc->sc_dying = 1;
}
-Static int
+int
umodem_open(void *addr, int portno)
{
struct umodem_softc *sc = addr;
@@ -401,7 +401,7 @@ umodem_open(void *addr, int portno)
return 0;
}
-Static void
+void
umodem_close(void *addr, int portno)
{
struct umodem_softc *sc = addr;
@@ -422,7 +422,7 @@ umodem_close(void *addr, int portno)
}
}
-Static void
+void
umodem_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct umodem_softc *sc = priv;
diff --git a/sys/dev/usb/ums.c b/sys/dev/usb/ums.c
index f14d57914d1..06aaa1b30c0 100644
--- a/sys/dev/usb/ums.c
+++ b/sys/dev/usb/ums.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ums.c,v 1.20 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: ums.c,v 1.21 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: ums.c,v 1.60 2003/03/11 16:44:00 augustss Exp $ */
/*
@@ -112,11 +112,11 @@ struct ums_softc {
#define MOUSE_FLAGS_MASK (HIO_CONST|HIO_RELATIVE)
#define MOUSE_FLAGS (HIO_RELATIVE)
-Static void ums_intr(struct uhidev *addr, void *ibuf, u_int len);
+void ums_intr(struct uhidev *addr, void *ibuf, u_int len);
-Static int ums_enable(void *);
-Static void ums_disable(void *);
-Static int ums_ioctl(void *, u_long, caddr_t, int, usb_proc_ptr);
+int ums_enable(void *);
+void ums_disable(void *);
+int ums_ioctl(void *, u_long, caddr_t, int, usb_proc_ptr);
const struct wsmouse_accessops ums_accessops = {
ums_enable,
@@ -335,7 +335,7 @@ ums_intr(struct uhidev *addr, void *ibuf, u_int len)
}
}
-Static int
+int
ums_enable(void *v)
{
struct ums_softc *sc = v;
@@ -354,7 +354,7 @@ ums_enable(void *v)
return (uhidev_open(&sc->sc_hdev));
}
-Static void
+void
ums_disable(void *v)
{
struct ums_softc *sc = v;
@@ -371,7 +371,7 @@ ums_disable(void *v)
uhidev_close(&sc->sc_hdev);
}
-Static int
+int
ums_ioctl(void *v, u_long cmd, caddr_t data, int flag, usb_proc_ptr p)
{
diff --git a/sys/dev/usb/uow.c b/sys/dev/usb/uow.c
index 7773ecae8d7..f32b6ea52ad 100644
--- a/sys/dev/usb/uow.c
+++ b/sys/dev/usb/uow.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uow.c,v 1.15 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uow.c,v 1.16 2007/06/05 08:43:56 mbalmer Exp $ */
/*
* Copyright (c) 2006 Alexander Yurchenko <grange@openbsd.org>
@@ -67,24 +67,24 @@ static const struct usb_devno uow_devs[] = {
{ USB_VENDOR_DALLAS, USB_PRODUCT_DALLAS_USB_FOB_IBUTTON }
};
-Static int uow_ow_reset(void *);
-Static int uow_ow_bit(void *, int);
-Static int uow_ow_read_byte(void *);
-Static void uow_ow_write_byte(void *, int);
-Static void uow_ow_read_block(void *, void *, int);
-Static void uow_ow_write_block(void *, const void *, int);
-Static void uow_ow_matchrom(void *, u_int64_t);
-Static int uow_ow_search(void *, u_int64_t *, int, u_int64_t);
+int uow_ow_reset(void *);
+int uow_ow_bit(void *, int);
+int uow_ow_read_byte(void *);
+void uow_ow_write_byte(void *, int);
+void uow_ow_read_block(void *, void *, int);
+void uow_ow_write_block(void *, const void *, int);
+void uow_ow_matchrom(void *, u_int64_t);
+int uow_ow_search(void *, u_int64_t *, int, u_int64_t);
-Static int uow_cmd(struct uow_softc *, int, int, int);
+int uow_cmd(struct uow_softc *, int, int, int);
#define uow_ctlcmd(s, c, p) uow_cmd((s), DS2490_CONTROL_CMD, (c), (p))
#define uow_commcmd(s, c, p) uow_cmd((s), DS2490_COMM_CMD, (c), (p))
#define uow_modecmd(s, c, p) uow_cmd((s), DS2490_MODE_CMD, (c), (p))
-Static void uow_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static int uow_read(struct uow_softc *, void *, int);
-Static int uow_write(struct uow_softc *, const void *, int);
-Static int uow_reset(struct uow_softc *);
+void uow_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+int uow_read(struct uow_softc *, void *, int);
+int uow_write(struct uow_softc *, const void *, int);
+int uow_reset(struct uow_softc *);
int
uow_match(struct device *parent, void *match, void *aux)
@@ -281,7 +281,7 @@ uow_activate(device_ptr_t self, enum devact act)
return (rv);
}
-Static int
+int
uow_ow_reset(void *arg)
{
struct uow_softc *sc = arg;
@@ -293,7 +293,7 @@ uow_ow_reset(void *arg)
return (0);
}
-Static int
+int
uow_ow_bit(void *arg, int value)
{
struct uow_softc *sc = arg;
@@ -308,7 +308,7 @@ uow_ow_bit(void *arg, int value)
return (data);
}
-Static int
+int
uow_ow_read_byte(void *arg)
{
struct uow_softc *sc = arg;
@@ -322,7 +322,7 @@ uow_ow_read_byte(void *arg)
return (data);
}
-Static void
+void
uow_ow_write_byte(void *arg, int value)
{
struct uow_softc *sc = arg;
@@ -333,7 +333,7 @@ uow_ow_write_byte(void *arg, int value)
uow_read(sc, &data, sizeof(data));
}
-Static void
+void
uow_ow_read_block(void *arg, void *buf, int len)
{
struct uow_softc *sc = arg;
@@ -345,7 +345,7 @@ uow_ow_read_block(void *arg, void *buf, int len)
uow_read(sc, buf, len);
}
-Static void
+void
uow_ow_write_block(void *arg, const void *buf, int len)
{
struct uow_softc *sc = arg;
@@ -356,7 +356,7 @@ uow_ow_write_block(void *arg, const void *buf, int len)
return;
}
-Static void
+void
uow_ow_matchrom(void *arg, u_int64_t rom)
{
struct uow_softc *sc = arg;
@@ -373,7 +373,7 @@ uow_ow_matchrom(void *arg, u_int64_t rom)
return;
}
-Static int
+int
uow_ow_search(void *arg, u_int64_t *buf, int size, u_int64_t startrom)
{
struct uow_softc *sc = arg;
@@ -396,7 +396,7 @@ uow_ow_search(void *arg, u_int64_t *buf, int size, u_int64_t startrom)
return (rv / 8);
}
-Static int
+int
uow_cmd(struct uow_softc *sc, int type, int cmd, int param)
{
usb_device_request_t req;
@@ -430,7 +430,7 @@ again:
return (0);
}
-Static void
+void
uow_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct uow_softc *sc = priv;
@@ -446,7 +446,7 @@ uow_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
wakeup(sc->sc_regs);
}
-Static int
+int
uow_read(struct uow_softc *sc, void *buf, int len)
{
usbd_status error;
@@ -478,7 +478,7 @@ uow_read(struct uow_softc *sc, void *buf, int len)
return (count);
}
-Static int
+int
uow_write(struct uow_softc *sc, const void *buf, int len)
{
usbd_status error;
@@ -508,7 +508,7 @@ uow_write(struct uow_softc *sc, const void *buf, int len)
return (0);
}
-Static int
+int
uow_reset(struct uow_softc *sc)
{
return (uow_ctlcmd(sc, DS2490_CTL_RESET_DEVICE, 0));
diff --git a/sys/dev/usb/uplcom.c b/sys/dev/usb/uplcom.c
index d8071d14d17..5c9fb48a915 100644
--- a/sys/dev/usb/uplcom.c
+++ b/sys/dev/usb/uplcom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uplcom.c,v 1.35 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uplcom.c,v 1.36 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: uplcom.c,v 1.29 2002/09/23 05:51:23 simonb Exp $ */
/*
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -120,24 +120,24 @@ struct uplcom_softc {
#define UPLCOMIBUFSIZE 256
#define UPLCOMOBUFSIZE 256
-Static usbd_status uplcom_reset(struct uplcom_softc *);
-Static usbd_status uplcom_set_line_coding(struct uplcom_softc *sc,
+usbd_status uplcom_reset(struct uplcom_softc *);
+usbd_status uplcom_set_line_coding(struct uplcom_softc *sc,
usb_cdc_line_state_t *state);
-Static usbd_status uplcom_set_crtscts(struct uplcom_softc *);
-Static void uplcom_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-
-Static void uplcom_set(void *, int, int, int);
-Static void uplcom_dtr(struct uplcom_softc *, int);
-Static void uplcom_rts(struct uplcom_softc *, int);
-Static void uplcom_break(struct uplcom_softc *, int);
-Static void uplcom_set_line_state(struct uplcom_softc *);
-Static void uplcom_get_status(void *, int portno, u_char *lsr, u_char *msr);
+usbd_status uplcom_set_crtscts(struct uplcom_softc *);
+void uplcom_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+
+void uplcom_set(void *, int, int, int);
+void uplcom_dtr(struct uplcom_softc *, int);
+void uplcom_rts(struct uplcom_softc *, int);
+void uplcom_break(struct uplcom_softc *, int);
+void uplcom_set_line_state(struct uplcom_softc *);
+void uplcom_get_status(void *, int portno, u_char *lsr, u_char *msr);
#if TODO
-Static int uplcom_ioctl(void *, int, u_long, caddr_t, int, usb_proc_ptr);
+int uplcom_ioctl(void *, int, u_long, caddr_t, int, usb_proc_ptr);
#endif
-Static int uplcom_param(void *, int, struct termios *);
-Static int uplcom_open(void *, int);
-Static void uplcom_close(void *, int);
+int uplcom_param(void *, int, struct termios *);
+int uplcom_open(void *, int);
+void uplcom_close(void *, int);
struct ucom_methods uplcom_methods = {
uplcom_get_status,
diff --git a/sys/dev/usb/usb.c b/sys/dev/usb/usb.c
index 36abf61bb0c..d5cb2f6e501 100644
--- a/sys/dev/usb/usb.c
+++ b/sys/dev/usb/usb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usb.c,v 1.41 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: usb.c,v 1.42 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usb.c,v 1.77 2003/01/01 00:10:26 thorpej Exp $ */
/*
@@ -105,30 +105,30 @@ struct usb_softc {
TAILQ_HEAD(, usb_task) usb_all_tasks;
-Static volatile int threads_pending = 0;
+volatile int threads_pending = 0;
-Static void usb_discover(void *);
-Static void usb_create_event_thread(void *);
-Static void usb_event_thread(void *);
-Static void usb_task_thread(void *);
-Static usb_proc_ptr usb_task_thread_proc = NULL;
+void usb_discover(void *);
+void usb_create_event_thread(void *);
+void usb_event_thread(void *);
+void usb_task_thread(void *);
+usb_proc_ptr usb_task_thread_proc = NULL;
#define USB_MAX_EVENTS 100
struct usb_event_q {
struct usb_event ue;
SIMPLEQ_ENTRY(usb_event_q) next;
};
-Static SIMPLEQ_HEAD(, usb_event_q) usb_events =
+SIMPLEQ_HEAD(, usb_event_q) usb_events =
SIMPLEQ_HEAD_INITIALIZER(usb_events);
-Static int usb_nevents = 0;
-Static struct selinfo usb_selevent;
-Static usb_proc_ptr usb_async_proc; /* process that wants USB SIGIO */
-Static int usb_dev_open = 0;
-Static void usb_add_event(int, struct usb_event *);
+int usb_nevents = 0;
+struct selinfo usb_selevent;
+usb_proc_ptr usb_async_proc; /* process that wants USB SIGIO */
+int usb_dev_open = 0;
+void usb_add_event(int, struct usb_event *);
-Static int usb_get_next_event(struct usb_event *);
+int usb_get_next_event(struct usb_event *);
-Static const char *usbrev_str[] = USBREV_STR;
+const char *usbrev_str[] = USBREV_STR;
USB_DECLARE_DRIVER(usb);
@@ -589,11 +589,11 @@ usbpoll(dev_t dev, int events, usb_proc_ptr p)
}
}
-Static void filt_usbrdetach(struct knote *);
-Static int filt_usbread(struct knote *, long);
+void filt_usbrdetach(struct knote *);
+int filt_usbread(struct knote *, long);
int usbkqfilter(dev_t, struct knote *);
-Static void
+void
filt_usbrdetach(struct knote *kn)
{
int s;
@@ -603,7 +603,7 @@ filt_usbrdetach(struct knote *kn)
splx(s);
}
-Static int
+int
filt_usbread(struct knote *kn, long hint)
{
@@ -614,7 +614,7 @@ filt_usbread(struct knote *kn, long hint)
return (1);
}
-Static struct filterops usbread_filtops =
+struct filterops usbread_filtops =
{ 1, NULL, filt_usbrdetach, filt_usbread };
int
@@ -645,7 +645,7 @@ usbkqfilter(dev_t dev, struct knote *kn)
}
/* Explore device tree from the root. */
-Static void
+void
usb_discover(void *v)
{
struct usb_softc *sc = v;
@@ -726,7 +726,7 @@ usbd_add_drv_event(int type, usbd_device_handle udev, device_ptr_t dev)
usb_add_event(type, &ue);
}
-Static void
+void
usb_add_event(int type, struct usb_event *uep)
{
struct usb_event_q *ueq;
diff --git a/sys/dev/usb/usb_mem.c b/sys/dev/usb/usb_mem.c
index 8b1d9d89c49..a93aa332a4a 100644
--- a/sys/dev/usb/usb_mem.c
+++ b/sys/dev/usb/usb_mem.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usb_mem.c,v 1.18 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: usb_mem.c,v 1.19 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usb_mem.c,v 1.26 2003/02/01 06:23:40 thorpej Exp $ */
/*
@@ -82,18 +82,18 @@ struct usb_frag_dma {
LIST_ENTRY(usb_frag_dma) next;
};
-Static usbd_status usb_block_allocmem(bus_dma_tag_t, size_t, size_t,
+usbd_status usb_block_allocmem(bus_dma_tag_t, size_t, size_t,
usb_dma_block_t **);
-Static void usb_block_freemem(usb_dma_block_t *);
+void usb_block_freemem(usb_dma_block_t *);
-Static LIST_HEAD(, usb_dma_block) usb_blk_freelist =
+LIST_HEAD(, usb_dma_block) usb_blk_freelist =
LIST_HEAD_INITIALIZER(usb_blk_freelist);
-Static int usb_blk_nfree = 0;
+int usb_blk_nfree = 0;
/* XXX should have different free list for different tags (for speed) */
-Static LIST_HEAD(, usb_frag_dma) usb_frag_freelist =
+LIST_HEAD(, usb_frag_dma) usb_frag_freelist =
LIST_HEAD_INITIALIZER(usb_frag_freelist);
-Static usbd_status
+usbd_status
usb_block_allocmem(bus_dma_tag_t tag, size_t size, size_t align,
usb_dma_block_t **dmap)
{
@@ -199,7 +199,7 @@ usb_block_real_freemem(usb_dma_block_t *p)
* from an interrupt context and that is BAD.
* XXX when should we really free?
*/
-Static void
+void
usb_block_freemem(usb_dma_block_t *p)
{
int s;
diff --git a/sys/dev/usb/usb_port.h b/sys/dev/usb/usb_port.h
index c9b611ebf9f..700053662c3 100644
--- a/sys/dev/usb/usb_port.h
+++ b/sys/dev/usb/usb_port.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: usb_port.h,v 1.69 2007/05/29 19:57:45 mbalmer Exp $ */
+/* $OpenBSD: usb_port.h,v 1.70 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usb_port.h,v 1.62 2003/02/15 18:33:30 augustss Exp $ */
/* $FreeBSD: src/sys/dev/usb/usb_port.h,v 1.21 1999/11/17 22:33:47 n_hibma Exp $ */
@@ -86,8 +86,6 @@
#define UDCF_DEBUG 1
#endif
-#define Static
-
#define UMASS_ATAPISTR "atapiscsi"
/* periph_quirks */
diff --git a/sys/dev/usb/usb_quirks.c b/sys/dev/usb/usb_quirks.c
index 05635726e28..13c7f3337af 100644
--- a/sys/dev/usb/usb_quirks.c
+++ b/sys/dev/usb/usb_quirks.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usb_quirks.c,v 1.28 2007/05/22 09:55:15 robert Exp $ */
+/* $OpenBSD: usb_quirks.c,v 1.29 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usb_quirks.c,v 1.45 2003/05/10 17:47:14 hamajima Exp $ */
/* $FreeBSD: src/sys/dev/usb/usb_quirks.c,v 1.30 2003/01/02 04:15:55 imp Exp $ */
@@ -53,7 +53,7 @@ extern int usbdebug;
#define ANY 0xffff
-Static const struct usbd_quirk_entry {
+const struct usbd_quirk_entry {
u_int16_t idVendor;
u_int16_t idProduct;
u_int16_t bcdDevice;
diff --git a/sys/dev/usb/usb_subr.c b/sys/dev/usb/usb_subr.c
index 9d702810c78..aeb3945d7dc 100644
--- a/sys/dev/usb/usb_subr.c
+++ b/sys/dev/usb/usb_subr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usb_subr.c,v 1.50 2007/06/03 20:49:25 deraadt Exp $ */
+/* $OpenBSD: usb_subr.c,v 1.51 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usb_subr.c,v 1.103 2003/01/10 11:19:13 augustss Exp $ */
/* $FreeBSD: src/sys/dev/usb/usb_subr.c,v 1.18 1999/11/17 22:33:47 n_hibma Exp $ */
@@ -66,26 +66,26 @@ extern int usbdebug;
#define DPRINTFN(n,x)
#endif
-Static usbd_status usbd_set_config(usbd_device_handle, int);
-Static void usbd_devinfo(usbd_device_handle, int, char *, size_t);
-Static void usbd_devinfo_vp(usbd_device_handle, char *, char *,
+usbd_status usbd_set_config(usbd_device_handle, int);
+void usbd_devinfo(usbd_device_handle, int, char *, size_t);
+void usbd_devinfo_vp(usbd_device_handle, char *, char *,
int);
-Static char *usbd_get_string(usbd_device_handle, int, char *);
-Static int usbd_getnewaddr(usbd_bus_handle);
-Static int usbd_print(void *, const char *);
-Static int usbd_submatch(device_ptr_t, void *, void *);
-Static void usbd_free_iface_data(usbd_device_handle, int);
-Static void usbd_kill_pipe(usbd_pipe_handle);
-Static usbd_status usbd_probe_and_attach(device_ptr_t,
+char *usbd_get_string(usbd_device_handle, int, char *);
+int usbd_getnewaddr(usbd_bus_handle);
+int usbd_print(void *, const char *);
+int usbd_submatch(device_ptr_t, void *, void *);
+void usbd_free_iface_data(usbd_device_handle, int);
+void usbd_kill_pipe(usbd_pipe_handle);
+usbd_status usbd_probe_and_attach(device_ptr_t,
usbd_device_handle, int, int);
-Static u_int32_t usb_cookie_no = 0;
+u_int32_t usb_cookie_no = 0;
#ifdef USBVERBOSE
#include <dev/usb/usbdevs_data.h>
#endif /* USBVERBOSE */
-Static const char * const usbd_error_strs[] = {
+const char * const usbd_error_strs[] = {
"NORMAL_COMPLETION",
"IN_PROGRESS",
"PENDING_REQUESTS",
@@ -290,7 +290,7 @@ usbd_printBCD(char *cp, size_t len, int bcd)
return (l);
}
-Static void
+void
usbd_devinfo(usbd_device_handle dev, int showclass, char *base, size_t len)
{
usb_device_descriptor_t *udd = &dev->ddesc;
@@ -561,7 +561,7 @@ usbd_free_iface_data(usbd_device_handle dev, int ifcno)
free(ifc->endpoints, M_USB);
}
-Static usbd_status
+usbd_status
usbd_set_config(usbd_device_handle dev, int conf)
{
usb_device_request_t req;
diff --git a/sys/dev/usb/usbdi.c b/sys/dev/usb/usbdi.c
index 6a810f6431f..1cc6d81712c 100644
--- a/sys/dev/usb/usbdi.c
+++ b/sys/dev/usb/usbdi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usbdi.c,v 1.30 2007/05/31 18:20:22 mbalmer Exp $ */
+/* $OpenBSD: usbdi.c,v 1.31 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usbdi.c,v 1.103 2002/09/27 15:37:38 provos Exp $ */
/* $FreeBSD: src/sys/dev/usb/usbdi.c,v 1.28 1999/11/17 22:33:49 n_hibma Exp $ */
@@ -63,14 +63,14 @@ extern int usbdebug;
#define DPRINTFN(n,x)
#endif
-Static usbd_status usbd_ar_pipe(usbd_pipe_handle pipe);
-Static void usbd_do_request_async_cb
+usbd_status usbd_ar_pipe(usbd_pipe_handle pipe);
+void usbd_do_request_async_cb
(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static void usbd_start_next(usbd_pipe_handle pipe);
-Static usbd_status usbd_open_pipe_ival
+void usbd_start_next(usbd_pipe_handle pipe);
+usbd_status usbd_open_pipe_ival
(usbd_interface_handle, u_int8_t, u_int8_t, usbd_pipe_handle *, int);
-Static int usbd_nbuses = 0;
+int usbd_nbuses = 0;
void
usbd_init(void)
@@ -705,7 +705,7 @@ usbd_get_interface(usbd_interface_handle iface, u_int8_t *aiface)
/*** Internal routines ***/
/* Dequeue all pipe operations, called at splusb(). */
-Static usbd_status
+usbd_status
usbd_ar_pipe(usbd_pipe_handle pipe)
{
usbd_xfer_handle xfer;
diff --git a/sys/dev/usb/usbdi_util.c b/sys/dev/usb/usbdi_util.c
index 06a95fdbf0c..fd23bfdbd19 100644
--- a/sys/dev/usb/usbdi_util.c
+++ b/sys/dev/usb/usbdi_util.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usbdi_util.c,v 1.19 2007/05/31 18:20:22 mbalmer Exp $ */
+/* $OpenBSD: usbdi_util.c,v 1.20 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usbdi_util.c,v 1.40 2002/07/11 21:14:36 augustss Exp $ */
/* $FreeBSD: src/sys/dev/usb/usbdi_util.c,v 1.14 1999/11/17 22:33:50 n_hibma Exp $ */
@@ -419,9 +419,9 @@ usbd_get_config(usbd_device_handle dev, u_int8_t *conf)
return (usbd_do_request(dev, &req, conf));
}
-Static void usbd_bulk_transfer_cb(usbd_xfer_handle xfer,
+void usbd_bulk_transfer_cb(usbd_xfer_handle xfer,
usbd_private_handle priv, usbd_status status);
-Static void
+void
usbd_bulk_transfer_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -461,9 +461,9 @@ usbd_bulk_transfer(usbd_xfer_handle xfer, usbd_pipe_handle pipe,
return (err);
}
-Static void usbd_intr_transfer_cb(usbd_xfer_handle xfer,
+void usbd_intr_transfer_cb(usbd_xfer_handle xfer,
usbd_private_handle priv, usbd_status status);
-Static void
+void
usbd_intr_transfer_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
diff --git a/sys/dev/usb/uscanner.c b/sys/dev/usb/uscanner.c
index 31cfbd287e7..0187cde656b 100644
--- a/sys/dev/usb/uscanner.c
+++ b/sys/dev/usb/uscanner.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uscanner.c,v 1.25 2007/05/31 18:20:22 mbalmer Exp $ */
+/* $OpenBSD: uscanner.c,v 1.26 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: uscanner.c,v 1.40 2003/01/27 00:32:44 wiz Exp $ */
/*
@@ -232,9 +232,9 @@ struct uscanner_softc {
u_char sc_dying;
};
-Static int uscanner_do_read(struct uscanner_softc *, struct uio *, int);
-Static int uscanner_do_write(struct uscanner_softc *, struct uio *, int);
-Static void uscanner_do_close(struct uscanner_softc *);
+int uscanner_do_read(struct uscanner_softc *, struct uio *, int);
+int uscanner_do_write(struct uscanner_softc *, struct uio *, int);
+void uscanner_do_close(struct uscanner_softc *);
#define USCANNERUNIT(n) (minor(n))
@@ -445,7 +445,7 @@ uscanner_do_close(struct uscanner_softc *sc)
sc->sc_state &= ~USCANNER_OPEN;
}
-Static int
+int
uscanner_do_read(struct uscanner_softc *sc, struct uio *uio, int flag)
{
u_int32_t n, tn;
@@ -500,7 +500,7 @@ uscannerread(dev_t dev, struct uio *uio, int flag)
return (error);
}
-Static int
+int
uscanner_do_write(struct uscanner_softc *sc, struct uio *uio, int flag)
{
u_int32_t n;
@@ -632,10 +632,10 @@ uscannerioctl(dev_t dev, u_long cmd, caddr_t addr, int flag, usb_proc_ptr p)
return (EINVAL);
}
-Static void filt_uscannerdetach(struct knote *);
+void filt_uscannerdetach(struct knote *);
int uscannerkqfilter(dev_t, struct knote *);
-Static void
+void
filt_uscannerdetach(struct knote *kn)
{
struct uscanner_softc *sc = (void *)kn->kn_hook;
@@ -643,7 +643,7 @@ filt_uscannerdetach(struct knote *kn)
SLIST_REMOVE(&sc->sc_selq.sel_klist, kn, knote, kn_selnext);
}
-Static struct filterops uscanner_seltrue_filtops =
+struct filterops uscanner_seltrue_filtops =
{ 1, NULL, filt_uscannerdetach, filt_seltrue };
int
diff --git a/sys/dev/usb/uslcom.c b/sys/dev/usb/uslcom.c
index e729baacb3a..18d63179f39 100644
--- a/sys/dev/usb/uslcom.c
+++ b/sys/dev/usb/uslcom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uslcom.c,v 1.6 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uslcom.c,v 1.7 2007/06/05 08:43:56 mbalmer Exp $ */
/*
* Copyright (c) 2006 Jonathan Gray <jsg@openbsd.org>
@@ -91,12 +91,12 @@ struct uslcom_softc {
u_char sc_dying;
};
-Static void uslcom_get_status(void *, int portno, u_char *lsr, u_char *msr);
-Static void uslcom_set(void *, int, int, int);
-Static int uslcom_param(void *, int, struct termios *);
-Static int uslcom_open(void *sc, int portno);
-Static void uslcom_close(void *, int);
-Static void uslcom_break(void *sc, int portno, int onoff);
+void uslcom_get_status(void *, int portno, u_char *lsr, u_char *msr);
+void uslcom_set(void *, int, int, int);
+int uslcom_param(void *, int, struct termios *);
+int uslcom_open(void *sc, int portno);
+void uslcom_close(void *, int);
+void uslcom_break(void *sc, int portno, int onoff);
struct ucom_methods uslcom_methods = {
uslcom_get_status,
@@ -257,7 +257,7 @@ uslcom_activate(device_ptr_t self, enum devact act)
return (rv);
}
-Static int
+int
uslcom_open(void *vsc, int portno)
{
struct uslcom_softc *sc = vsc;
@@ -279,7 +279,7 @@ uslcom_open(void *vsc, int portno)
return (0);
}
-Static void
+void
uslcom_close(void *vsc, int portno)
{
struct uslcom_softc *sc = vsc;
@@ -296,7 +296,7 @@ uslcom_close(void *vsc, int portno)
usbd_do_request(sc->sc_udev, &req, NULL);
}
-Static void
+void
uslcom_set(void *vsc, int portno, int reg, int onoff)
{
struct uslcom_softc *sc = vsc;
@@ -326,7 +326,7 @@ uslcom_set(void *vsc, int portno, int reg, int onoff)
usbd_do_request(sc->sc_udev, &req, NULL);
}
-Static int
+int
uslcom_param(void *vsc, int portno, struct termios *t)
{
struct uslcom_softc *sc = (struct uslcom_softc *)vsc;
diff --git a/sys/dev/usb/usscanner.c b/sys/dev/usb/usscanner.c
index 6e3e32036ab..13db5a17ca6 100644
--- a/sys/dev/usb/usscanner.c
+++ b/sys/dev/usb/usscanner.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usscanner.c,v 1.15 2007/06/04 10:34:04 mbalmer Exp $ */
+/* $OpenBSD: usscanner.c,v 1.16 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: usscanner.c,v 1.6 2001/01/23 14:04:14 augustss Exp $ */
/*
@@ -108,7 +108,7 @@ int usscannerdebug = 0;
#define USSCANNER_TIMEOUT 2000
-Static struct scsipi_device usscanner_dev =
+struct scsipi_device usscanner_dev =
{
NULL, /* Use default error handler */
NULL, /* have a queue, served by this */
@@ -158,17 +158,17 @@ struct usscanner_softc {
};
-Static void usscanner_cleanup(struct usscanner_softc *sc);
-Static int usscanner_scsipi_cmd(struct scsipi_xfer *xs);
-Static void usscanner_scsipi_minphys(struct buf *bp);
-Static void usscanner_done(struct usscanner_softc *sc);
-Static void usscanner_sense(struct usscanner_softc *sc);
+void usscanner_cleanup(struct usscanner_softc *sc);
+int usscanner_scsipi_cmd(struct scsipi_xfer *xs);
+void usscanner_scsipi_minphys(struct buf *bp);
+void usscanner_done(struct usscanner_softc *sc);
+void usscanner_sense(struct usscanner_softc *sc);
typedef void callback(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static callback usscanner_intr_cb;
-Static callback usscanner_cmd_cb;
-Static callback usscanner_data_cb;
-Static callback usscanner_sensecmd_cb;
-Static callback usscanner_sensedata_cb;
+callback usscanner_intr_cb;
+callback usscanner_cmd_cb;
+callback usscanner_data_cb;
+callback usscanner_sensecmd_cb;
+callback usscanner_sensedata_cb;
USB_DECLARE_DRIVER(usscanner);
@@ -389,7 +389,7 @@ usscanner_detach(struct device *self, int flags)
return (rv);
}
-Static void
+void
usscanner_cleanup(struct usscanner_softc *sc)
{
if (sc->sc_in_pipe != NULL) {
@@ -430,7 +430,7 @@ usscanner_activate(device_ptr_t self, enum devact act)
return (0);
}
-Static void
+void
usscanner_scsipi_minphys(struct buf *bp)
{
if (bp->b_bcount > USSCANNER_MAX_TRANSFER_SIZE)
@@ -438,7 +438,7 @@ usscanner_scsipi_minphys(struct buf *bp)
minphys(bp);
}
-Static void
+void
usscanner_sense(struct usscanner_softc *sc)
{
struct scsipi_xfer *xs = sc->sc_xs;
@@ -465,7 +465,7 @@ usscanner_sense(struct usscanner_softc *sc)
usscanner_done(sc);
}
-Static void
+void
usscanner_intr_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -492,7 +492,7 @@ usscanner_intr_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
splx(s);
}
-Static void
+void
usscanner_data_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -534,7 +534,7 @@ usscanner_data_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usscanner_done(sc);
}
-Static void
+void
usscanner_sensedata_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -571,7 +571,7 @@ usscanner_sensedata_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usscanner_done(sc);
}
-Static void
+void
usscanner_done(struct usscanner_softc *sc)
{
struct scsipi_xfer *xs = sc->sc_xs;
@@ -589,7 +589,7 @@ usscanner_done(struct usscanner_softc *sc)
xs->error = XS_DRIVER_STUFFUP;
}
-Static void
+void
usscanner_sensecmd_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -636,7 +636,7 @@ usscanner_sensecmd_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usscanner_done(sc);
}
-Static void
+void
usscanner_cmd_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usbd_status status)
{
@@ -702,7 +702,7 @@ usscanner_cmd_cb(usbd_xfer_handle xfer, usbd_private_handle priv,
usscanner_done(sc);
}
-Static int
+int
usscanner_scsipi_cmd(struct scsipi_xfer *xs)
{
struct scsipi_link *sc_link = xs->sc_link;
diff --git a/sys/dev/usb/uts.c b/sys/dev/usb/uts.c
index 2e6b2eeec2f..e920f278312 100644
--- a/sys/dev/usb/uts.c
+++ b/sys/dev/usb/uts.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uts.c,v 1.9 2007/05/31 02:56:03 robert Exp $ */
+/* $OpenBSD: uts.c,v 1.10 2007/06/05 08:43:56 mbalmer Exp $ */
/*
* Copyright (c) 2007 Robert Nagy <robert@openbsd.org>
@@ -92,19 +92,19 @@ struct uts_pos {
int z; /* touch pressure */
};
-Static const struct usb_devno uts_devs[] = {
+const struct usb_devno uts_devs[] = {
{ USB_VENDOR_FTDI, USB_PRODUCT_FTDI_ITM_TOUCH },
{ USB_VENDOR_EGALAX, USB_PRODUCT_EGALAX_TPANEL },
{ USB_VENDOR_EGALAX, USB_PRODUCT_EGALAX_TPANEL2 },
{ USB_VENDOR_GUNZE, USB_PRODUCT_GUNZE_TOUCHPANEL }
};
-Static void uts_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+void uts_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
struct uts_pos uts_get_pos(usbd_private_handle addr, struct uts_pos tp);
-Static int uts_enable(void *);
-Static void uts_disable(void *);
-Static int uts_ioctl(void *, u_long, caddr_t, int, struct proc *);
+int uts_enable(void *);
+void uts_disable(void *);
+int uts_ioctl(void *, u_long, caddr_t, int, struct proc *);
const struct wsmouse_accessops uts_accessops = {
uts_enable,
@@ -262,7 +262,7 @@ uts_activate(device_ptr_t self, enum devact act)
return (rv);
}
-Static int
+int
uts_enable(void *v)
{
struct uts_softc *sc = v;
@@ -292,7 +292,7 @@ uts_enable(void *v)
return (0);
}
-Static void
+void
uts_disable(void *v)
{
struct uts_softc *sc = v;
@@ -317,7 +317,7 @@ uts_disable(void *v)
sc->sc_enabled = 0;
}
-Static int
+int
uts_ioctl(void *v, u_long cmd, caddr_t data, int flag, struct proc *l)
{
int error = 0;
@@ -441,7 +441,7 @@ uts_get_pos(usbd_private_handle addr, struct uts_pos tp)
return (tp);
}
-Static void
+void
uts_intr(usbd_xfer_handle xfer, usbd_private_handle addr, usbd_status status)
{
struct uts_softc *sc = addr;
diff --git a/sys/dev/usb/uvisor.c b/sys/dev/usb/uvisor.c
index 2e88d4f7118..df13e3b712a 100644
--- a/sys/dev/usb/uvisor.c
+++ b/sys/dev/usb/uvisor.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uvisor.c,v 1.28 2007/05/27 04:00:25 jsg Exp $ */
+/* $OpenBSD: uvisor.c,v 1.29 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: uvisor.c,v 1.21 2003/08/03 21:59:26 nathanw Exp $ */
/*
@@ -149,11 +149,11 @@ struct uvisor_softc {
u_char sc_dying;
};
-Static usbd_status uvisor_init(struct uvisor_softc *,
+usbd_status uvisor_init(struct uvisor_softc *,
struct uvisor_connection_info *,
struct uvisor_palm_connection_info *);
-Static void uvisor_close(void *, int);
+void uvisor_close(void *, int);
struct ucom_methods uvisor_methods = {
diff --git a/sys/dev/usb/uvscom.c b/sys/dev/usb/uvscom.c
index 5a9c50d08b5..bf066716a06 100644
--- a/sys/dev/usb/uvscom.c
+++ b/sys/dev/usb/uvscom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uvscom.c,v 1.11 2007/05/31 18:20:22 mbalmer Exp $ */
+/* $OpenBSD: uvscom.c,v 1.12 2007/06/05 08:43:56 mbalmer Exp $ */
/* $NetBSD: uvscom.c,v 1.9 2003/02/12 15:36:20 ichiro Exp $ */
/*-
* Copyright (c) 2001-2002, Shunsuke Akiyama <akiyama@jp.FreeBSD.org>.
@@ -162,23 +162,23 @@ struct uvscom_softc {
#define UVSCOMIBUFSIZE 512
#define UVSCOMOBUFSIZE 64
-Static usbd_status uvscom_readstat(struct uvscom_softc *);
-Static usbd_status uvscom_shutdown(struct uvscom_softc *);
-Static usbd_status uvscom_reset(struct uvscom_softc *);
-Static usbd_status uvscom_set_line_coding(struct uvscom_softc *,
+usbd_status uvscom_readstat(struct uvscom_softc *);
+usbd_status uvscom_shutdown(struct uvscom_softc *);
+usbd_status uvscom_reset(struct uvscom_softc *);
+usbd_status uvscom_set_line_coding(struct uvscom_softc *,
uint16_t, uint16_t);
-Static usbd_status uvscom_set_line(struct uvscom_softc *, uint16_t);
-Static usbd_status uvscom_set_crtscts(struct uvscom_softc *);
-Static void uvscom_get_status(void *, int, u_char *, u_char *);
-Static void uvscom_dtr(struct uvscom_softc *, int);
-Static void uvscom_rts(struct uvscom_softc *, int);
-Static void uvscom_break(struct uvscom_softc *, int);
-
-Static void uvscom_set(void *, int, int, int);
-Static void uvscom_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
-Static int uvscom_param(void *, int, struct termios *);
-Static int uvscom_open(void *, int);
-Static void uvscom_close(void *, int);
+usbd_status uvscom_set_line(struct uvscom_softc *, uint16_t);
+usbd_status uvscom_set_crtscts(struct uvscom_softc *);
+void uvscom_get_status(void *, int, u_char *, u_char *);
+void uvscom_dtr(struct uvscom_softc *, int);
+void uvscom_rts(struct uvscom_softc *, int);
+void uvscom_break(struct uvscom_softc *, int);
+
+void uvscom_set(void *, int, int, int);
+void uvscom_intr(usbd_xfer_handle, usbd_private_handle, usbd_status);
+int uvscom_param(void *, int, struct termios *);
+int uvscom_open(void *, int);
+void uvscom_close(void *, int);
struct ucom_methods uvscom_methods = {
uvscom_get_status,
@@ -406,7 +406,7 @@ uvscom_activate(device_ptr_t self, enum devact act)
return (rv);
}
-Static usbd_status
+usbd_status
uvscom_readstat(struct uvscom_softc *sc)
{
usb_device_request_t req;
@@ -434,7 +434,7 @@ uvscom_readstat(struct uvscom_softc *sc)
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
uvscom_shutdown(struct uvscom_softc *sc)
{
usb_device_request_t req;
@@ -458,7 +458,7 @@ uvscom_shutdown(struct uvscom_softc *sc)
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
uvscom_reset(struct uvscom_softc *sc)
{
DPRINTF(("%s: uvscom_reset\n", USBDEVNAME(sc->sc_dev)));
@@ -466,7 +466,7 @@ uvscom_reset(struct uvscom_softc *sc)
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
uvscom_set_crtscts(struct uvscom_softc *sc)
{
DPRINTF(("%s: uvscom_set_crtscts\n", USBDEVNAME(sc->sc_dev)));
@@ -474,7 +474,7 @@ uvscom_set_crtscts(struct uvscom_softc *sc)
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
uvscom_set_line(struct uvscom_softc *sc, uint16_t line)
{
usb_device_request_t req;
@@ -499,7 +499,7 @@ uvscom_set_line(struct uvscom_softc *sc, uint16_t line)
return (USBD_NORMAL_COMPLETION);
}
-Static usbd_status
+usbd_status
uvscom_set_line_coding(struct uvscom_softc *sc, uint16_t lsp, uint16_t ls)
{
usb_device_request_t req;
@@ -537,7 +537,7 @@ uvscom_set_line_coding(struct uvscom_softc *sc, uint16_t lsp, uint16_t ls)
return (USBD_NORMAL_COMPLETION);
}
-Static void
+void
uvscom_dtr(struct uvscom_softc *sc, int onoff)
{
DPRINTF(("%s: uvscom_dtr: onoff = %d\n",
@@ -556,7 +556,7 @@ uvscom_dtr(struct uvscom_softc *sc, int onoff)
uvscom_set_line(sc, sc->sc_lcr);
}
-Static void
+void
uvscom_rts(struct uvscom_softc *sc, int onoff)
{
DPRINTF(("%s: uvscom_rts: onoff = %d\n",
@@ -575,7 +575,7 @@ uvscom_rts(struct uvscom_softc *sc, int onoff)
uvscom_set_line(sc, sc->sc_lcr);
}
-Static void
+void
uvscom_break(struct uvscom_softc *sc, int onoff)
{
DPRINTF(("%s: uvscom_break: onoff = %d\n",
@@ -585,7 +585,7 @@ uvscom_break(struct uvscom_softc *sc, int onoff)
uvscom_set_line(sc, SET(sc->sc_lcr, UVSCOM_BREAK));
}
-Static void
+void
uvscom_set(void *addr, int portno, int reg, int onoff)
{
struct uvscom_softc *sc = addr;
@@ -605,7 +605,7 @@ uvscom_set(void *addr, int portno, int reg, int onoff)
}
}
-Static int
+int
uvscom_param(void *addr, int portno, struct termios *t)
{
struct uvscom_softc *sc = addr;
@@ -699,7 +699,7 @@ uvscom_param(void *addr, int portno, struct termios *t)
return (0);
}
-Static int
+int
uvscom_open(void *addr, int portno)
{
struct uvscom_softc *sc = addr;
@@ -768,7 +768,7 @@ uvscom_open(void *addr, int portno)
return (0);
}
-Static void
+void
uvscom_close(void *addr, int portno)
{
struct uvscom_softc *sc = addr;
@@ -797,7 +797,7 @@ uvscom_close(void *addr, int portno)
}
}
-Static void
+void
uvscom_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
{
struct uvscom_softc *sc = priv;
@@ -841,7 +841,7 @@ uvscom_intr(usbd_xfer_handle xfer, usbd_private_handle priv, usbd_status status)
ucom_status_change((struct ucom_softc *) sc->sc_subdev);
}
-Static void
+void
uvscom_get_status(void *addr, int portno, u_char *lsr, u_char *msr)
{
struct uvscom_softc *sc = addr;