From patchwork Mon Jul 13 14:27:33 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: jordan hargrave X-Patchwork-Id: 6779681 Return-Path: X-Original-To: patchwork-linux-scsi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D56DCC05AC for ; Mon, 13 Jul 2015 14:29:10 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 049E220489 for ; Mon, 13 Jul 2015 14:29:10 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1DA8820396 for ; Mon, 13 Jul 2015 14:29:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752308AbbGMO2x (ORCPT ); Mon, 13 Jul 2015 10:28:53 -0400 Received: from mail-ig0-f179.google.com ([209.85.213.179]:36901 "EHLO mail-ig0-f179.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751292AbbGMO1q (ORCPT ); Mon, 13 Jul 2015 10:27:46 -0400 Received: by igbpg9 with SMTP id pg9so4002500igb.0; Mon, 13 Jul 2015 07:27:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id; bh=sh4a1f0ROsNmO/r7xNZEw8Ue2Hv7qHQ55phRW8ejgZM=; b=fa2mkMi6Hc+ZFhtqn7ByzdSNn0/3FV1qPuj/SUAzsSxITja+h6zhGuHCiA3949h8pI d0evOgj+ParmHxL6ItA8kpksFsYi/fC0gF3tC/+y1TNxg6vgXe+Dnz2H93yhFjuRLlsP WM+RHkH7xIopIOIL5OY5MQ/shnUaGQZz5PCJJNWjYjba5HfluJGT7fdv+B4RBt9DhpB8 +WQzwaMax6f7yPQQ+PZjrasEgz+SvbYy0b7RnHdddUdhc2wKDWscFswT3Y8l1wxTU6Bq Eb7ULzT2ff3ZeqPcTW9x9xUxgONZ3RZt+kCtcAcwEbVdwt/puNSeUp6jugiH10COCbVA wW/Q== X-Received: by 10.107.149.14 with SMTP id x14mr42846672iod.87.1436797666228; Mon, 13 Jul 2015 07:27:46 -0700 (PDT) Received: from localhost.localdomain ([24.27.227.0]) by smtp.gmail.com with ESMTPSA id 76sm12649793iom.12.2015.07.13.07.27.43 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 13 Jul 2015 07:27:44 -0700 (PDT) From: Jordan Hargrave X-Google-Original-From: Jordan Hargrave To: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, jbottomley@odin.com, jordan_hargrave@dell.com Subject: [PATCH] Remove check for SAS expander when querying bay/enclosure IDs. Date: Mon, 13 Jul 2015 09:27:33 -0500 Message-Id: <1436797653-9822-1-git-send-email-jordan_hargrave@dell.com> X-Mailer: git-send-email 1.9.1 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Spam-Status: No, score=-8.2 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Dell Server backplanes can report bay/enclosure IDs without an expander present. This patch allows the bay/enclosure IDs to be propagaged to sysfs.we Signed-off-by: Jordan Hargrave Reviewed-by: Hannes Reinecke --- drivers/scsi/scsi_transport_sas.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/drivers/scsi/scsi_transport_sas.c b/drivers/scsi/scsi_transport_sas.c index 9a05819..30d26e3 100644 --- a/drivers/scsi/scsi_transport_sas.c +++ b/drivers/scsi/scsi_transport_sas.c @@ -1222,13 +1222,6 @@ show_sas_rphy_enclosure_identifier(struct device *dev, u64 identifier; int error; - /* - * Only devices behind an expander are supported, because the - * enclosure identifier is a SMP feature. - */ - if (scsi_is_sas_phy_local(phy)) - return -EINVAL; - error = i->f->get_enclosure_identifier(rphy, &identifier); if (error) return error; @@ -1248,9 +1241,6 @@ show_sas_rphy_bay_identifier(struct device *dev, struct sas_internal *i = to_sas_internal(shost->transportt); int val; - if (scsi_is_sas_phy_local(phy)) - return -EINVAL; - val = i->f->get_bay_identifier(rphy); if (val < 0) return val;