Changeset 20751


Ignore:
Timestamp:
2010-04-09T10:40:06+02:00 (8 years ago)
Author:
juhosg
Message:

ar71xx: ag71xx: avoid unalinged accesses when using the phy specific receive functions

Cc: backfire@…

Location:
trunk/target/linux/ar71xx/files/drivers/net/ag71xx
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx.h

    r20750 r20751  
    3939 
    4040#define AG71XX_DRV_NAME         "ag71xx" 
    41 #define AG71XX_DRV_VERSION      "0.5.34" 
     41#define AG71XX_DRV_VERSION      "0.5.35" 
    4242 
    4343#define AG71XX_NAPI_WEIGHT      64 
  • trunk/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx_main.c

    r20750 r20751  
    765765        struct sk_buff *copy_skb; 
    766766 
     767        if (ag->phy_dev && (ag->phy_dev->pkt_align % 4) == 2) 
     768                goto keep; 
     769 
    767770        copy_skb = netdev_alloc_skb(ag->dev, pktlen + NET_IP_ALIGN); 
    768771        if (!copy_skb) 
     
    776779        *pskb = copy_skb; 
    777780 
     781        return 0; 
     782 
     783 keep: 
     784        skb_put(*pskb, pktlen); 
    778785        return 0; 
    779786} 
Note: See TracChangeset for help on using the changeset viewer.