Return value of slave_configure in scsi_scan.c is ignored

Bug #57265 reported by Ondřej Surý
10
Affects Status Importance Assigned to Milestone
linux-restricted-modules-2.6.15 (Ubuntu)
Invalid
Undecided
Unassigned
linux-source-2.6.15 (Ubuntu)
Fix Released
Undecided
Kyle McMartin

Bug Description

Number of scsi drivers return some return code from slave_configure function which is called on scsi bus scan (or whatever). This value gets ignored in 2.6.15.x and this causes problem with LSI Logig Megaraid SAS driver which uses return value to indicate that disk should not be exported to the system and thus you see all Physical Disk as /dev/sdx in your system (which is not fine when those disk are part of some RAID) and all Logical Disks (which is perfectly OK).

Attached patch merges smallest possible change into scsi_scan.c which fixes this breakage. And also fixes some breakages in other drivers which return non-zero response to indicate that this device should not be initialized.

Please apply since this makes all LSI Megaraid SAS controllers unusable.

Revision history for this message
Ondřej Surý (ondrej) wrote :
Revision history for this message
Ondřej Surý (ondrej) wrote :

Patch which actually applies to current linux-source-2.6.15

Revision history for this message
Matthew Gregg (mcg) wrote :

Just bitten by this on 4 new servers I was attempting Dapper install's on. I worked around with a custom kernel. Please apply this patch to the official kernels. Thanks.

Revision history for this message
Matthew Gregg (mcg) wrote :

Any chance this is going to be fixed? One of the reasons I switched from Debian to Ubuntu was to not have to run a custom kernel and here I am, back to custom.

Revision history for this message
Ben Collins (ben-collins) wrote :

Will get added to dapper (via the dapper-proposed branch) soon.

Thanks.

Changed in linux-source-2.6.15:
assignee: nobody → ben-collins
status: Unconfirmed → Fix Committed
Revision history for this message
Robert Citek (robert-citek) wrote :

Hello all,

Has anyone successfully applied the patch and used it in a running kernel? If so, would you be willing to post a link to instructions?

Here's what I tried, which did not work:

sudo su -
apt-get update
apt-get install linux-source
wget 'http://librarian.launchpad.net/3976623/scsi-scan.c-slave_configure_retval.diff'
cd /usr/src/
tar -xjvf linux-source-2.6.15.tar.bz2
patch -i scsi-scan.c-slave_configure_retval.diff

When I try that last line, patch throws an error:

patching file scsi_scan.c
Hunk #1 FAILED at 783.
1 out of 1 hunk FAILED -- saving rejects to file scsi_scan.c.rej

Regards,
- Robert

Revision history for this message
Ben Collins (ben-collins) wrote :

This patch will be added to the next -security update, and will eventually make it into the install CD's on the next point-release.

Changed in linux-source-2.6.15:
assignee: ben-collins → kyle
Revision history for this message
Kyle McMartin (kyle) wrote :

Applicable patch (must have whitespace change or something...) going into dapper-security tree now.

Patch is from Christoph Hellwig,

From: Christoph Hellwig <email address hidden>
Date: Fri, 17 Feb 2006 11:11:29 +0000 (+0100)
Subject: [SCSI] scsi: handle ->slave_configure return value
X-Git-Tag: v2.6.16^0~202^2~5
X-Git-Url: http://www.kernel.org/git/?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=938050916f57f08e20595b1fa1c1e57c2fbf7243

[SCSI] scsi: handle ->slave_configure return value

When ­>slave_configure fails the scsi midlayer should handle it.

Revision history for this message
Kyle McMartin (kyle) wrote :

Released in -security update.

Changed in linux-source-2.6.15:
status: Fix Committed → Fix Released
Changed in linux-restricted-modules-2.6.15:
status: New → Fix Committed
Changed in linux-source-2.6.15:
status: Fix Released → Fix Committed
Changed in linux-source-2.6.15:
status: Fix Committed → Fix Released
Changed in linux-restricted-modules-2.6.15:
status: Fix Committed → Fix Released
Revision history for this message
Marco Rodrigues (gothicx) wrote :

Sorry, I think it wasn't proposed...

Changed in linux-restricted-modules-2.6.15:
status: Fix Released → Invalid
Changed in linux-source-2.6.15:
status: Fix Released → Fix Committed
Revision history for this message
Marco Rodrigues (gothicx) wrote :

This was fixed on 2.6.15-28.51

Changed in linux-source-2.6.15:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.