Bug 243056

Summary: smartpqi error and warning messages
Product: Base System Reporter: John F. Carr <jfc>
Component: kernAssignee: Mark Johnston <markj>
Status: Closed FIXED    
Severity: Affects Only Me CC: markj
Priority: ---    
Version: 12.1-RELEASE   
Hardware: amd64   
OS: Any   

Description John F. Carr 2020-01-03 13:23:33 UTC
Running on an HPE ProLiant DL325 Gen10 (AMD EPYC 7402P 24 core) I see an error from the smartpqi driver in dmesg output, "unrecognized PQI config table section ID: 0x5".  Looking at the source (smartpqi_init.c) the error message seems unnecessary.  The driver is looking for one specific config table section, not trying to parse them all.  Unrecognized sections are fine.

Also there is a "WARN" message for each connected device.  The DBG_WARN in pqisrc_add_device should be a DBG_INFO, which would disable the message in normal operation.  (See PQISRC_LOG_LEVEL in smartpqi_defines.h.)

Here is the relevant fragment of dmesg output

FreeBSD 12.1-RELEASE-p1 GENERIC amd64
[...]
acpi0: <HPE Server> on motherboard
[...]
pcib11: <ACPI Host-PCI bridge> numa-domain 0 on acpi0
pci11: <ACPI PCI bus> numa-domain 0 on pcib11
pci11: <base peripheral, IOMMU> at device 0.2 (no driver attached)
pcib12: <ACPI PCI-PCI bridge> at device 1.1 numa-domain 0 on pci11
pci12: <ACPI PCI bus> numa-domain 0 on pcib12
smartpqi0: <P408i-a SR Gen10> port 0x4000-0x40ff mem 0x90500000-0x90507fff at device 0.0 numa-domain 0 on pci12
smartpqi0: using MSI-X interrupts (48 vectors)
[ERROR]::[67:655.0][CPU 14][pqisrc_process_config_table][457]:unrecognized PQI config table section ID: 0x5
[WARN]:[67:655.0][CPU 14][pqisrc_add_device][1217]:vendor: HP      MM2000JEFRC      model: MM2000JEFRC      bus:0 target:64 lun:0 is_physical_device:0x1 expose_device:0x1 volume_offline 0x0 volume_status 0x0 
[WARN]:[67:655.0][CPU 14][pqisrc_add_device][1217]:vendor: HP      MM2000JEFRC      model: MM2000JEFRC      bus:0 target:65 lun:0 is_physical_device:0x1 expose_device:0x1 volume_offline 0x0 volume_status 0x0 
[WARN]:[67:655.0][CPU 14][pqisrc_add_device][1217]:vendor: HPE     Smart Adapter    model: Smart Adapter    bus:0 target:66 lun:0 is_physical_device:0x1 expose_device:0x1 volume_offline 0x0 volume_status 0x0 
[WARN]:[67:655.0][CPU 14][pqisrc_add_device][1217]:vendor: HPE     P408i-a SR Gen10 model: P408i-a SR Gen10 bus:2 target:1088 lun:0 is_physical_device:0x0 expose_device:0x1 volume_offline 0x0 volume_status 0x0
Comment 1 Mark Johnston freebsd_committer freebsd_triage 2020-01-03 17:22:07 UTC
I submitted a patch to the driver maintainer here: https://reviews.freebsd.org/D23023
Comment 2 commit-hook freebsd_committer freebsd_triage 2020-01-07 16:08:00 UTC
A commit references this bug:

Author: markj
Date: Tue Jan  7 16:07:31 UTC 2020
New revision: 356445
URL: https://svnweb.freebsd.org/changeset/base/356445

Log:
  Decrease logging severity when adding a device or reading config table.

  In PR 243056 a user reports some spam from smartpqi(4).  In particular,
  the driver warns about an unrecognized PQI_CONF_TABLE_SECTION_SOFT_RESET
  section (not yet defined in the driver, but handled in Linux), but this
  doesn't cause any problems.  The Linux driver also does not warn about
  unrecognized sections.

  Also do not log a warning when a device is added, since this is routine.
  Lower severity to DISC, to match pqisrc_remove_device().

  PR:		243056
  Reviewed by:	sbruno
  MFC after:	1 week
  Sponsored by:	The FreeBSD Foundation
  Differential Revision:	https://reviews.freebsd.org/D23023

Changes:
  head/sys/dev/smartpqi/smartpqi_discovery.c
  head/sys/dev/smartpqi/smartpqi_init.c
Comment 3 commit-hook freebsd_committer freebsd_triage 2020-01-14 02:44:45 UTC
A commit references this bug:

Author: markj
Date: Tue Jan 14 02:44:25 UTC 2020
New revision: 356719
URL: https://svnweb.freebsd.org/changeset/base/356719

Log:
  MFC r356445:
  Decrease logging severity when adding a device or reading config table.

  PR:	243056

Changes:
_U  stable/12/
  stable/12/sys/dev/smartpqi/smartpqi_discovery.c
  stable/12/sys/dev/smartpqi/smartpqi_init.c
Comment 4 Mark Johnston freebsd_committer freebsd_triage 2020-01-14 02:48:03 UTC
Fixed in stable/12.  Thank you for the report.