linux/drivers/net/ethernet/pensando/ionic/ionic_fw.c

// SPDX-License-Identifier: GPL-2.0
/* Copyright(c) 2020 Pensando Systems, Inc */

#include <linux/kernel.h>
#include <linux/types.h>
#include <linux/errno.h>
#include <linux/firmware.h>

#include "ionic.h"
#include "ionic_dev.h"
#include "ionic_lif.h"
#include "ionic_devlink.h"

/* The worst case wait for the install activity is about 25 minutes when
 * installing a new CPLD, which is very seldom.  Normal is about 30-35
 * seconds.  Since the driver can't tell if a CPLD update will happen we
 * set the timeout for the ugly case.
 */
#define IONIC_FW_INSTALL_TIMEOUT
#define IONIC_FW_SELECT_TIMEOUT

/* Number of periodic log updates during fw file download */
#define IONIC_FW_INTERVAL_FRACTION

static void ionic_dev_cmd_firmware_download(struct ionic_dev *idev, u64 addr,
					    u32 offset, u32 length)
{}

static void ionic_dev_cmd_firmware_install(struct ionic_dev *idev)
{}

static void ionic_dev_cmd_firmware_activate(struct ionic_dev *idev, u8 slot)
{}

static int ionic_fw_status_long_wait(struct ionic *ionic,
				     const char *label,
				     unsigned long timeout,
				     u8 fw_cmd,
				     struct netlink_ext_ack *extack)
{}

int ionic_firmware_update(struct ionic_lif *lif, const struct firmware *fw,
			  struct netlink_ext_ack *extack)
{}