NetBSD-Bugs archive

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

port-evbmips/50856: src/sys/arch/evbmips/isa/isadma_bounce.c: 2 * redundant conditions



>Number:         50856
>Category:       port-evbmips
>Synopsis:       src/sys/arch/evbmips/isa/isadma_bounce.c: 2 * redundant conditions
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    port-evbmips-maintainer
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Feb 26 17:30:00 +0000 2016
>Originator:     David Binderman
>Release:        cvs dated 20160226
>Organization:
>Environment:
>Description:
1.

[src/sys/arch/evbmips/isa/isadma_bounce.c:181]: (style) Redundant condition: error!=0. 'A || (!A && B)' is equivalent to 'A || B'


Source code is

    if (error == 0 ||
        (error != 0 && (cookie->id_flags & _BUS_DMA_MIGHT_NEED_BOUNCE) == 0))

2.

[src/sys/arch/evbmips/isa/isadma_bounce.c:251]: (style) Redundant condition: error!=0. 'A || (!A && B)' is equivalent to 'A || B'

Source code is

    if (error == 0 ||
        (error != 0 && (cookie->id_flags & _BUS_DMA_MIGHT_NEED_BOUNCE) == 0))

>How-To-Repeat:

>Fix:



Home | Main Index | Thread Index | Old Index