// SPDX-License-Identifier: GPL-2.0 /* Marvell Octeon EP (EndPoint) Ethernet Driver * * Copyright (C) 2020 Marvell. * */ #include <linux/pci.h> #include <linux/etherdevice.h> #include <linux/vmalloc.h> #include "octep_config.h" #include "octep_main.h" /* Reset various index of Tx queue data structure. */ static void octep_iq_reset_indices(struct octep_iq *iq) { … } /** * octep_iq_process_completions() - Process Tx queue completions. * * @iq: Octeon Tx queue data structure. * @budget: max number of completions to be processed in one invocation. */ int octep_iq_process_completions(struct octep_iq *iq, u16 budget) { … } /** * octep_iq_free_pending() - Free Tx buffers for pending completions. * * @iq: Octeon Tx queue data structure. */ static void octep_iq_free_pending(struct octep_iq *iq) { … } /** * octep_clean_iqs() - Clean Tx queues to shutdown the device. * * @oct: Octeon device private data structure. * * Free the buffers in Tx queue descriptors pending completion and * reset queue indices */ void octep_clean_iqs(struct octep_device *oct) { … } /** * octep_setup_iq() - Setup a Tx queue. * * @oct: Octeon device private data structure. * @q_no: Tx queue number to be setup. * * Allocate resources for a Tx queue. */ static int octep_setup_iq(struct octep_device *oct, int q_no) { … } /** * octep_free_iq() - Free Tx queue resources. * * @iq: Octeon Tx queue data structure. * * Free all the resources allocated for a Tx queue. */ static void octep_free_iq(struct octep_iq *iq) { … } /** * octep_setup_iqs() - setup resources for all Tx queues. * * @oct: Octeon device private data structure. */ int octep_setup_iqs(struct octep_device *oct) { … } /** * octep_free_iqs() - Free resources of all Tx queues. * * @oct: Octeon device private data structure. */ void octep_free_iqs(struct octep_device *oct) { … }