|
@@ -355,15 +355,19 @@ static int fpga_region_notify_pre_apply(struct fpga_region *region,
|
|
const char *firmware_name;
|
|
const char *firmware_name;
|
|
int ret;
|
|
int ret;
|
|
|
|
|
|
- info = fpga_image_info_alloc(dev);
|
|
|
|
- if (!info)
|
|
|
|
- return -ENOMEM;
|
|
|
|
-
|
|
|
|
- /* Reject overlay if child FPGA Regions have firmware-name property */
|
|
|
|
|
|
+ /*
|
|
|
|
+ * Reject overlay if child FPGA Regions added in the overlay have
|
|
|
|
+ * firmware-name property (would mean that an FPGA region that has
|
|
|
|
+ * not been added to the live tree yet is doing FPGA programming).
|
|
|
|
+ */
|
|
ret = child_regions_with_firmware(nd->overlay);
|
|
ret = child_regions_with_firmware(nd->overlay);
|
|
if (ret)
|
|
if (ret)
|
|
return ret;
|
|
return ret;
|
|
|
|
|
|
|
|
+ info = fpga_image_info_alloc(dev);
|
|
|
|
+ if (!info)
|
|
|
|
+ return -ENOMEM;
|
|
|
|
+
|
|
/* Read FPGA region properties from the overlay */
|
|
/* Read FPGA region properties from the overlay */
|
|
if (of_property_read_bool(nd->overlay, "partial-fpga-config"))
|
|
if (of_property_read_bool(nd->overlay, "partial-fpga-config"))
|
|
info->flags |= FPGA_MGR_PARTIAL_RECONFIG;
|
|
info->flags |= FPGA_MGR_PARTIAL_RECONFIG;
|