linux/drivers/phy/marvell/phy-armada38x-comphy.c

// SPDX-License-Identifier: GPL-2.0
/*
 * Copyright (C) 2018 Russell King, Deep Blue Solutions Ltd.
 *
 * Partly derived from CP110 comphy driver by Antoine Tenart
 * <[email protected]>
 */
#include <linux/delay.h>
#include <linux/iopoll.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/phy/phy.h>
#include <linux/phy.h>
#include <linux/platform_device.h>

#define MAX_A38X_COMPHY
#define MAX_A38X_PORTS

#define COMPHY_CFG1
#define COMPHY_CFG1_GEN_TX(x)
#define COMPHY_CFG1_GEN_TX_MSK
#define COMPHY_CFG1_GEN_RX(x)
#define COMPHY_CFG1_GEN_RX_MSK
#define GEN_SGMII_1_25GBPS
#define GEN_SGMII_3_125GBPS

#define COMPHY_STAT1
#define COMPHY_STAT1_PLL_RDY_TX
#define COMPHY_STAT1_PLL_RDY_RX

#define COMPHY_SELECTOR

struct a38x_comphy;

struct a38x_comphy_lane {};

struct a38x_comphy {};

/*
 * Map serdes lanes and gbe ports to serdes mux configuration values:
 * row index = serdes lane,
 * column index = gbe port number.
 */
static const u8 gbe_mux[MAX_A38X_COMPHY][MAX_A38X_PORTS] =;

static void a38x_set_conf(struct a38x_comphy_lane *lane, bool enable)
{}

static void a38x_comphy_set_reg(struct a38x_comphy_lane *lane,
				unsigned int offset, u32 mask, u32 value)
{}

static void a38x_comphy_set_speed(struct a38x_comphy_lane *lane,
				  unsigned int gen_tx, unsigned int gen_rx)
{}

static int a38x_comphy_poll(struct a38x_comphy_lane *lane,
			    unsigned int offset, u32 mask, u32 value)
{}

/*
 * We only support changing the speed for comphys configured for GBE.
 * Since that is all we do, we only poll for PLL ready status.
 */
static int a38x_comphy_set_mode(struct phy *phy, enum phy_mode mode, int sub)
{}

static const struct phy_ops a38x_comphy_ops =;

static struct phy *a38x_comphy_xlate(struct device *dev,
				     const struct of_phandle_args *args)
{}

static int a38x_comphy_probe(struct platform_device *pdev)
{}

static const struct of_device_id a38x_comphy_of_match_table[] =;
MODULE_DEVICE_TABLE(of, a38x_comphy_of_match_table);

static struct platform_driver a38x_comphy_driver =;
module_platform_driver();

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();