• Home
  • Raw
  • Download

Lines Matching full:firmware

3  * ISH-TP client driver for ISH firmware loading
8 #include <linux/firmware.h>
15 /* Number of times we attempt to load the firmware before giving up */
23 * ISH Shim firmware loader reserves 4 Kb buffer in SRAM. The buffer is
25 * firmware loader. Reason for the odd size of 3968 bytes? Each IPC
34 * LOADER_CMD_XFER_QUERY Query the Shim firmware loader for
36 * LOADER_CMD_XFER_FRAGMENT Transfer one firmware image fragment at a
38 * multiple times until the entire firmware
40 * LOADER_CMD_START Start executing the main firmware.
53 * ISH firmware max delay for one transmit failure is 1 Hz,
54 * and firmware will retry 2 times, so 3 Hz is used for timeout.
62 * transfer data. This may use IPC or DMA if supported in firmware.
66 * LOADER_XFER_MODE_DIRECT_DMA - firmware loading is a bit different
71 * instead manage the DMA directly in kernel driver and Shim firmware
73 * to overcome 4 Kb limit, and optimize the data flow path in firmware.
86 * The firmware loading latency will be minimum if we can DMA the
87 * entire ISH firmware image in one go. This requires that we allocate
102 * between Host driver and ISH Shim firmware loader.
173 * struct response_info - Encapsulate firmware response related
176 * @data Copy the data received from firmware here.
180 * @size Actual size of data received from firmware.
183 * @received Set to true on receiving a valid firmware
185 * @wait_queue Wait queue for Host firmware loading where the
186 * client sends message to ISH firmware and waits
201 * @work_fw_load: Work queue for host firmware loading.
202 * @flag_retry Flag for indicating host firmware loading should
213 * Used for passing firmware response information between
223 * subsystem and retry Host firmware loading (e.g. bad message
241 * get_firmware_variant() - Gets the filename of firmware image to be
244 * @filename Returns firmware filename.
246 * Queries the firmware-name device property string.
257 rv = device_property_read_string(devc, "firmware-name", &val); in get_firmware_variant()
260 "Error: ISH firmware-name device property required\n"); in get_firmware_variant()
267 * loader_cl_send() Send message from host to firmware
269 * @out_msg Message buffer to be sent to firmware
348 "Previous firmware message not yet processed\n"); in process_recv()
353 * All firmware messages have a header. Check buffer size in process_recv()
398 /* We expect only "response" messages from firmware */ in process_recv()
418 * Copy the buffer received in firmware response for the in process_recv()
450 /* Process the data packet from firmware */ in loader_cl_event_cb()
456 * ish_query_loader_prop() - Query ISH Shim firmware loader
458 * @fw: Poiner to firmware data struct in host memory
459 * @fw_info: Loader firmware properties
461 * This function queries the ISH Shim firmware loader for capabilities.
466 const struct firmware *fw, in ish_query_loader_prop()
500 /* Loader firmware properties */ in ish_query_loader_prop()
520 "ISH firmware size %zu is greater than Shim firmware loader max supported %d\n", in ish_query_loader_prop()
530 "Shim firmware loader buffer size %d should be multiple of cacheline\n", in ish_query_loader_prop()
539 * ish_fw_xfer_ishtp() Loads ISH firmware using ishtp interface
541 * @fw: Pointer to firmware data struct in host memory
543 * This function uses ISH-TP to transfer ISH firmware from host to
544 * ISH SRAM. Lower layers may use IPC or DMA depending on firmware
550 const struct firmware *fw) in ish_fw_xfer_ishtp()
569 /* Break the firmware image into fragments and send as ISH-TP payload */ in ish_fw_xfer_ishtp()
615 * ish_fw_xfer_direct_dma() - Loads ISH firmware using direct dma
617 * @fw: Pointer to firmware data struct in host memory
618 * @fw_info: Loader firmware properties
620 * Host firmware load is a unique case where we need to download
621 * a large firmware image (200+ Kb). This function implements
622 * direct DMA transfer in kernel and ISH firmware. This allows
625 * Function depends on corresponding support in ISH firmware.
630 const struct firmware *fw, in ish_fw_xfer_direct_dma()
645 * (1) Size of firmware to be loaded, in ish_fw_xfer_direct_dma()
646 * (2) Max DMA buffer size supported by Shim firmware, in ish_fw_xfer_direct_dma()
678 /* Send the firmware image in chucks of payload_max_size */ in ish_fw_xfer_direct_dma()
736 * ish_fw_start() Start executing ISH main firmware
739 * This function sends message to Shim firmware loader to start
740 * the execution of ISH main firmware.
759 * load_fw_from_host() Loads ISH firmware from host
762 * This function loads the ISH firmware to ISH SRAM and starts execution
771 const struct firmware *fw; in load_fw_from_host()
784 /* Get filename of the ISH firmware to be loaded */ in load_fw_from_host()
793 /* Step 1: Query Shim firmware loader properties */ in load_fw_from_host()
799 /* Step 2: Send the main firmware image to be loaded, to ISH SRAM */ in load_fw_from_host()
808 "No transfer mode selected in firmware\n"); in load_fw_from_host()
814 /* Step 3: Start ISH main firmware exeuction */ in load_fw_from_host()
821 dev_info(cl_data_to_dev(client_data), "ISH firmware %s loaded\n", in load_fw_from_host()
835 "ISH host firmware load failed %d. Resetting ISH, and trying again..\n", in load_fw_from_host()
840 "ISH host firmware load failed %d\n", rv); in load_fw_from_host()
876 /* Connect to firmware client */ in loader_init()
955 /* ISH firmware loading from host */ in reset_handler()
1004 /* ISH firmware loading from host */ in loader_ishtp_cl_probe()
1083 MODULE_DESCRIPTION("ISH ISH-TP Host firmware Loader Client Driver");