Home
last modified time | relevance | path

Searched +full:mdio +full:- +full:bus (Results 1 – 25 of 764) sorted by relevance

12345678910>>...31

/linux/drivers/net/ethernet/hisilicon/
H A Dhns_mdio.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * Copyright (c) 2014-2015 Hisilicon Limited.
23 #define MDIO_DRV_NAME "Hi-HNS_MDIO"
24 #define MDIO_BUS_NAME "Hisilicon MII Bus"
38 u8 __iomem *vbase; /* mdio reg base address */
43 /* mdio reg */
101 mdio_write_reg((a)->vbase, (reg), (value))
126 mdio_set_reg_field((dev)->vbase, (reg), (mask), (shift), (val))
137 mdio_get_reg_field((dev)->vbase, (reg), (mask), (shift))
140 mdio_get_reg_field((dev)->vbase, (reg), 0x1ull, (bit))
[all …]
/linux/drivers/net/ethernet/xilinx/
H A Dxilinx_axienet_mdio.c1 // SPDX-License-Identifier: GPL-2.0
3 * MDIO bus driver for the Xilinx Axi Ethernet device
6 * Copyright (c) 2010 - 2011 Michal Simek <monstr@monstr.eu>
7 * Copyright (c) 2010 - 2011 PetaLogix
9 * Copyright (c) 2010 - 2012 Xilinx, Inc. All rights reserved.
24 * axienet_mdio_wait_until_ready - MDIO wait function
29 * Wait till MDIO interface is ready to accept a new transaction.
41 * axienet_mdio_mdc_enable - MDIO MDC enable function
44 * Enable the MDIO MDC. Called prior to a read/write operation
49 ((u32)lp->mii_clk_div | XAE_MDIO_MC_MDIOEN_MASK)); in axienet_mdio_mdc_enable()
[all …]
/linux/drivers/net/ethernet/arc/
H A Demac_mdio.c1 // SPDX-License-Identifier: GPL-2.0
3 * Copyright (C) 2004-2013 Synopsys, Inc. (www.synopsys.com)
5 * MDIO implementation for ARC EMAC
15 /* Number of seconds we wait for "MDIO complete" flag to appear */
19 * arc_mdio_complete_wait - Waits until MDIO transaction is completed.
22 * returns: 0 on success, -ETIMEDOUT on a timeout.
34 /* Reset "MDIO complete" flag */ in arc_mdio_complete_wait()
42 return -ETIMEDOUT; in arc_mdio_complete_wait()
46 * arc_mdio_read - MDIO interface read function.
47 * @bus: Pointer to MII bus structure.
[all …]
/linux/drivers/net/ethernet/freescale/
H A Dfsl_pq_mdio.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * Freescale PowerQUICC Ethernet Driver -- MIIM bus implementation
4 * Provides Bus interface for MIIM regs
9 * Copyright 2002-2004, 2008-2009 Freescale Semiconductor, Inc.
52 u32 ieventm; /* MDIO Interrupt event register (for etsec2)*/
53 u32 imaskm; /* MDIO Interrupt mask register (for etsec2)*/
55 u32 emapm; /* MDIO Event mapping register (for etsec2)*/
72 * Per-device-type data. Each type of device tree node that we support gets
90 * Write value to the PHY at mii_id at register regnum, on the bus attached
91 * to the local interface, which may be different from the generic mdio bus
[all …]
H A Dxgmac_mdio.c2 * QorIQ 10G MDIO Controller
20 #include <linux/mdio.h>
33 __be32 mdio_stat; /* MDIO configuration and status */
34 __be32 mdio_ctl; /* MDIO control */
35 __be32 mdio_data; /* MDIO data */
36 __be32 mdio_addr; /* MDIO address */
82 * Wait until the MDIO bus is free
90 /* Wait till the bus is free */ in xgmac_wait_until_free()
92 while ((xgmac_read32(&regs->mdio_stat, is_little_endian) & in xgmac_wait_until_free()
95 timeout--; in xgmac_wait_until_free()
[all …]
/linux/Documentation/devicetree/bindings/net/
H A Dmdio.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
4 $id: http://devicetree.org/schemas/net/mdio.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: MDIO Bus Common Properties
10 - Andrew Lunn <andrew@lunn.ch>
11 - Florian Fainelli <f.fainelli@gmail.com>
12 - Heiner Kallweit <hkallweit1@gmail.com>
15 These are generic properties that can apply to any MDIO bus. Any
16 MDIO bus must have a list of child nodes, one per device on the
[all …]
H A Dmdio-mux-mmioreg.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
4 $id: http://devicetree.org/schemas/net/mdio-mux-mmioreg.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Properties for an MDIO bus multiplexer controlled by a memory-mapped device
10 - Andrew Lunn <andrew@lunn.ch>
13 This is a special case of a MDIO bus multiplexer. A memory-mapped device,
14 like an FPGA, is used to control which child bus is connected. The mdio-mux
15 node must be a child of the memory-mapped device. The driver currently only
16 supports devices with 8, 16 or 32-bit registers.
[all …]
H A Damlogic,gxl-mdio-mux.yaml1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
3 ---
4 $id: http://devicetree.org/schemas/net/amlogic,gxl-mdio-mux.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Amlogic GXL MDIO bus multiplexer
10 - Jerome Brunet <jbrunet@baylibre.com>
13 This is a special case of a MDIO bus multiplexer. It allows to choose between
14 the internal mdio bus leading to the embedded 10/100 PHY or the external
15 MDIO bus on the Amlogic GXL SoC family.
18 - $ref: mdio-mux.yaml#
[all …]
H A Dmdio-mux.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
4 $id: http://devicetree.org/schemas/net/mdio-mux.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Common MDIO bus multiplexer/switch properties.
10 - Andrew Lunn <andrew@lunn.ch>
13 An MDIO bus multiplexer/switch will have several child busses that are
14 numbered uniquely in a device dependent manner. The nodes for an MDIO
15 bus multiplexer/switch will have one child node for each child bus.
18 mdio-parent-bus:
[all …]
H A Damlogic,g12a-mdio-mux.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/net/amlogic,g12a-mdio-mux.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: MDIO bus multiplexer/glue of Amlogic G12a SoC family
10 This is a special case of a MDIO bus multiplexer. It allows to choose between
11 the internal mdio bus leading to the embedded 10/100 PHY or the external
12 MDIO bus.
15 - Neil Armstrong <neil.armstrong@linaro.org>
18 - $ref: mdio-mux.yaml#
[all …]
H A Dfsl,fman-mdio.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/net/fsl,fman-mdio.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Freescale Frame Manager MDIO Device
10 - Frank Li <Frank.Li@nxp.com>
12 description: FMan MDIO Node.
13 The MDIO is a bus to which the PHY devices are connected.
18 - fsl,fman-mdio
19 - fsl,fman-xmdio
[all …]
H A Dcavium-mdio.txt1 * System Management Interface (SMI) / MDIO
4 - compatible: One of:
6 "cavium,octeon-3860-mdio": Compatibility with all cn3XXX, cn5XXX
9 "cavium,thunder-8890-mdio": Compatibility with all cn8XXX SOCs.
11 - reg: The base address of the MDIO bus controller register bank.
13 - #address-cells: Must be <1>.
15 - #size-cells: Must be <0>. MDIO addresses have no size component.
17 Typically an MDIO bus might have several children.
20 mdio@1180000001800 {
21 compatible = "cavium,octeon-3860-mdio";
[all …]
H A Dfsl,gianfar-mdio.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/net/fsl,gianfar-mdio.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Freescale Gianfar (TSEC) MDIO Device
10 This binding describes the MDIO is a bus to which the PHY devices are
11 connected. For each device that exists on this bus, a child node should be
14 Some TSECs are associated with an internal Ten-Bit Interface (TBI) PHY. This
15 PHY is accessed through the local MDIO bus. These buses are defined similarly
16 to the mdio buses, except they are compatible with "fsl,gianfar-tbi". The TBI
[all …]
H A Dbrcm,bcm6368-mdio-mux.yaml1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
3 ---
4 $id: http://devicetree.org/schemas/net/brcm,bcm6368-mdio-mux.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Broadcom BCM6368 MDIO bus multiplexer
10 - Álvaro Fernández Rojas <noltari@gmail.com>
13 This MDIO bus multiplexer defines buses that could be internal as well as
14 external to SoCs. When child bus is selected, one needs to select these two
15 properties as well to generate desired MDIO transaction on appropriate bus.
18 - $ref: mdio-mux.yaml#
[all …]
H A Dhisilicon-hns-mdio.txt1 Hisilicon MDIO bus controller
4 - compatible: can be one of:
5 "hisilicon,hns-mdio"
6 "hisilicon,mdio"
7 "hisilicon,hns-mdio" is recommended to be used for hip05 and later SOCs,
8 while "hisilicon,mdio" is optional for backwards compatibility only on
10 - reg: The base address of the MDIO bus controller register bank.
11 - #address-cells: Must be <1>.
12 - #size-cells: Must be <0>. MDIO addresses have no size component.
14 Typically an MDIO bus might have several children.
[all …]
H A Dmdio-mux-multiplexer.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
4 $id: http://devicetree.org/schemas/net/mdio-mux-multiplexer.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Properties for an MDIO bus multiplexer consumer device
10 - Andrew Lunn <andrew@lunn.ch>
13 This is a special case of MDIO mux when MDIO mux is defined as a consumer
19 - $ref: /schemas/net/mdio-mux.yaml#
23 const: mdio-mux-multiplexer
25 mux-controls:
[all …]
/linux/drivers/net/phy/
H A Dmdio_bus.c1 // SPDX-License-Identifier: GPL-2.0+
2 /* MDIO Bus interface
34 #include <trace/events/mdio.h>
39 mdiodev->reset_gpio = gpiod_get_optional(&mdiodev->dev, in mdiobus_register_gpiod()
41 if (IS_ERR(mdiodev->reset_gpio)) in mdiobus_register_gpiod()
42 return PTR_ERR(mdiodev->reset_gpio); in mdiobus_register_gpiod()
44 if (mdiodev->reset_gpio) in mdiobus_register_gpiod()
45 gpiod_set_consumer_name(mdiodev->reset_gpio, "PHY reset"); in mdiobus_register_gpiod()
54 reset = reset_control_get_optional_exclusive(&mdiodev->dev, "phy"); in mdiobus_register_reset()
58 mdiodev->reset_ctrl = reset; in mdiobus_register_reset()
[all …]
H A Dmdio_device.c1 // SPDX-License-Identifier: GPL-2.0+
2 /* Framework for MDIO devices, other than PHYs.
16 #include <linux/mdio.h>
28 put_device(&mdiodev->dev); in mdio_device_free()
34 fwnode_handle_put(dev->fwnode); in mdio_device_release()
44 if (mdiodrv->mdiodrv.flags & MDIO_DEVICE_IS_PHY) in mdio_device_bus_match()
47 return strcmp(mdiodev->modalias, drv->name) == 0; in mdio_device_bus_match()
50 struct mdio_device *mdio_device_create(struct mii_bus *bus, int addr) in mdio_device_create() argument
57 return ERR_PTR(-ENOMEM); in mdio_device_create()
59 mdiodev->dev.release = mdio_device_release; in mdio_device_create()
[all …]
/linux/Documentation/firmware-guide/acpi/dsd/
H A Dphy.rst1 .. SPDX-License-Identifier: GPL-2.0
4 MDIO bus and PHYs in ACPI
7 The PHYs on an MDIO bus [phy] are probed and registered using
11 on the MDIO bus have to be referenced.
14 for connecting PHYs on the MDIO bus [dsd-properties-rules] to the MAC layer.
17 Properties UUID For _DSD" [dsd-guide] document and the
18 daffd814-6eba-4d8c-8a91-bc9bbf4aa301 UUID must be used in the Device
21 phy-handle
22 ----------
23 For each MAC node, a device property "phy-handle" is used to reference
[all …]
/linux/include/linux/
H A Dmdio.h1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * linux/mdio.h: definitions for MDIO (clause 45) transceivers
4 * Copyright 2006-2009 Solarflare Communications Inc.
9 #include <uapi/linux/mdio.h>
31 struct mii_bus *bus; member
38 /* Bus address of the MDIO device (0-31) */
50 /* struct mdio_driver_common: Common to all MDIO drivers */
60 /* struct mdio_driver: Generic MDIO driver */
66 * up device-specific structures, if any
81 static inline void mdiodev_set_drvdata(struct mdio_device *mdio, void *data) in mdiodev_set_drvdata() argument
[all …]
/linux/drivers/net/mdio/
H A Dacpi_mdio.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * ACPI helpers for the MDIO (Ethernet PHY) API
19 MODULE_DESCRIPTION("ACPI MDIO bus (Ethernet PHY) accessors");
22 * __acpi_mdiobus_register - Register mii_bus and create PHYs from the ACPI ASL.
23 * @mdio: pointer to mii_bus structure
24 * @fwnode: pointer to fwnode of MDIO bus. This fwnode is expected to represent
25 * @owner: module owning this @mdio object.
26 * an ACPI device object corresponding to the MDIO bus and its children are
27 * expected to correspond to the PHY devices on that bus.
32 int __acpi_mdiobus_register(struct mii_bus *mdio, struct fwnode_handle *fwnode, in __acpi_mdiobus_register() argument
[all …]
H A Dfwnode_mdio.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * fwnode helpers for the MDIO (Ethernet PHY) API
14 #include <linux/pse-pd/pse.h>
18 MODULE_DESCRIPTION("FWNODE MDIO bus (Ethernet PHY) accessors");
35 if (PTR_ERR(psec) == -ENOENT) in fwnode_find_pse_control()
53 if (err == -ENOENT) in fwnode_find_mii_timestamper()
59 mii_ts = ERR_PTR(-EINVAL); in fwnode_find_mii_timestamper()
70 int fwnode_mdiobus_phy_device_register(struct mii_bus *mdio, in fwnode_mdiobus_phy_device_register() argument
80 if (rc == -EPROBE_DEFER) in fwnode_mdiobus_phy_device_register()
81 rc = driver_deferred_probe_check_state(&phy->mdio.dev); in fwnode_mdiobus_phy_device_register()
[all …]
/linux/drivers/net/dsa/
H A Dlan9303_mdio.c1 // SPDX-License-Identifier: GPL-2.0-only
10 #include <linux/mdio.h>
16 /* Generate phy-addr and -reg from the input address */
25 static void lan9303_mdio_real_write(struct mdio_device *mdio, int reg, u16 val) in lan9303_mdio_real_write() argument
27 mdio->bus->write(mdio->bus, PHY_ADDR(reg), PHY_REG(reg), val); in lan9303_mdio_real_write()
35 mutex_lock_nested(&sw_dev->device->bus->mdio_lock, MDIO_MUTEX_NESTED); in lan9303_mdio_write()
36 lan9303_mdio_real_write(sw_dev->device, reg, val & 0xffff); in lan9303_mdio_write()
37 lan9303_mdio_real_write(sw_dev->device, reg + 2, (val >> 16) & 0xffff); in lan9303_mdio_write()
38 mutex_unlock(&sw_dev->device->bus->mdio_lock); in lan9303_mdio_write()
43 static u16 lan9303_mdio_real_read(struct mdio_device *mdio, int reg) in lan9303_mdio_real_read() argument
[all …]
/linux/drivers/net/usb/
H A Dax88172a.c1 // SPDX-License-Identifier: GPL-2.0-or-later
9 * Copyright (C) 2003-2006 David Hollis <dhollis@davehollis.com>
12 * Copyright (c) 2002-2003 TiVo Inc.
19 struct mii_bus *mdio; member
31 struct phy_device *phydev = netdev->phydev; in ax88172a_adjust_link()
33 struct ax88172a_private *priv = dev->driver_priv; in ax88172a_adjust_link()
36 if (phydev->link) { in ax88172a_adjust_link()
39 if (phydev->duplex == DUPLEX_HALF) in ax88172a_adjust_link()
42 if (phydev->speed != SPEED_100) in ax88172a_adjust_link()
46 if (mode != priv->oldmode) { in ax88172a_adjust_link()
[all …]
/linux/drivers/net/dsa/mv88e6xxx/
H A Dpcs-6352.c1 // SPDX-License-Identifier: GPL-2.0-or-later
25 struct mdio_device mdio; member
43 mutex_lock(&mpcs->mdio.bus->mdio_lock); in marvell_c22_pcs_set_fiber_page()
45 err = __mdiodev_read(&mpcs->mdio, MII_MARVELL_PHY_PAGE); in marvell_c22_pcs_set_fiber_page()
47 dev_err(mpcs->mdio.dev.parent, in marvell_c22_pcs_set_fiber_page()
49 mpcs->name, ERR_PTR(err)); in marvell_c22_pcs_set_fiber_page()
55 err = __mdiodev_write(&mpcs->mdio, MII_MARVELL_PHY_PAGE, in marvell_c22_pcs_set_fiber_page()
58 dev_err(mpcs->mdio.dev.parent, in marvell_c22_pcs_set_fiber_page()
60 mpcs->name, ERR_PTR(err)); in marvell_c22_pcs_set_fiber_page()
73 err = __mdiodev_write(&mpcs->mdio, MII_MARVELL_PHY_PAGE, in marvell_c22_pcs_restore_page()
[all …]

12345678910>>...31