Discussion:
megaraid_sas: direct drive access for smartctl and hdparm
Jochen Radmacher
2008-05-07 14:11:37 UTC
Permalink
I was trying to get some useful SMART Information from the SATA drives
connected to my PERC5/i controller, but the PERC had no options for that.
When browsing through the kernel sources I found this:

static int megasas_slave_configure(struct scsi_device *sdev)
{
/*
* Don't export physical disk devices to the disk driver.
*
* FIXME: Currently we don't export them to the midlayer at all.
* That will be fixed once LSI engineers have audited the
* firmware for possible issues.
*/
if (sdev->channel < MEGASAS_MAX_PD_CHANNELS && sdev->type ==
TYPE_DISK)
return -ENXIO;


I changed the if{ } to:

if (sdev->channel < MEGASAS_MAX_PD_CHANNELS && sdev->type ==
TYPE_DISK)
{
sdev->writeable=1;
sdev->no_uld_attach=1;
return 0;
}


This way I get sgX devices (and no extra sdX devices), which work fine
with smartctl 5.37 and hdparm 8.4 . hdparm seems to need kernel 2.6.24
or greater for the pass through to work.

This only is a proof of concept and I have no idea how to implement this
correctly.
Regards,
Jochen Radmacher
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Rakesh
2008-05-09 23:01:59 UTC
Permalink
Post by Jochen Radmacher
I was trying to get some useful SMART Information from the SATA
drives connected to my PERC5/i controller, but the PERC had no
options for that.
I would say use the mptctl interface to do anything you would like to do with the physical members of the RAID device

Thanks,
Rakesh



____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Loading...