THE RANT / THE SCHPLOG
Schmorp's POD Blog a.k.a. THE RANT
a.k.a. the blog that cannot decide on a name

This document was first published 2018-01-25 21:58:57, and last modified 2018-01-25 21:58:57.

Changing the PCI IDs on LSI 2008/2108-based MegaRAID controllers

There are a multitude of tutorials on how to cross-flash LSI 2108 or older controllers between Dell/IBM/Intel/LSI/etc firmwares (for example here).

Unfortunately, some newer firmwares check the the SBR file ("serial boot record") at boot, and when there is a mismatch, they revert to the previous firmware or firmware mode, telling you so in the termlog. For example, a Dell PERC H700 (sub vendor ID 1f17) firmware booting on a LSI 9261 card might revert the boot record to the LSI ID:

T96: Raw SBR Image data:
T96: MFC PNP-ids [Ven: 1000, Dev: 79, SubVen: 1028, SubDev: 1f17] NOT matching with
T96: SBR PNP-ids [Ven: 1000, Dev: 79, SubVen: 1000, SubDev: 9261]
T96: SBR PNP-ids updated from MFC. Rebooting the controller...

To permantly change the PCI ID, one must (instead of or in addition to writing the matching SBR file) change the PCI data. Googling didn't really turn up a way to do this, so I had to invest a modicum of reverse engineering skills (mostly running strings on the various megaxxx commands) to find out you can use the MegaSCU command (google can find a copy for you) to change the PCI ID:

MegaSCU -AdpFactorySettings -SetPCIData -f pci.ini -a0

All you need is a magic pci.ini, such as this one, for an LSI 9260-8i:

[GEN2_INI_FILE]
[PCIDATA]
VENDORID=1000
DEVICEID=0079
SUBVENDORID=1000
SUBDEVICEID=9261

Other SUBVENDORID/SUBDEVICEID combinations can be found in your pci.ids file, also for other chips than the LSI 2108. Here are some examples:

1000 9260  MegaRAID SAS 9260-4i
1000 9261  MegaRAID SAS 9260-8i
1000 9267  MegaRAID SAS 9260CV-4i
1000 9268  MegaRAID SAS 9260CV-8i
1000 9280  MegaRAID SAS 9280-8e
1014 03b2  ServeRAID M5015 SAS/SATA Controller
1014 03b3  ServeRAID M5025 SAS/SATA Controller
1028 1f15  PERC H800 Adapter
1028 1f16  PERC H700 Adapter
1028 1f17  PERC H700 Integrated
1028 1f18  PERC H700 Modular
1043 8480  PIKE-2108 16PD
1734 1176  RAID Ctrl SAS 6G 5/6 512MB (D2616)
1734 1177  RAID Ctrl SAS 6G 0/1 (D2607)
8086 350b  RMS2MH080 RAID Controller
8086 9260  RAID Controller RS2BL040
8086 9261  RAID Controller RS2BL080

The AdpFactorySettings subcommand of MegaSCU has other modes than than SetPCIData as well, probably with something like the following (I haven't tried any of this - if you do, and find out what to supply and what it does, publish it and send me a link):

MegaSCU -AdpFactorySettings -SetSasAddress:

[GEN2_INI_FILE]
[SASADDR]
sasAddress=

MegaSCU -AdpFactorySettings -SetMfgData:

[GEN2_INI_FILE]
[MFGDATA]
SERIALNUMBER=
REVISIONNUMBER=
MFGDATE=
REWORKDATE=
BATTERYFRU=
MEMORYMODULEFRU=

MegaSCU -AdpFactorySettings -SetMfcData:

[GEN2_INI_FILE]
[MFCDATA]
CLUSTERDISABLE=
DISABLESAS=
MAXDISKS=
ENABLERAID6=
DISABLEWIDECACHE=
DISABLERAID5=
ENABLESECURITY=
SUBOEM=
ENABLECTIO=
ENABLESNAPSHOT=
ENABLESSC=
ENABLEREDUCEDFEATURESET=
ENABLECACHEOFFLOAD=
ENABLESSCWB=
ISRAIDKEYSECONDARY=

Links appreciated

If this information was helpful to you and you published something based on this, consider dropping me a note so I can link to it from here.