Mercurial > vordog
comparison vordog.c @ 11:3968bbb5303d
disable timer before attached
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Wed, 09 Jul 2008 00:57:33 +0800 |
parents | b4f4a69ea86a |
children | 6bfd60bcd7b8 |
comparison
equal
deleted
inserted
replaced
10:b853a7227489 | 11:3968bbb5303d |
---|---|
276 | 276 |
277 static int vordog_attach(device_t dev) { | 277 static int vordog_attach(device_t dev) { |
278 vd_softc_t sc; | 278 vd_softc_t sc; |
279 struct cdev *_cdev; | 279 struct cdev *_cdev; |
280 | 280 |
281 disable_timer(); | |
282 | |
281 sc = (vd_softc_t)malloc(sizeof(struct vd_softc), M_TEMP, M_WAITOK); | 283 sc = (vd_softc_t)malloc(sizeof(struct vd_softc), M_TEMP, M_WAITOK); |
282 if(sc == NULL) | 284 if(sc == NULL) |
283 return ENOMEM; | 285 return ENOMEM; |
284 | 286 |
285 _cdev = make_dev(&vordog_cdevsw, 0, UID_ROOT, GID_WHEEL, 0600, "vordog0"); | 287 _cdev = make_dev(&vordog_cdevsw, 0, UID_ROOT, GID_WHEEL, 0600, "vordog0"); |