Bug 238265 - Unable to link kernel: sybmol not found
Summary: Unable to link kernel: sybmol not found
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: John Baldwin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-05-31 15:17 UTC by Eir Nym
Modified: 2019-06-06 20:51 UTC (History)
2 users (show)

See Also:


Attachments
Log output (rerun) (71.66 KB, patch)
2019-05-31 15:17 UTC, Eir Nym
no flags Details | Diff
kernel config (25.22 KB, text/plain)
2019-05-31 15:19 UTC, Eir Nym
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eir Nym 2019-05-31 15:17:55 UTC
Created attachment 204744 [details]
Log output (rerun)

eee attached files for log and kernel config
Comment 1 Eir Nym 2019-05-31 15:19:08 UTC
Created attachment 204745 [details]
kernel config
Comment 2 Eir Nym 2019-05-31 15:21:15 UTC
scc.conf and src-env.conf will be attached if needed
Comment 3 Conrad Meyer freebsd_committer freebsd_triage 2019-06-01 01:24:17 UTC
Salient part:

linking kernel
ld: error: undefined symbol: t4_register_cpl_handler
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_modevent)

ld: error: undefined symbol: t4_register_cpl_handler
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_modevent)

ld: error: undefined symbol: M_CXGBE
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: M_CXGBE
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: M_CXGBE
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: t4_wrq_tx_locked
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: t4_wrq_tx_locked
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: t4_wrq_tx_locked
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: M_CXGBE
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: t4_wrq_tx_locked
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_process)

ld: error: undefined symbol: t4_aes_getdeckey
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_aes_setkey)

ld: error: undefined symbol: M_CXGBE
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_hash)

ld: error: undefined symbol: t4_wrq_tx_locked
>>> referenced by t4_crypto.c
>>>               t4_crypto.o:(ccr_hash)
*** [kernel] Error code 1
Comment 4 Conrad Meyer freebsd_committer freebsd_triage 2019-06-01 01:25:44 UTC
Kernel config includes 'device         ccr' but not 'device cxgbe', which is probably invalid.
Comment 5 Conrad Meyer freebsd_committer freebsd_triage 2019-06-01 01:28:09 UTC
I guess another solution would be to changes 'optional ccr' to 'optional ccr cxgbe' in conf/files t4_crypto.c line, but that just silently "succeeds" when ccr is set and cxgbe is not set, when failure seems more desirable.  3rd option would be to make all the 'optional cxgbe' files 'optional cxgbe | ccr', which looks a bit odd, but would make this config "work."

Short term fix is to add 'device cxgbe' to your configuration if you want ccr.
Comment 6 John Baldwin freebsd_committer freebsd_triage 2019-06-03 15:33:57 UTC
ccr depends on cxgbe both at link time and at runtime (ccr0 devices are children of the t6nex devices created by 'device cxgbe').  I can add 'device cxgbe' in the synopsis of the manpage though.  The manpage does mention the runtime dependency, but it currently only lists 'device ccr'.
Comment 7 commit-hook freebsd_committer freebsd_triage 2019-06-03 15:42:47 UTC
A commit references this bug:

Author: jhb
Date: Mon Jun  3 15:41:55 UTC 2019
New revision: 348542
URL: https://svnweb.freebsd.org/changeset/base/348542

Log:
  Add 'device cxgbe' explicitly in the synopsis.

  ccr depends on symbols exported by the cxgbe driver as well as having
  a runtime dependency.  While the runtime depenency was noted in the
  manpage already, the compile-time dependency wasn't as clear.

  PR:		238265
  MFC after:	3 days
  Sponsored by:	Chelsio Communications

Changes:
  head/share/man/man4/ccr.4
Comment 8 commit-hook freebsd_committer freebsd_triage 2019-06-06 20:04:01 UTC
A commit references this bug:

Author: jhb
Date: Thu Jun  6 20:03:23 UTC 2019
New revision: 348755
URL: https://svnweb.freebsd.org/changeset/base/348755

Log:
  MFC 348542: Add 'device cxgbe' explicitly in the synopsis.

  ccr depends on symbols exported by the cxgbe driver as well as having
  a runtime dependency.  While the runtime depenency was noted in the
  manpage already, the compile-time dependency wasn't as clear.

  PR:		238265

Changes:
_U  stable/12/
  stable/12/share/man/man4/ccr.4
Comment 9 commit-hook freebsd_committer freebsd_triage 2019-06-06 20:04:04 UTC
A commit references this bug:

Author: jhb
Date: Thu Jun  6 20:03:55 UTC 2019
New revision: 348756
URL: https://svnweb.freebsd.org/changeset/base/348756

Log:
  MFC 348542: Add 'device cxgbe' explicitly in the synopsis.

  ccr depends on symbols exported by the cxgbe driver as well as having
  a runtime dependency.  While the runtime depenency was noted in the
  manpage already, the compile-time dependency wasn't as clear.

  PR:		238265
  Approved by:	re (gjb)

Changes:
_U  stable/11/
  stable/11/share/man/man4/ccr.4