Changeset 37995


Ignore:
Timestamp:
2013-09-15T15:30:49+02:00 (4 years ago)
Author:
hauke
Message:

kernel: b53: detect revision of BCM5325

The revision is stored in a different register than it is in other
Broadcom switches.

Signed-off-by: Hauke Mehrtens <hauke@…>

Location:
trunk/target/linux/generic/files/drivers/net/phy/b53
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/generic/files/drivers/net/phy/b53/b53_common.c

    r37994 r37995  
    13061306        } 
    13071307 
    1308         return b53_read8(dev, B53_MGMT_PAGE, B53_REV_ID, &dev->core_rev); 
     1308        if (dev->chip_id == BCM5325_DEVICE_ID) 
     1309                return b53_read8(dev, B53_STAT_PAGE, B53_REV_ID_25, 
     1310                                 &dev->core_rev); 
     1311        else 
     1312                return b53_read8(dev, B53_MGMT_PAGE, B53_REV_ID, 
     1313                                 &dev->core_rev); 
    13091314} 
    13101315EXPORT_SYMBOL(b53_switch_detect); 
  • trunk/target/linux/generic/files/drivers/net/phy/b53/b53_regs.h

    r35305 r37995  
    136136#define B53_DUPLEX_STAT_63XX            0x0c 
    137137 
     138/* Revision ID register for BCM5325 */ 
     139#define B53_REV_ID_25                   0x50 
     140 
    138141/* Strap Value (48 bit) */ 
    139142#define B53_STRAP_VALUE                 0x70 
Note: See TracChangeset for help on using the changeset viewer.