summaryrefslogtreecommitdiffstats
path: root/sys/dev/cp
diff options
context:
space:
mode:
authorjkim <jkim@FreeBSD.org>2015-05-22 17:05:21 +0000
committerjkim <jkim@FreeBSD.org>2015-05-22 17:05:21 +0000
commit318c4f97e694c1972b55450cafe914f39977d179 (patch)
tree9c598a67317c5e22e5e44d49e8bb797cb28e79b9 /sys/dev/cp
parentb15207d5c210e55bafbc6c85235ab64d12815e79 (diff)
downloadFreeBSD-src-318c4f97e694c1972b55450cafe914f39977d179.zip
FreeBSD-src-318c4f97e694c1972b55450cafe914f39977d179.tar.gz
CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than ten
years for head. However, it is continuously misused as the mpsafe argument for callout_init(9). Deprecate the flag and clean up callout_init() calls to make them more consistent. Differential Revision: https://reviews.freebsd.org/D2613 Reviewed by: jhb MFC after: 2 weeks
Diffstat (limited to 'sys/dev/cp')
-rw-r--r--sys/dev/cp/if_cp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/cp/if_cp.c b/sys/dev/cp/if_cp.c
index 3d07ef2..44791d0 100644
--- a/sys/dev/cp/if_cp.c
+++ b/sys/dev/cp/if_cp.c
@@ -445,7 +445,7 @@ static int cp_attach (device_t dev)
splx (s);
return (ENXIO);
}
- callout_init (&led_timo[unit], CALLOUT_MPSAFE);
+ callout_init (&led_timo[unit], 1);
error = bus_setup_intr (dev, bd->cp_irq,
INTR_TYPE_NET|INTR_MPSAFE,
NULL, cp_intr, bd, &bd->cp_intrhand);
@@ -474,7 +474,7 @@ static int cp_attach (device_t dev)
d->board = b;
d->chan = c;
c->sys = d;
- callout_init (&d->timeout_handle, CALLOUT_MPSAFE);
+ callout_init (&d->timeout_handle, 1);
#ifdef NETGRAPH
if (ng_make_node_common (&typestruct, &d->node) != 0) {
printf ("%s: cannot make common node\n", d->name);
@@ -2223,7 +2223,7 @@ static int cp_modevent (module_t mod, int type, void *unused)
printf ("Failed to register ng_cp\n");
#endif
++load_count;
- callout_init (&timeout_handle, CALLOUT_MPSAFE);
+ callout_init (&timeout_handle, 1);
callout_reset (&timeout_handle, hz*5, cp_timeout, 0);
break;
case MOD_UNLOAD:
OpenPOWER on IntegriCloud