Lines Matching refs:rtl_fw

830 	struct rtl_fw {  struct
841 } *rtl_fw; member
1861 struct rtl_fw *rtl_fw = tp->rtl_fw; in rtl8169_get_drvinfo() local
1866 BUILD_BUG_ON(sizeof(info->fw_version) < sizeof(rtl_fw->version)); in rtl8169_get_drvinfo()
1867 if (!IS_ERR_OR_NULL(rtl_fw)) in rtl8169_get_drvinfo()
1868 strlcpy(info->fw_version, rtl_fw->version, in rtl8169_get_drvinfo()
2451 static bool rtl_fw_format_ok(struct rtl8169_private *tp, struct rtl_fw *rtl_fw) in rtl_fw_format_ok() argument
2453 const struct firmware *fw = rtl_fw->fw; in rtl_fw_format_ok()
2455 struct rtl_fw_phy_action *pa = &rtl_fw->phy_action; in rtl_fw_format_ok()
2456 char *version = rtl_fw->version; in rtl_fw_format_ok()
2558 static int rtl_check_firmware(struct rtl8169_private *tp, struct rtl_fw *rtl_fw) in rtl_check_firmware() argument
2563 if (!rtl_fw_format_ok(tp, rtl_fw)) { in rtl_check_firmware()
2568 if (rtl_fw_data_ok(tp, dev, &rtl_fw->phy_action)) in rtl_check_firmware()
2574 static void rtl_phy_write_fw(struct rtl8169_private *tp, struct rtl_fw *rtl_fw) in rtl_phy_write_fw() argument
2576 struct rtl_fw_phy_action *pa = &rtl_fw->phy_action; in rtl_phy_write_fw()
2665 if (!IS_ERR_OR_NULL(tp->rtl_fw)) { in rtl_release_firmware()
2666 release_firmware(tp->rtl_fw->fw); in rtl_release_firmware()
2667 kfree(tp->rtl_fw); in rtl_release_firmware()
2669 tp->rtl_fw = RTL_FIRMWARE_UNKNOWN; in rtl_release_firmware()
2674 struct rtl_fw *rtl_fw = tp->rtl_fw; in rtl_apply_firmware() local
2677 if (!IS_ERR_OR_NULL(rtl_fw)) in rtl_apply_firmware()
2678 rtl_phy_write_fw(tp, rtl_fw); in rtl_apply_firmware()
5074 struct rtl_fw *rtl_fw; in rtl_request_uncached_firmware() local
5082 rtl_fw = kzalloc(sizeof(*rtl_fw), GFP_KERNEL); in rtl_request_uncached_firmware()
5083 if (!rtl_fw) in rtl_request_uncached_firmware()
5086 rc = request_firmware(&rtl_fw->fw, name, &tp->pci_dev->dev); in rtl_request_uncached_firmware()
5090 rc = rtl_check_firmware(tp, rtl_fw); in rtl_request_uncached_firmware()
5094 tp->rtl_fw = rtl_fw; in rtl_request_uncached_firmware()
5099 release_firmware(rtl_fw->fw); in rtl_request_uncached_firmware()
5101 kfree(rtl_fw); in rtl_request_uncached_firmware()
5106 tp->rtl_fw = NULL; in rtl_request_uncached_firmware()
5112 if (IS_ERR(tp->rtl_fw)) in rtl_request_firmware()
8312 tp->rtl_fw = RTL_FIRMWARE_UNKNOWN; in rtl_init_one()