[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

About that Alpha kernel bug mentioned in beta3 errata



Hello,

if that bug (alpha cannot install from SCSI cdrom) is the one mentioned in
<http://lists.debian.org/debian-boot/2004/debian-boot-200401/msg00374.html>,
then I've run into it as well with a daily build shortly before d-i beta3.
Is this fixed now? If not here is some additional info:
On my system (an AS 2100A "Lynx" btw, cool these are supported now):

# cd /dev/cdroms
# ls -l
        lr-xr-xr-x 1 root root 34 Jan 1 1970 cdrom0 -> yyyscsi/host0/bus0/target6/lun0/cd
        [actually, the 'y's are y with dieresis, 0xff in ISO-8859-1]

And it is possible to work around it: create a _correct_ link under
another name, e.g.

# ln -s ../scsi/host0/bus0/target6/lun0/cd cdrom1

then try detecting the cdrom again, voila.

The symlink gets created in drivers/cdrom/cdrom.c:register_cdrom():

                if (pos >= 0) {
                        char vname[16];
                        sprintf (vname, "cdrom%d", cdi->number);
                        strncpy (rname + pos, "../", 3);
                        devfs_mk_symlink (devfs_handle, vname,
                                          DEVFS_FL_DEFAULT,
                                          rname + pos, &slave, NULL);
                        devfs_auto_unregister (cdi->de, slave);
                }

That piece of code is shared by all kinds of cdroms, and all
architectures... so how can it be broken on alpha and not on x86,
and with SCSI but not IDE? I think the strncpy (rname + pos, "../", 3);
call fails, and strncpy is arch specific. This would mean that, in the
end, alpha stxncpy.S is broken again. I don't know enough alpha assembly
to understand what's going on, but it seems there are a lot of hairy
corner cases, depending on data length and alignment. Maybe one could
replace the strncpy with array member assignments and see what happens.
I can't try this myself because I only have access to this one alpha machine
and it still waits for its dose of Linux.

The other possibility would be a gcc optimizer bug.

One final remark: it would tremendously help troubleshooting hardware /
kernel related problems if a rmmod command were available from the
d-i shell prompt.


Regards,

Bjoern Brill

P.S.: please cc me on replies, I'm not on the list.

--
Bj"orn Brill <brill@fs.math.uni-frankfurt.de>
Frankfurt am Main, Germany




Reply to: