From 7837155fa2dcbedae410e898503889ea6d7d651c Mon Sep 17 00:00:00 2001 From: Poul-Henning Kamp Date: Fri, 5 Sep 2003 10:40:16 +0000 Subject: Put the device cloning functions for disk-drivers under #ifndef BURN_BRIDGES. For the floppy driver, use fdcontrol to manipulate density selection. For the CD drivers, the 'a' and 'c' suffix is without actual effect and any applications insisting on it can be satisfied with a symlink: ln -s /dev/cd0 /dev/cd0a Ongoing discussion may result in these pieces of code being removed before the 5-stable branch as opposed to after. --- sys/dev/ata/atapi-cd.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'sys/dev/ata/atapi-cd.c') diff --git a/sys/dev/ata/atapi-cd.c b/sys/dev/ata/atapi-cd.c index 2008515d8b34..a8a8b8737294 100644 --- a/sys/dev/ata/atapi-cd.c +++ b/sys/dev/ata/atapi-cd.c @@ -242,7 +242,9 @@ acd_detach(struct ata_device *atadev) free(entry, M_ACD); } destroy_dev(cdp->dev); +#ifndef BURN_BRIDGES EVENTHANDLER_DEREGISTER(dev_clone, cdp->clone_evh); +#endif devstat_remove_entry(cdp->stats); ata_prtdev(atadev, "WARNING - removed from configuration\n"); ata_free_name(atadev); @@ -273,6 +275,7 @@ acd_init_lun(struct ata_device *atadev) return cdp; } +#ifndef BURN_BRIDGES static void acd_clone(void *arg, char *name, int namelen, dev_t *dev) { @@ -289,6 +292,7 @@ acd_clone(void *arg, char *name, int namelen, dev_t *dev) if (unit == cdp->lun) *dev = makedev(acd_cdevsw.d_maj, cdp->lun); } +#endif static void acd_make_dev(struct acd_softc *cdp) @@ -300,7 +304,9 @@ acd_make_dev(struct acd_softc *cdp) dev->si_drv1 = cdp; cdp->dev = dev; cdp->device->flags |= ATA_D_MEDIA_CHANGED; +#ifndef BURN_BRIDGES cdp->clone_evh = EVENTHANDLER_REGISTER(dev_clone, acd_clone, cdp, 1000); +#endif acd_set_ioparm(cdp); } -- cgit v1.3