/******************************************************************************
 * Copyright (c) 2024 Texas Instruments Incorporated - http://www.ti.com
 *
 *  Redistribution and use in source and binary forms, with or without
 *  modification, are permitted provided that the following conditions
 *  are met:
 *
 *    Redistributions of source code must retain the above copyright
 *    notice, this list of conditions and the following disclaimer.
 *
 *    Redistributions in binary form must reproduce the above copyright
 *    notice, this list of conditions and the following disclaimer in the
 *    documentation and/or other materials provided with the
 *    distribution.
 *
 *    Neither the name of Texas Instruments Incorporated nor the names of
 *    its contributors may be used to endorse or promote products derived
 *    from this software without specific prior written permission.
 *
 *  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 *  "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 *  LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 *  A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
 *  OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 *  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 *  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
 *  DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
 *  THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 *  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 *  OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 *****************************************************************************/

/**
 *  \file qos_data.h
 *
 *  \brief am62dx SOC Quality of Service (QoS) Configuration Data
 *         generated using K3 Resource Partitioning tool
 */

#ifndef QOS_DATA_H_
#define QOS_DATA_H_

/* ========================================================================== */
/*                             Include Files                                  */
/* ========================================================================== */

#include <drivers/qos/v0/soc/am62dx/qos_soc.h>

#ifdef __cplusplus
extern "C" {
#endif

/* ========================================================================== */
/*                           Macros & Typedefs                                */
/* ========================================================================== */

/* None */

/* ========================================================================== */
/*                         Structure Declarations                             */
/* ========================================================================== */

/* None */

/* ========================================================================== */
/*                            Global Variables                                */
/* ========================================================================== */

#define K3_QOS_REG(base_reg, i)	(base_reg + 0x100 + (i) * 4)

QOS_Config gQosData[] = {
    /* QoS data generated from K3 Resource Partitioning tool */
	{
		.reg = K3_QOS_REG(SAM62A_A53_512KB_WRAP_MAIN_0_A53_QUAD_WRAP_CBA_AXI_R, 0),
		.val = QOS_0|ORDERID_8|ASEL_0|EPRIORITY_0|VIRTID_0|ATYPE_0,
	}, 
	{
		.reg = K3_QOS_REG(SAM62A_A53_512KB_WRAP_MAIN_0_A53_QUAD_WRAP_CBA_AXI_W, 0),
		.val = QOS_0|ORDERID_8|ASEL_0|EPRIORITY_0|VIRTID_0|ATYPE_0,
	},
	{
		.reg = K3_QOS_REG(PULSAR_ULS_MCU_0_CPU0_RMST, 0),
		.val = QOS_0|ORDERID_8|ASEL_0|EPRIORITY_0|VIRTID_0|ATYPE_0,
	},
	{
		.reg = K3_QOS_REG(PULSAR_ULS_MCU_0_CPU0_WMST, 0),
		.val = QOS_0|ORDERID_8|ASEL_0|EPRIORITY_0|VIRTID_0|ATYPE_0,
	},
	{
		.reg = K3_QOS_REG(PULSAR_ULS_MCU_0_CPU0_PMST, 0),
		.val = QOS_0|ORDERID_8|ASEL_0|EPRIORITY_0|VIRTID_0|ATYPE_0,
	},
#if 0
	{
		.reg = K3_QOS_REG(SAM62A_C7XV_WRAP_MAIN_0_C7XV_SOC, 0),
		.val = ORDERID_8,
	}
#endif	
};

uint32_t gQosCount = sizeof(gQosData) / sizeof(gQosData[0]);

/* ========================================================================== */
/*                          Function Declarations                             */
/* ========================================================================== */

/* None */

#ifdef __cplusplus
}
#endif

#endif /* #ifndef QOS_DATA_H_ */
