mirror of https://gitee.com/openkylin/linux.git
staging: pi433: Fix missing 'undefined' value in enum modulation
It is possible that rf69_get_modulation() function will return 'undefined' value and this value is missing in enum modulation. Fix this by adding appropriate entry in enum modulation. Signed-off-by: Marcin Ciupak <marcin.s.ciupak@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
8b26315ec7
commit
1c12da3576
|
@ -117,7 +117,7 @@ enum modulation rf69_get_modulation(struct spi_device *spi)
|
|||
switch (currentValue & MASK_DATAMODUL_MODULATION_TYPE >> 3) { // TODO improvement: change 3 to define
|
||||
case DATAMODUL_MODULATION_TYPE_OOK: return OOK;
|
||||
case DATAMODUL_MODULATION_TYPE_FSK: return FSK;
|
||||
default: return undefined;
|
||||
default: return UNDEF;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -28,7 +28,8 @@ enum mode {
|
|||
|
||||
enum modulation {
|
||||
OOK,
|
||||
FSK
|
||||
FSK,
|
||||
UNDEF
|
||||
};
|
||||
|
||||
enum mod_shaping {
|
||||
|
|
Loading…
Reference in New Issue