staging: fwserial: (coding style) removing "!= NULL" to comply with checkpatch.pl
authorDominique van den Broeck <domdevlin@free.fr>
Tue, 29 Mar 2016 17:14:21 +0000 (19:14 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 29 Mar 2016 21:41:15 +0000 (14:41 -0700)
Removing two "!= NULL" from fwserial.c as suggested by checkpatch.pl.
Note that the associated expression "port->port.console" is a 1-bit-field
that is already assumed as an implicit boolean (that is: without comparison)

Signed-off-by: Dominique van den Broeck <domdevlin@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/fwserial/fwserial.c

index 66e54e767c98cf9da4e52e939a751ca7f55f7ac1..4dd5304cb7182fe931fa3d680e0f80a8e4c4ccf3 100644 (file)
@@ -1701,7 +1701,7 @@ static void fwserial_virt_plug_complete(struct fwtty_peer *peer,
        dma_fifo_change_tx_limit(&port->tx_fifo, port->max_payload);
        spin_unlock_bh(&peer->port->lock);
 
-       if (port->port.console && port->fwcon_ops->notify != NULL)
+       if (port->port.console && port->fwcon_ops->notify)
                (*port->fwcon_ops->notify)(FWCON_NOTIFY_ATTACH, port->con_data);
 
        fwtty_info(&peer->unit, "peer (guid:%016llx) connected on %s\n",
@@ -1808,7 +1808,7 @@ static void fwserial_release_port(struct fwtty_port *port, bool reset)
        RCU_INIT_POINTER(port->peer, NULL);
        spin_unlock_bh(&port->lock);
 
-       if (port->port.console && port->fwcon_ops->notify != NULL)
+       if (port->port.console && port->fwcon_ops->notify)
                (*port->fwcon_ops->notify)(FWCON_NOTIFY_DETACH, port->con_data);
 }
 
This page took 0.025766 seconds and 5 git commands to generate.