IB/hfi1: Remove reading platform configuration from EFI variable
authorJan Sokolowski <jan.sokolowski@intel.com>
Fri, 9 Jun 2017 22:59:46 +0000 (15:59 -0700)
committerDoug Ledford <dledford@redhat.com>
Tue, 27 Jun 2017 20:58:13 +0000 (16:58 -0400)
Currently, platform configuration can be read from EFI variable
for discrete cards. It will happen when reading from EPROM fails.
EFI variables should not be queried for platform configuration
in any scenario.

Reviewed-by: Jakub Byczkowski <jakub.byczkowski@intel.com>
Signed-off-by: Jan Sokolowski <jan.sokolowski@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/hfi1/platform.c

index cbda9b189216e2dc2d8cdf542f15bb45e04fcc02..41307e4745257264655d29a06e9991807f18334d 100644 (file)
@@ -136,7 +136,6 @@ static void save_platform_config_fields(struct hfi1_devdata *dd)
 void get_platform_config(struct hfi1_devdata *dd)
 {
        int ret = 0;
-       unsigned long size = 0;
        u8 *temp_platform_config = NULL;
        u32 esize;
 
@@ -160,15 +159,6 @@ void get_platform_config(struct hfi1_devdata *dd)
                        dd->platform_config.size = esize;
                        return;
                }
-               /* fail, try EFI variable */
-
-               ret = read_hfi1_efi_var(dd, "configuration", &size,
-                                       (void **)&temp_platform_config);
-               if (!ret) {
-                       dd->platform_config.data = temp_platform_config;
-                       dd->platform_config.size = size;
-                       return;
-               }
        }
        dd_dev_err(dd,
                   "%s: Failed to get platform config, falling back to sub-optimal default file\n",