From: Alan Cox Date: Thu, 25 Oct 2012 14:18:34 +0000 (+0100) Subject: rfkill: error cannot be set here so simplify X-Git-Tag: firefly_0821_release~3680^2~631^2~105 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=6f7c962c0b8efc78aec4c5514865fb5be83f4d92;p=firefly-linux-kernel-4.4.55.git rfkill: error cannot be set here so simplify Signed-off-by: Alan Cox Signed-off-by: Jiri Kosina --- diff --git a/net/rfkill/core.c b/net/rfkill/core.c index 752b72360ebc..61c112c890a9 100644 --- a/net/rfkill/core.c +++ b/net/rfkill/core.c @@ -656,7 +656,7 @@ static ssize_t rfkill_soft_store(struct device *dev, rfkill_set_block(rfkill, state); mutex_unlock(&rfkill_global_mutex); - return err ?: count; + return count; } static u8 user_state_from_blocked(unsigned long state) @@ -701,7 +701,7 @@ static ssize_t rfkill_state_store(struct device *dev, rfkill_set_block(rfkill, state == RFKILL_USER_STATE_SOFT_BLOCKED); mutex_unlock(&rfkill_global_mutex); - return err ?: count; + return count; } static ssize_t rfkill_claim_show(struct device *dev,