Deleted Added
full compact
bktr_os.c (104094) bktr_os.c (107699)
1/* $FreeBSD: head/sys/dev/bktr/bktr_os.c 104094 2002-09-28 17:15:38Z phk $ */
1/* $FreeBSD: head/sys/dev/bktr/bktr_os.c 107699 2002-12-09 09:04:09Z roger $ */
2
3/*
4 * This is part of the Driver for Video Capture Cards (Frame grabbers)
5 * and TV Tuner cards using the Brooktree Bt848, Bt848A, Bt849A, Bt878, Bt879
6 * chipset.
7 * Copyright Roger Hardiman and Amancio Hasty.
8 *
9 * bktr_os : This has all the Operating System dependant code,

--- 479 unchanged lines hidden (view full) ---

489 if (bt848_i2c_detach(dev))
490 printf("bktr%d: i2c_attach: can't attach\n", unit);
491#endif
492
493 /* Note: We do not free memory for RISC programs, grab buffer, vbi buffers */
494 /* The memory is retained by the bktr_mem module so we can unload and */
495 /* then reload the main bktr driver module */
496
2
3/*
4 * This is part of the Driver for Video Capture Cards (Frame grabbers)
5 * and TV Tuner cards using the Brooktree Bt848, Bt848A, Bt849A, Bt878, Bt879
6 * chipset.
7 * Copyright Roger Hardiman and Amancio Hasty.
8 *
9 * bktr_os : This has all the Operating System dependant code,

--- 479 unchanged lines hidden (view full) ---

489 if (bt848_i2c_detach(dev))
490 printf("bktr%d: i2c_attach: can't attach\n", unit);
491#endif
492
493 /* Note: We do not free memory for RISC programs, grab buffer, vbi buffers */
494 /* The memory is retained by the bktr_mem module so we can unload and */
495 /* then reload the main bktr driver module */
496
497 /* Unregister the /dev/bktrN, tunerN and vbiN devices */
497 /* Unregister the /dev/bktrN, tunerN and vbiN devices,
498 * the aliases for unit 0 are automatically destroyed */
498 destroy_dev(bktr->vbidev);
499 destroy_dev(bktr->tunerdev);
500 destroy_dev(bktr->bktrdev);
501
499 destroy_dev(bktr->vbidev);
500 destroy_dev(bktr->tunerdev);
501 destroy_dev(bktr->bktrdev);
502
502 /* If this is unit 0, then destroy the alias entries too */
503#if (__FreeBSD_version >=500000)
504 if (unit == 0) {
505 destroy_dev(bktr->vbidev_alias);
506 destroy_dev(bktr->tunerdev_alias);
507 destroy_dev(bktr->bktrdev_alias);
508 }
509#endif
510
511 /*
512 * Deallocate resources.
513 */
514 bus_teardown_intr(dev, bktr->res_irq, bktr->res_ih);
515 bus_release_resource(dev, SYS_RES_IRQ, bktr->irq_rid, bktr->res_irq);
516 bus_release_resource(dev, SYS_RES_MEMORY, bktr->mem_rid, bktr->res_mem);
517
518 return 0;

--- 784 unchanged lines hidden ---
503 /*
504 * Deallocate resources.
505 */
506 bus_teardown_intr(dev, bktr->res_irq, bktr->res_ih);
507 bus_release_resource(dev, SYS_RES_IRQ, bktr->irq_rid, bktr->res_irq);
508 bus_release_resource(dev, SYS_RES_MEMORY, bktr->mem_rid, bktr->res_mem);
509
510 return 0;

--- 784 unchanged lines hidden ---