mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-12-11 22:03:15 +00:00
c919ab9ee5
As per current implementation of DPAA2 ethernet driver DPNI is used as net device. DPNI is tangible objects can be multiple connected to same physical lane. Use DPMAC as net device where it represents physical lane. Below modification done in driver - Use global DPNI object - Connect DPMAC to DPNI - Create and destroy DPMAC Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com> Reviewed-by: York Sun <yorksun@freescale.com>
70 lines
1.5 KiB
C
70 lines
1.5 KiB
C
/*
|
|
* Copyright (C) 2014 Freescale Semiconductor
|
|
*
|
|
* SPDX-License-Identifier: GPL-2.0+
|
|
*/
|
|
|
|
#ifndef _FSL_MC_PRIVATE_H_
|
|
#define _FSL_MC_PRIVATE_H_
|
|
|
|
#include <errno.h>
|
|
#include <malloc.h>
|
|
#include <asm/io.h>
|
|
#include <linux/compat.h>
|
|
#include <linux/types.h>
|
|
#include <linux/stringify.h>
|
|
#include <phy.h>
|
|
|
|
#include <fsl-mc/fsl_mc_sys.h>
|
|
#include <fsl-mc/fsl_mc_cmd.h>
|
|
#include <fsl-mc/fsl_dprc.h>
|
|
#include <fsl-mc/fsl_dpbp.h>
|
|
#include <fsl-mc/fsl_dpni.h>
|
|
|
|
extern struct fsl_mc_io *dflt_mc_io;
|
|
|
|
/**
|
|
* struct dpbp_node - DPBP strucuture
|
|
* @uint16_t handle: DPBP object handle
|
|
* @struct dpbp_attr: DPBP attribute
|
|
*/
|
|
struct fsl_dpbp_obj {
|
|
uint16_t dpbp_handle;
|
|
struct dpbp_attr dpbp_attr;
|
|
};
|
|
|
|
extern struct fsl_dpbp_obj *dflt_dpbp;
|
|
|
|
/**
|
|
* struct fsl_dpio_obj - DPIO strucuture
|
|
* @int dpio_id: DPIO id
|
|
* @struct qbman_swp *sw_portal: SW portal object
|
|
*/
|
|
struct fsl_dpio_obj {
|
|
int dpio_id;
|
|
uint16_t dpio_handle;
|
|
struct qbman_swp *sw_portal; /** SW portal object */
|
|
};
|
|
|
|
extern struct fsl_dpio_obj *dflt_dpio;
|
|
|
|
/**
|
|
* struct dpni_node - DPNI strucuture
|
|
* @int dpni_id: DPNI id
|
|
* @uint16_t handle: DPNI object handle
|
|
* @struct dpni_attr: DPNI attributes
|
|
* @struct dpni_buffer_layout: DPNI buffer layout
|
|
*/
|
|
struct fsl_dpni_obj {
|
|
int dpni_id;
|
|
uint16_t dpni_handle;
|
|
struct dpni_attr dpni_attrs;
|
|
struct dpni_buffer_layout buf_layout;
|
|
};
|
|
|
|
extern struct fsl_dpni_obj *dflt_dpni;
|
|
|
|
int mc_init(u64 mc_fw_addr, u64 mc_dpc_addr);
|
|
int ldpaa_eth_init(int dpmac_id, phy_interface_t enet_if);
|
|
int mc_apply_dpl(u64 mc_dpl_addr);
|
|
#endif /* _FSL_MC_PRIVATE_H_ */
|