]> Pileus Git - ~andy/linux/commitdiff
Staging: line6/midi.c: Fixed call of obsolete function strict_strtoul
authorAndor Daam <andor.daam@googlemail.com>
Mon, 5 Dec 2011 09:10:37 +0000 (10:10 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 8 Dec 2011 20:32:55 +0000 (12:32 -0800)
The obsolete function strict_strtoul should be replaced by the kstrto*
functions.

In this context kstrtou16 should be use, as midi_mask_receive is only
used as unsigned short. All corresponding datatypes were adapted
accordingly.

Signed-off-by: Andor Daam <andor.daam@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/line6/midi.c
drivers/staging/line6/midi.h

index 3d1ada68c29da02cffbb8850708b1f55f484bb73..3013fb522bde7a417b664943ccb1bf325edcded2 100644 (file)
@@ -339,10 +339,10 @@ static ssize_t midi_set_midi_mask_receive(struct device *dev,
 {
        struct usb_interface *interface = to_usb_interface(dev);
        struct usb_line6 *line6 = usb_get_intfdata(interface);
-       unsigned long value;
+       unsigned short value;
        int ret;
 
-       ret = strict_strtoul(buf, 10, &value);
+       ret = kstrtou16(buf, 10, &value);
        if (ret)
                return ret;
 
index 2c0a66343ca5101feb89385fb4945da8c20d61c3..4a9e9f947297af8f6e9398aab66de4ac2396fc30 100644 (file)
@@ -62,7 +62,7 @@ struct snd_line6_midi {
        /**
                 Bit mask for input MIDI channels.
        */
-       int midi_mask_receive;
+       unsigned short midi_mask_receive;
 
        /**
                 Buffer for incoming MIDI stream.