Project

General

Profile

Actions

Bug #14983

open

Panic in cfg_offset != 0xffffffff assertion in smrt:smrt_locate_cfgtbl

Added by Albert Lee 8 days ago. Updated 8 days ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
driver - device drivers
Start date:
Due date:
% Done:

0%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:
External Bug:

Description

I recently installed an HP H240 in a non-HP Ivy Bridge system (Dell T20). The card is configured for HBA mode (analogous to LSI's IT mode) using the HPE SSA.

Sometimes, the card's option ROM is not executed by the BIOS until the system is hard power cycled. Without the option ROM, the HBA is likely unusable as at least some of the BARs are not set up.

When smrt attaches while the H240 is in this state, we panic in smrt_locate_cfgtbl:

panic[cpu1]/thread=fffffe16d38afb40: 
assertion failed: cfg_offset != 0xffffffff (0xffffffff != 0xffffffff), file: ../../common/io/scsi/adapters/smrt/smrt_device.c, line: 55

fffffe001f8ef120 fffffffffba4a3e1 ()
fffffe001f8ef1b0 smrt:smrt_locate_cfgtbl+122 ()
fffffe001f8ef220 smrt:smrt_map_device+ea ()
fffffe001f8ef250 smrt:smrt_device_setup+33 ()
fffffe001f8ef2f0 smrt:smrt_attach+155 ()
fffffe001f8ef360 genunix:devi_attach+b1 ()
fffffe001f8ef3a0 genunix:attach_node+8b ()
fffffe001f8ef3f0 genunix:i_ndi_config_node+118 ()
fffffe001f8ef420 genunix:i_ddi_attachchild+3e ()
fffffe001f8ef460 genunix:devi_attach_node+64 ()
fffffe001f8ef540 genunix:devi_config_one+3cb ()
fffffe001f8ef5c0 genunix:ndi_devi_config_one+ac ()
fffffe001f8ef690 devfs:dv_find+4b3 ()
fffffe001f8ef6e0 devfs:devfs_lookup+37 ()
fffffe001f8ef790 genunix:fop_lookup+aa ()
fffffe001f8ef9d0 genunix:lookuppnvp+2d8 ()
fffffe001f8efa70 genunix:lookuppnatcred+113 ()
fffffe001f8efb70 genunix:lookupnameatcred+11b ()
fffffe001f8efbc0 genunix:lookupnameat+39 ()
fffffe001f8efd70 genunix:vn_openat+2c6 ()
fffffe001f8efed0 genunix:copen+170 ()
fffffe001f8eff00 genunix:openat+39 ()

This creates a panic loop, as the problem with the option ROM does not resolve itself without a hard power cycle. It may be more desirable to fail the attach instead.

Actions #1

Updated by Joshua M. Clulow 8 days ago

Yeah, sorry about that. There are two VERIFYs in that function that could easily be relaxed to a comparison with PCI_EINVAL32 and an early failure return, and possibly an FMA ereport. There are likely other places in the driver that could receive a similar treatment too.

Actions

Also available in: Atom PDF