linux/sound/usb/6fire/firmware.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 * Linux driver for TerraTec DMX 6Fire USB
 *
 * Firmware loader
 *
 * Author:	Torsten Schenk <[email protected]>
 * Created:	Jan 01, 2011
 * Copyright:	(C) Torsten Schenk
 */

#include <linux/firmware.h>
#include <linux/module.h>
#include <linux/bitrev.h>
#include <linux/kernel.h>

#include "firmware.h"
#include "chip.h"

MODULE_FIRMWARE();
MODULE_FIRMWARE();
MODULE_FIRMWARE();

enum {};

/*
 * wMaxPacketSize of pcm endpoints.
 * keep synced with rates_in_packet_size and rates_out_packet_size in pcm.c
 * fpp: frames per isopacket
 *
 * CAUTION: keep sizeof <= buffer[] in usb6fire_fw_init
 */
static const u8 ep_w_max_packet_size[] =;

static const u8 known_fw_versions[][2] =;

struct ihex_record {};

static u8 usb6fire_fw_ihex_hex(const u8 *data, u8 *crc)
{}

/*
 * returns true if record is available, false otherwise.
 * iff an error occurred, false will be returned and record->error will be true.
 */
static bool usb6fire_fw_ihex_next_record(struct ihex_record *record)
{}

static int usb6fire_fw_ihex_init(const struct firmware *fw,
		struct ihex_record *record)
{}

static int usb6fire_fw_ezusb_write(struct usb_device *device,
		int type, int value, char *data, int len)
{}

static int usb6fire_fw_ezusb_read(struct usb_device *device,
		int type, int value, char *data, int len)
{}

static int usb6fire_fw_fpga_write(struct usb_device *device,
		char *data, int len)
{}

static int usb6fire_fw_ezusb_upload(
		struct usb_interface *intf, const char *fwname,
		unsigned int postaddr, u8 *postdata, unsigned int postlen)
{}

static int usb6fire_fw_fpga_upload(
		struct usb_interface *intf, const char *fwname)
{}

/* check, if the firmware version the devices has currently loaded
 * is known by this driver. 'version' needs to have 4 bytes version
 * info data. */
static int usb6fire_fw_check(struct usb_interface *intf, const u8 *version)
{}

int usb6fire_fw_init(struct usb_interface *intf)
{}