Skip to content

Commit

Permalink
[media] nuvoton-cir: simplify nvt_cir_tx_inactive
Browse files Browse the repository at this point in the history
Simplify nvt_cir_tx_inactive.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
  • Loading branch information
Heiner Kallweit authored and Mauro Carvalho Chehab committed Jan 25, 2016
1 parent 7a89836 commit 1feac49
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions drivers/media/rc/nuvoton-cir.c
Original file line number Diff line number Diff line change
Expand Up @@ -742,16 +742,13 @@ static void nvt_cir_log_irqs(u8 status, u8 iren)
static bool nvt_cir_tx_inactive(struct nvt_dev *nvt)
{
unsigned long flags;
bool tx_inactive;
u8 tx_state;

spin_lock_irqsave(&nvt->tx.lock, flags);
tx_state = nvt->tx.tx_state;
spin_unlock_irqrestore(&nvt->tx.lock, flags);

tx_inactive = (tx_state == ST_TX_NONE);

return tx_inactive;
return tx_state == ST_TX_NONE;
}

/* interrupt service routine for incoming and outgoing CIR data */
Expand Down

0 comments on commit 1feac49

Please sign in to comment.