From: Shraddha Barke Date: Fri, 11 Sep 2015 06:02:27 +0000 (+0530) Subject: Staging: speakup: serialio.c: Remove explicit NULL comparison X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=114885e08c0e7d55775373f5cea8fa3c0b1ef1e8;p=linux-beck.git Staging: speakup: serialio.c: Remove explicit NULL comparison Remove explicit NULL comparison and write it in its simpler form. Replacement done with coccinelle: @replace_rule@ expression e; @@ -e == NULL + !e Signed-off-by: Shraddha Barke Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/speakup/serialio.c b/drivers/staging/speakup/serialio.c index 66ac999a0323..3b5835b28128 100644 --- a/drivers/staging/speakup/serialio.c +++ b/drivers/staging/speakup/serialio.c @@ -101,7 +101,7 @@ static void start_serial_interrupt(int irq) { int rv; - if (synth->read_buff_add == NULL) + if (!synth->read_buff_add) return; rv = request_irq(irq, synth_readbuf_handler, IRQF_SHARED, @@ -127,7 +127,7 @@ void spk_stop_serial_interrupt(void) if (speakup_info.port_tts == 0) return; - if (synth->read_buff_add == NULL) + if (!synth->read_buff_add) return; /* Turn off interrupts */