summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authormav <mav@FreeBSD.org>2015-10-11 13:01:51 +0000
committermav <mav@FreeBSD.org>2015-10-11 13:01:51 +0000
commit64d53c4c7d2401ff7f259304054800f496e26941 (patch)
treeae68a3ddda28f0bc480012dc566360581eeafc38 /sys
parent1fd9c17d055b56ee0020a5f8cd93b732498cf04b (diff)
downloadFreeBSD-src-64d53c4c7d2401ff7f259304054800f496e26941.zip
FreeBSD-src-64d53c4c7d2401ff7f259304054800f496e26941.tar.gz
Remove compatibility shims for legacy ATA device names.
We got new ATA stack in FreeBSD 8.x, switched to it at 9.x, completely removed old stack at 10.x, so at 11.x it is time to remove compat shims.
Diffstat (limited to 'sys')
-rw-r--r--sys/amd64/conf/GENERIC1
-rw-r--r--sys/arm/conf/A201
-rw-r--r--sys/arm/conf/ALPINE1
-rw-r--r--sys/arm/conf/CRB1
-rw-r--r--sys/arm/conf/CUBIEBOARD1
-rw-r--r--sys/arm/conf/EFIKA_MX1
-rw-r--r--sys/arm/conf/EP802191
-rw-r--r--sys/arm/conf/IMX531
-rw-r--r--sys/arm/conf/IQ312441
-rw-r--r--sys/cam/ata/ata_da.c26
-rw-r--r--sys/cam/cam_xpt.c39
-rw-r--r--sys/cam/cam_xpt.h1
-rw-r--r--sys/conf/NOTES3
-rw-r--r--sys/geom/geom_dev.c30
-rw-r--r--sys/geom/raid/g_raid.c20
-rw-r--r--sys/i386/conf/GENERIC1
-rw-r--r--sys/i386/conf/XBOX1
-rw-r--r--sys/mips/conf/OCTEON11
-rw-r--r--sys/mips/conf/std.SWARM1
-rw-r--r--sys/pc98/conf/GENERIC1
20 files changed, 5 insertions, 128 deletions
diff --git a/sys/amd64/conf/GENERIC b/sys/amd64/conf/GENERIC
index 5c7f7c0..ec943f9 100644
--- a/sys/amd64/conf/GENERIC
+++ b/sys/amd64/conf/GENERIC
@@ -109,7 +109,6 @@ device fdc
# ATA controllers
device ahci # AHCI-compatible SATA controllers
device ata # Legacy ATA/SATA controllers
-options ATA_STATIC_ID # Static device numbering
device mvs # Marvell 88SX50XX/88SX60XX/88SX70XX/SoC SATA
device siis # SiliconImage SiI3124/SiI3132/SiI3531 SATA
diff --git a/sys/arm/conf/A20 b/sys/arm/conf/A20
index 3bac455..21ecd85 100644
--- a/sys/arm/conf/A20
+++ b/sys/arm/conf/A20
@@ -62,7 +62,6 @@ device mmcsd # mmc/sd flash cards
# ATA controllers
device ahci # AHCI-compatible SATA controllers
#device ata # Legacy ATA/SATA controllers
-#options ATA_STATIC_ID # Static device numbering
# Console and misc
device uart
diff --git a/sys/arm/conf/ALPINE b/sys/arm/conf/ALPINE
index 075cc1f..bf1c42d 100644
--- a/sys/arm/conf/ALPINE
+++ b/sys/arm/conf/ALPINE
@@ -48,7 +48,6 @@ device gpio
# ATA controllers
device ahci # AHCI-compatible SATA controllers
device ata # Legacy ATA/SATA controllers
-options ATA_STATIC_ID # Static device numbering
# ATA/SCSI peripherals
device scbus # SCSI bus (required for ATA/SCSI)
diff --git a/sys/arm/conf/CRB b/sys/arm/conf/CRB
index 69b0ebd..af500ca 100644
--- a/sys/arm/conf/CRB
+++ b/sys/arm/conf/CRB
@@ -76,7 +76,6 @@ device uart
device pci
device ata
-options ATA_STATIC_ID # Static device numbering
device scbus # SCSI bus (required for ATA/SCSI)
device cd # CD
diff --git a/sys/arm/conf/CUBIEBOARD b/sys/arm/conf/CUBIEBOARD
index 2de16f7..8102306 100644
--- a/sys/arm/conf/CUBIEBOARD
+++ b/sys/arm/conf/CUBIEBOARD
@@ -59,7 +59,6 @@ device mmcsd # mmc/sd flash cards
# ATA controllers
device ahci # AHCI-compatible SATA controllers
#device ata # Legacy ATA/SATA controllers
-#options ATA_STATIC_ID # Static device numbering
# Console and misc
device uart
diff --git a/sys/arm/conf/EFIKA_MX b/sys/arm/conf/EFIKA_MX
index 2c4d973..7f978b2 100644
--- a/sys/arm/conf/EFIKA_MX
+++ b/sys/arm/conf/EFIKA_MX
@@ -91,7 +91,6 @@ options ALT_BREAK_TO_DEBUGGER
device ata
device atapci # Only for helper functions
device imxata
-options ATA_STATIC_ID # Static device numbering
device gpio
device gpioled
diff --git a/sys/arm/conf/EP80219 b/sys/arm/conf/EP80219
index 301849c..a744283 100644
--- a/sys/arm/conf/EP80219
+++ b/sys/arm/conf/EP80219
@@ -76,7 +76,6 @@ device uart
device pci
device ata
-options ATA_STATIC_ID # Static device numbering
device scbus # SCSI bus (required for ATA/SCSI)
device cd # CD
diff --git a/sys/arm/conf/IMX53 b/sys/arm/conf/IMX53
index d07d6ad..7fe97a2 100644
--- a/sys/arm/conf/IMX53
+++ b/sys/arm/conf/IMX53
@@ -80,7 +80,6 @@ options ALT_BREAK_TO_DEBUGGER
device ata
device atapci # Only for helper functions
device imxata
-options ATA_STATIC_ID # Static device numbering
device gpio
device gpioled
diff --git a/sys/arm/conf/IQ31244 b/sys/arm/conf/IQ31244
index ae8eae8..0bb224d 100644
--- a/sys/arm/conf/IQ31244
+++ b/sys/arm/conf/IQ31244
@@ -75,7 +75,6 @@ device uart
device pci
device ata
-options ATA_STATIC_ID # Static device numbering
device scbus # SCSI bus (required for ATA/SCSI)
device cd # CD
diff --git a/sys/cam/ata/ata_da.c b/sys/cam/ata/ata_da.c
index 049a2fd..e9c63f2 100644
--- a/sys/cam/ata/ata_da.c
+++ b/sys/cam/ata/ata_da.c
@@ -582,7 +582,6 @@ static void adaresume(void *arg);
#define ata_disk_firmware_geom_adjust(disk)
#endif
-static int ada_legacy_aliases = ADA_DEFAULT_LEGACY_ALIASES;
static int ada_retry_count = ADA_DEFAULT_RETRY;
static int ada_default_timeout = ADA_DEFAULT_TIMEOUT;
static int ada_send_ordered = ADA_DEFAULT_SEND_ORDERED;
@@ -593,8 +592,6 @@ static int ada_write_cache = ADA_DEFAULT_WRITE_CACHE;
static SYSCTL_NODE(_kern_cam, OID_AUTO, ada, CTLFLAG_RD, 0,
"CAM Direct Access Disk driver");
-SYSCTL_INT(_kern_cam_ada, OID_AUTO, legacy_aliases, CTLFLAG_RWTUN,
- &ada_legacy_aliases, 0, "Create legacy-like device aliases");
SYSCTL_INT(_kern_cam_ada, OID_AUTO, retry_count, CTLFLAG_RWTUN,
&ada_retry_count, 0, "Normal I/O retry count");
SYSCTL_INT(_kern_cam_ada, OID_AUTO, default_timeout, CTLFLAG_RWTUN,
@@ -1164,11 +1161,11 @@ adaregister(struct cam_periph *periph, void *arg)
struct ada_softc *softc;
struct ccb_pathinq cpi;
struct ccb_getdev *cgd;
- char announce_buf[80], buf1[32];
+ char announce_buf[80];
struct disk_params *dp;
caddr_t match;
u_int maxio;
- int legacy_id, quirks;
+ int quirks;
cgd = (struct ccb_getdev *)arg;
if (cgd == NULL) {
@@ -1331,22 +1328,6 @@ adaregister(struct cam_periph *periph, void *arg)
softc->disk->d_fwheads = softc->params.heads;
ata_disk_firmware_geom_adjust(softc->disk);
- if (ada_legacy_aliases) {
-#ifdef ATA_STATIC_ID
- legacy_id = xpt_path_legacy_ata_id(periph->path);
-#else
- legacy_id = softc->disk->d_unit;
-#endif
- if (legacy_id >= 0) {
- snprintf(announce_buf, sizeof(announce_buf),
- "kern.devalias.%s%d",
- softc->disk->d_name, softc->disk->d_unit);
- snprintf(buf1, sizeof(buf1),
- "ad%d", legacy_id);
- kern_setenv(announce_buf, buf1);
- }
- } else
- legacy_id = -1;
/*
* Acquire a reference to the periph before we register with GEOM.
* We'll release this reference once GEOM calls us back (via
@@ -1372,9 +1353,6 @@ adaregister(struct cam_periph *periph, void *arg)
dp->secs_per_track, dp->cylinders);
xpt_announce_periph(periph, announce_buf);
xpt_announce_quirks(periph, softc->quirks, ADA_Q_BIT_STRING);
- if (legacy_id >= 0)
- printf("%s%d: Previously was known as ad%d\n",
- periph->periph_name, periph->unit_number, legacy_id);
/*
* Create our sysctl variables, now that we know
diff --git a/sys/cam/cam_xpt.c b/sys/cam/cam_xpt.c
index 4ce48a3..fb5d041 100644
--- a/sys/cam/cam_xpt.c
+++ b/sys/cam/cam_xpt.c
@@ -3756,45 +3756,6 @@ xpt_path_periph(struct cam_path *path)
return (path->periph);
}
-int
-xpt_path_legacy_ata_id(struct cam_path *path)
-{
- struct cam_eb *bus;
- int bus_id;
-
- if ((strcmp(path->bus->sim->sim_name, "ata") != 0) &&
- strcmp(path->bus->sim->sim_name, "ahcich") != 0 &&
- strcmp(path->bus->sim->sim_name, "mvsch") != 0 &&
- strcmp(path->bus->sim->sim_name, "siisch") != 0)
- return (-1);
-
- if (strcmp(path->bus->sim->sim_name, "ata") == 0 &&
- path->bus->sim->unit_number < 2) {
- bus_id = path->bus->sim->unit_number;
- } else {
- bus_id = 2;
- xpt_lock_buses();
- TAILQ_FOREACH(bus, &xsoftc.xpt_busses, links) {
- if (bus == path->bus)
- break;
- if ((strcmp(bus->sim->sim_name, "ata") == 0 &&
- bus->sim->unit_number >= 2) ||
- strcmp(bus->sim->sim_name, "ahcich") == 0 ||
- strcmp(bus->sim->sim_name, "mvsch") == 0 ||
- strcmp(bus->sim->sim_name, "siisch") == 0)
- bus_id++;
- }
- xpt_unlock_buses();
- }
- if (path->target != NULL) {
- if (path->target->target_id < 2)
- return (bus_id * 2 + path->target->target_id);
- else
- return (-1);
- } else
- return (bus_id * 2);
-}
-
/*
* Release a CAM control block for the caller. Remit the cost of the structure
* to the device referenced by the path. If the this device had no 'credits'
diff --git a/sys/cam/cam_xpt.h b/sys/cam/cam_xpt.h
index 1d983c9..d92981c 100644
--- a/sys/cam/cam_xpt.h
+++ b/sys/cam/cam_xpt.h
@@ -101,7 +101,6 @@ int xpt_path_string(struct cam_path *path, char *str,
path_id_t xpt_path_path_id(struct cam_path *path);
target_id_t xpt_path_target_id(struct cam_path *path);
lun_id_t xpt_path_lun_id(struct cam_path *path);
-int xpt_path_legacy_ata_id(struct cam_path *path);
struct cam_sim *xpt_path_sim(struct cam_path *path);
struct cam_periph *xpt_path_periph(struct cam_path *path);
void xpt_async(u_int32_t async_code, struct cam_path *path,
diff --git a/sys/conf/NOTES b/sys/conf/NOTES
index 05ffe55..c6478f9 100644
--- a/sys/conf/NOTES
+++ b/sys/conf/NOTES
@@ -1759,12 +1759,9 @@ hint.ata.1.irq="15"
#
# The following options are valid on the ATA driver:
#
-# ATA_STATIC_ID: controller numbering is static ie depends on location
-# else the device numbers are dynamically allocated.
# ATA_REQUEST_TIMEOUT: the number of seconds to wait for an ATA request
# before timing out.
-options ATA_STATIC_ID
#options ATA_REQUEST_TIMEOUT=10
#
diff --git a/sys/geom/geom_dev.c b/sys/geom/geom_dev.c
index 789de4d..6aecd78 100644
--- a/sys/geom/geom_dev.c
+++ b/sys/geom/geom_dev.c
@@ -280,9 +280,9 @@ g_dev_taste(struct g_class *mp, struct g_provider *pp, int insist __unused)
struct g_geom *gp;
struct g_consumer *cp;
struct g_dev_softc *sc;
- int error, len;
- struct cdev *dev, *adev;
- char buf[SPECNAMELEN + 6], *val;
+ int error;
+ struct cdev *dev;
+ char buf[SPECNAMELEN + 6];
g_trace(G_T_TOPOLOGY, "dev_taste(%s,%s)", mp->name, pp->name);
g_topology_assert();
@@ -310,33 +310,9 @@ g_dev_taste(struct g_class *mp, struct g_provider *pp, int insist __unused)
dev->si_flags |= SI_UNMAPPED;
sc->sc_dev = dev;
- /* Search for device alias name and create it if found. */
- adev = NULL;
- for (len = MIN(strlen(gp->name), sizeof(buf) - 15); len > 0; len--) {
- snprintf(buf, sizeof(buf), "kern.devalias.%s", gp->name);
- buf[14 + len] = 0;
- val = kern_getenv(buf);
- if (val != NULL) {
- snprintf(buf, sizeof(buf), "%s%s",
- val, gp->name + len);
- freeenv(val);
- if ((make_dev_alias_p(MAKEDEV_CHECKNAME|MAKEDEV_WAITOK,
- &adev, dev, "%s", buf)) != 0)
- printf("Warning: unable to create device "
- "alias %s\n", buf);
- break;
- }
- }
-
dev->si_iosize_max = MAXPHYS;
dev->si_drv2 = cp;
init_dumpdev(dev);
- if (adev != NULL) {
- adev->si_iosize_max = MAXPHYS;
- adev->si_drv2 = cp;
- adev->si_flags |= SI_UNMAPPED;
- init_dumpdev(adev);
- }
g_dev_attrchanged(cp, "GEOM::physpath");
snprintf(buf, sizeof(buf), "cdev=%s", gp->name);
diff --git a/sys/geom/raid/g_raid.c b/sys/geom/raid/g_raid.c
index 4156674..839a2d4 100644
--- a/sys/geom/raid/g_raid.c
+++ b/sys/geom/raid/g_raid.c
@@ -82,10 +82,6 @@ static u_int g_raid_idle_threshold = 1000000;
SYSCTL_UINT(_kern_geom_raid, OID_AUTO, idle_threshold, CTLFLAG_RWTUN,
&g_raid_idle_threshold, 1000000,
"Time in microseconds to consider a volume idle.");
-static u_int ar_legacy_aliases = 1;
-SYSCTL_INT(_kern_geom_raid, OID_AUTO, legacy_aliases, CTLFLAG_RWTUN,
- &ar_legacy_aliases, 0, "Create aliases named as the legacy ataraid style.");
-
#define MSLEEP(rv, ident, mtx, priority, wmesg, timeout) do { \
G_RAID_DEBUG(4, "%s: Sleeping %p.", __func__, (ident)); \
@@ -1628,7 +1624,6 @@ g_raid_launch_provider(struct g_raid_volume *vol)
struct g_raid_softc *sc;
struct g_provider *pp;
char name[G_RAID_MAX_VOLUMENAME];
- char announce_buf[80], buf1[32];
off_t off;
int i;
@@ -1644,21 +1639,6 @@ g_raid_launch_provider(struct g_raid_volume *vol)
snprintf(name, sizeof(name), "raid/r%d", vol->v_global_id);
}
- /*
- * Create a /dev/ar%d that the old ataraid(4) stack once
- * created as an alias for /dev/raid/r%d if requested.
- * This helps going from stable/7 ataraid devices to newer
- * FreeBSD releases. sbruno 07 MAY 2013
- */
-
- if (ar_legacy_aliases) {
- snprintf(announce_buf, sizeof(announce_buf),
- "kern.devalias.%s", name);
- snprintf(buf1, sizeof(buf1),
- "ar%d", vol->v_global_id);
- kern_setenv(announce_buf, buf1);
- }
-
pp = g_new_providerf(sc->sc_geom, "%s", name);
pp->flags |= G_PF_DIRECT_RECEIVE;
if (vol->v_tr->tro_class->trc_accept_unmapped) {
diff --git a/sys/i386/conf/GENERIC b/sys/i386/conf/GENERIC
index dc11f73..ca57521 100644
--- a/sys/i386/conf/GENERIC
+++ b/sys/i386/conf/GENERIC
@@ -109,7 +109,6 @@ device fdc
# ATA controllers
device ahci # AHCI-compatible SATA controllers
device ata # Legacy ATA/SATA controllers
-options ATA_STATIC_ID # Static device numbering
device mvs # Marvell 88SX50XX/88SX60XX/88SX70XX/SoC SATA
device siis # SiliconImage SiI3124/SiI3132/SiI3531 SATA
diff --git a/sys/i386/conf/XBOX b/sys/i386/conf/XBOX
index 5a8ded0..b3817a8 100644
--- a/sys/i386/conf/XBOX
+++ b/sys/i386/conf/XBOX
@@ -51,7 +51,6 @@ device pci
# ATA and ATAPI devices
device ata
-options ATA_STATIC_ID # Static device numbering
# ATA/SCSI peripherals
device scbus # SCSI bus (required for ATA/SCSI)
diff --git a/sys/mips/conf/OCTEON1 b/sys/mips/conf/OCTEON1
index d6679fd..7c24f1a 100644
--- a/sys/mips/conf/OCTEON1
+++ b/sys/mips/conf/OCTEON1
@@ -108,7 +108,6 @@ device pci
# ATA controllers
device ahci # AHCI-compatible SATA controllers
device ata # Legacy ATA/SATA controllers
-options ATA_STATIC_ID # Static device numbering
device mvs # Marvell 88SX50XX/88SX60XX/88SX70XX/SoC SATA
device siis # SiliconImage SiI3124/SiI3132/SiI3531 SATA
diff --git a/sys/mips/conf/std.SWARM b/sys/mips/conf/std.SWARM
index c737905..3e95206 100644
--- a/sys/mips/conf/std.SWARM
+++ b/sys/mips/conf/std.SWARM
@@ -57,4 +57,3 @@ device da
device pass
device ata
-options ATA_STATIC_ID # Static device numbering
diff --git a/sys/pc98/conf/GENERIC b/sys/pc98/conf/GENERIC
index e7876ba..5adcf32 100644
--- a/sys/pc98/conf/GENERIC
+++ b/sys/pc98/conf/GENERIC
@@ -93,7 +93,6 @@ device fdc
# ATA controllers
device ahci # AHCI-compatible SATA controllers
device ata # Legacy ATA/SATA controllers
-options ATA_STATIC_ID # Static device numbering
device mvs # Marvell 88SX50XX/88SX60XX/88SX70XX/SoC SATA
device siis # SiliconImage SiI3124/SiI3132/SiI3531 SATA
OpenPOWER on IntegriCloud