NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

kern/50694: src/sys/dev/pci/if_alc.c:1421: possible bad bitmask ?



>Number:         50694
>Category:       kern
>Synopsis:       src/sys/dev/pci/if_alc.c:1421: possible bad bitmask ?
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Jan 22 17:15:00 +0000 2016
>Originator:     David Binderman
>Release:        cvs dated 20160121
>Organization:
>Environment:
>Description:

[src/sys/dev/pci/if_alc.c:1421] -> [src/sys/dev/pci/if_alc.c:1420]: (style) Same expression on both sides of '|'.

Source code is

    ifp->if_capabilities |= IFCAP_CSUM_IPv4_Tx | IFCAP_CSUM_IPv4_Rx |
                IFCAP_CSUM_TCPv4_Tx | IFCAP_CSUM_TCPv4_Rx |
                IFCAP_CSUM_UDPv4_Tx | IFCAP_CSUM_TCPv4_Rx;

Suggest new code

     ifp->if_capabilities |= IFCAP_CSUM_IPv4_Tx | IFCAP_CSUM_IPv4_Rx |
                IFCAP_CSUM_TCPv4_Tx | IFCAP_CSUM_TCPv4_Rx |
                IFCAP_CSUM_UDPv4_Tx | IFCAP_CSUM_UDPv4_Rx;

>How-To-Repeat:

>Fix:



Home | Main Index | Thread Index | Old Index