From 5cd424736069e45a7f3c697f87264d33de82765d Mon Sep 17 00:00:00 2001 From: James Smart Date: Thu, 6 Jul 2006 15:50:29 -0400 Subject: [PATCH] --- yaml --- r: 32734 b: refs/heads/master c: 5e0b43385559bfe78c1f80d71ec203effe244d9a h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/scsi/lpfc/lpfc_attr.c | 42 ----------------------------- 2 files changed, 1 insertion(+), 43 deletions(-) diff --git a/[refs] b/[refs] index eb64ca7bae74..397f63ba860d 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 40496f073ffe75c59414a7236f95ecbc49562596 +refs/heads/master: 5e0b43385559bfe78c1f80d71ec203effe244d9a diff --git a/trunk/drivers/scsi/lpfc/lpfc_attr.c b/trunk/drivers/scsi/lpfc/lpfc_attr.c index cdae011b2813..48379c606124 100644 --- a/trunk/drivers/scsi/lpfc/lpfc_attr.c +++ b/trunk/drivers/scsi/lpfc/lpfc_attr.c @@ -292,45 +292,6 @@ lpfc_nport_evt_cnt_show(struct class_device *cdev, char *buf) return snprintf(buf, PAGE_SIZE, "%d\n", phba->nport_event_cnt); } -static ssize_t -lpfc_board_online_show(struct class_device *cdev, char *buf) -{ - struct Scsi_Host *host = class_to_shost(cdev); - struct lpfc_hba *phba = (struct lpfc_hba*)host->hostdata; - - if (phba->fc_flag & FC_OFFLINE_MODE) - return snprintf(buf, PAGE_SIZE, "0\n"); - else - return snprintf(buf, PAGE_SIZE, "1\n"); -} - -static ssize_t -lpfc_board_online_store(struct class_device *cdev, const char *buf, - size_t count) -{ - struct Scsi_Host *host = class_to_shost(cdev); - struct lpfc_hba *phba = (struct lpfc_hba*)host->hostdata; - struct completion online_compl; - int val=0, status=0; - - if (sscanf(buf, "%d", &val) != 1) - return -EINVAL; - - init_completion(&online_compl); - - if (val) - lpfc_workq_post_event(phba, &status, &online_compl, - LPFC_EVT_ONLINE); - else - lpfc_workq_post_event(phba, &status, &online_compl, - LPFC_EVT_OFFLINE); - wait_for_completion(&online_compl); - if (!status) - return strlen(buf); - else - return -EIO; -} - static ssize_t lpfc_board_mode_show(struct class_device *cdev, char *buf) { @@ -583,8 +544,6 @@ static CLASS_DEVICE_ATTR(lpfc_drvr_version, S_IRUGO, lpfc_drvr_version_show, NULL); static CLASS_DEVICE_ATTR(management_version, S_IRUGO, management_version_show, NULL); -static CLASS_DEVICE_ATTR(board_online, S_IRUGO | S_IWUSR, - lpfc_board_online_show, lpfc_board_online_store); static CLASS_DEVICE_ATTR(board_mode, S_IRUGO | S_IWUSR, lpfc_board_mode_show, lpfc_board_mode_store); static CLASS_DEVICE_ATTR(issue_reset, S_IWUSR, NULL, lpfc_issue_reset); @@ -791,7 +750,6 @@ struct class_device_attribute *lpfc_host_attrs[] = { &class_device_attr_lpfc_max_luns, &class_device_attr_nport_evt_cnt, &class_device_attr_management_version, - &class_device_attr_board_online, &class_device_attr_board_mode, &class_device_attr_issue_reset, &class_device_attr_lpfc_poll,