Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: speakup: fix type mismatch warnings

Compiling speakup driver with sparse produces following warning:

drivers/staging/speakup/serialio.c:22:9: warning: incorrect type in
initializer (different base types)
drivers/staging/speakup/serialio.c:22:9: expected unsigned int
[unsigned] flags
drivers/staging/speakup/serialio.c:22:9: got restricted upf_t

This patch fixes it.

Signed-off-by: Okash Khawaja <okash.khawaja@gmail.com>
Acked-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Okash Khawaja and committed by
Greg Kroah-Hartman
ff59f2a6 b42ca86a

+2 -1
+2 -1
drivers/staging/speakup/serialio.h
··· 6 6 #ifndef __sparc__ 7 7 #include <linux/serial.h> 8 8 #endif 9 + #include <linux/serial_core.h> 9 10 10 11 /* 11 12 * this is cut&paste from 8250.h. Get rid of the structure, the definitions ··· 17 16 unsigned int baud_base; 18 17 unsigned int port; 19 18 unsigned int irq; 20 - unsigned int flags; /* unused */ 19 + upf_t flags; /* unused */ 21 20 }; 22 21 23 22 /* countdown values for serial timeouts in us */