Commit e2bdb0d8 authored by H Hartley Sweeten's avatar H Hartley Sweeten Committed by Greg Kroah-Hartman

staging: comedi: ni_stc.h: remove unreachable code in RTSI_Output_Bit()

All the callers of this function check the 'channel' number with
num_configurable_rtsi_channels(). This check can never occure.
Remove it.
Signed-off-by: default avatarH Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: default avatarIan Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5ecadf8c
......@@ -352,10 +352,6 @@ static inline unsigned RTSI_Output_Bit(unsigned channel, int is_mseries)
base_bit_shift = 9;
max_channel = 6;
}
if (channel > max_channel) {
pr_err("%s: bug, invalid RTSI_channel=%i\n", __func__, channel);
return 0;
}
return 1 << (base_bit_shift + channel);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment