OpenCores
URL https://opencores.org/ocsvn/test_project/test_project/trunk

Subversion Repositories test_project

[/] [test_project/] [trunk/] [linux_sd_driver/] [include/] [linux/] [phy_fixed.h] - Blame information for rev 81

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 62 marcus.erl
#ifndef __PHY_FIXED_H
2
#define __PHY_FIXED_H
3
 
4
#define MII_REGS_NUM    29
5
 
6
/* max number of virtual phy stuff */
7
#define MAX_PHY_AMNT    10
8
/*
9
    The idea is to emulate normal phy behavior by responding with
10
    pre-defined values to mii BMCR read, so that read_status hook could
11
    take all the needed info.
12
*/
13
 
14
struct fixed_phy_status {
15
        u8 link;
16
        u16 speed;
17
        u8 duplex;
18
};
19
 
20
/*-----------------------------------------------------------------------------
21
 *  Private information hoder for mii_bus
22
 *-----------------------------------------------------------------------------*/
23
struct fixed_info {
24
        u16 *regs;
25
        u8 regs_num;
26
        struct fixed_phy_status phy_status;
27
        struct phy_device *phydev;      /* pointer to the container */
28
        /* link & speed cb */
29
        int (*link_update) (struct net_device *, struct fixed_phy_status *);
30
 
31
};
32
 
33
 
34
int fixed_mdio_set_link_update(struct phy_device *,
35
       int (*link_update) (struct net_device *, struct fixed_phy_status *));
36
struct fixed_info *fixed_mdio_get_phydev (int phydev_ind);
37
 
38
#endif /* __PHY_FIXED_H */

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.