Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit eb8fafdf authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman
Browse files

greybus: firmware: log the name of the firmware being requested



People are getting confused as to what the firmware file name is for
their module, so log it to make it easier to find modules with "blank"
vid/pid values and let people know what to name their firmware files.

Because we are now logging this, turn the debug message after the
firmware request into an error message if something fails.

Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
Reviewed-by: default avatarMichael Scott <michael.scott@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent ebe99d61
Loading
Loading
Loading
Loading
+11 −2
Original line number Diff line number Diff line
@@ -88,9 +88,18 @@ static int download_firmware(struct gb_firmware *firmware, u8 stage)
		 intf->ddbl1_manufacturer_id, intf->ddbl1_product_id,
		 firmware->vendor_id, firmware->product_id, stage);

	// FIXME:
	// Turn to dev_dbg later after everyone has valid bootloaders with good
	// ids, but leave this as dev_info for now to make it easier to track
	// down "empty" vid/pid modules.
	dev_info(&connection->bundle->dev, "Firmware file '%s' requested\n",
		 firmware_name);

	rc = request_firmware(&firmware->fw, firmware_name,
		&connection->bundle->dev);
	dev_dbg(&connection->bundle->dev, "Searched for TFTF %s: %d\n",
	if (rc)
		dev_err(&connection->bundle->dev,
			"Firware request for %s has failed : %d",
			firmware_name, rc);
	return rc;
}