Bug#697017: root=compute fails at parse_numeric() for lilo compatibility
gabriel wrote:
> Stephen Powell <zlinuxman@wowway.com> schrieb am Tue, Jan 01, 2013 at 11:56:00AM -0500:
>> We accept the following variants:
>>
>> 1) device number in hexadecimal represents itself
>
> I haven't read that kernel source code before and therefore didn't know that
> the root parameter may be a hex number of arbitrary length.
>
> So I totally agree with the patch that you've made.
Technically the current code only makes sense for 5 hexdigits.
After that, something more complicated could work:
# 16 hexdigits: 0xMMMMMmmmmmmMMMmm
devno=$(( 0x${1} ))
major=$(( (($devno >> 8) & 0xfff) | (($devno >> 32) & ~0xfff) ))
minor=$(( ($devno & 0xff) | (($devno >> 12) & 0xffffff00) ))
Reply to: