]> git.baikalelectronics.ru Git - kernel.git/commit
Modpost: fixed USB alias generation for ranges including 0x9 and 0xA
authorJan Moskyto Matejka <mq@suse.cz>
Fri, 7 Feb 2014 18:15:11 +0000 (19:15 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 7 Feb 2014 19:26:35 +0000 (11:26 -0800)
commita9c7456356c74056c37338b3771ca42af5a07fdc
treefc0968a9e7cd6003903060e2764c7bad56d887e0
parent912de722749aa3203b6fc03e162d2c1e3ad31617
Modpost: fixed USB alias generation for ranges including 0x9 and 0xA

Commit c6f2bfc22a ("USB: add hex/bcd detection to usb modalias generation")
changed the routine that generates alias ranges. Before that change, only
digits 0-9 were supported; the commit tried to fix the case when the range
includes higher values than 0x9.

Unfortunately, the commit didn't fix the case when the range includes both
0x9 and 0xA, meaning that the final range must look like [x-9A-y] where
x <= 0x9 and y >= 0xA -- instead the [x-9A-x] range was produced.

Modprobe doesn't complain as it sees no difference between no-match and
bad-pattern results of fnmatch().

Fixing this simple bug to fix the aliases.
Also changing the hardcoded beginning of the range to uppercase as all the
other letters are also uppercase in the device version numbers.

Fortunately, this affects only the dvb-usb-dib0700 module, AFAIK.

Signed-off-by: Jan Moskyto Matejka <mq@suse.cz>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
scripts/mod/file2alias.c