#define HPSA_RAID_ADM  6       /* also used for RAID 1+0 ADM */
 #define RAID_UNKNOWN (ARRAY_SIZE(raid_label) - 1)
 
+static inline bool is_logical_device(struct hpsa_scsi_dev_t *device)
+{
+       return !device->physical_device;
+}
+
 static ssize_t raid_level_show(struct device *dev,
             struct device_attribute *attr, char *buf)
 {
        }
 
        /* Is this even a logical drive? */
-       if (!is_logical_dev_addr_mode(hdev->scsi3addr)) {
+       if (!is_logical_device(hdev)) {
                spin_unlock_irqrestore(&h->lock, flags);
                l = snprintf(buf, PAGE_SIZE, "N/A\n");
                return l;
                                scsi_device_type(hdev->devtype));
 
                if (is_ext_target(h, hdev) ||
-                       (hdev->devtype == TYPE_RAID) ||
-                       is_logical_dev_addr_mode(hdev->scsi3addr)) {
+                       hdev->devtype == TYPE_RAID ||
+                       is_logical_device(hdev)) {
                        output_len += snprintf(path[i] + output_len,
                                                PATH_STRING_LEN, "%s\n",
                                                active);
                                continue;
                        if (dev[j]->devtype != TYPE_DISK)
                                continue;
-                       if (is_logical_dev_addr_mode(dev[j]->scsi3addr))
+                       if (is_logical_device(dev[j]))
                                continue;
                        if (dev[j]->ioaccel_handle != dd[i].ioaccel_handle)
                                continue;
                        continue;
                if (dev[i]->devtype != TYPE_DISK)
                        continue;
-               if (!is_logical_dev_addr_mode(dev[i]->scsi3addr))
+               if (!is_logical_device(dev[i]))
                        continue;
 
                /*
         * the normal I/O path so the controller can handle whatever's
         * wrong.
         */
-       if (is_logical_dev_addr_mode(dev->scsi3addr) &&
+       if (is_logical_device(dev) &&
                c2->error_data.serv_response ==
                        IOACCEL2_SERV_RESPONSE_FAILURE) {
                if (c2->error_data.status ==
                 * the normal I/O path so the controller can handle whatever's
                 * wrong.
                 */
-               if (is_logical_dev_addr_mode(dev->scsi3addr)) {
+               if (is_logical_device(dev)) {
                        if (ei->CommandStatus == CMD_IOACCEL_DISABLED)
                                dev->offload_enabled = 0;
                        return hpsa_retry_cmd(h, cp);