Bug 246885 - if_em: Add back LED device node (gone after iflib conversion)
Summary: if_em: Add back LED device node (gone after iflib conversion)
Status: In Progress
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-net (Nobody)
URL:
Keywords: IntelNetworking, regression
Depends on:
Blocks:
 
Reported: 2020-05-30 22:48 UTC by Jose Luis Duran
Modified: 2023-09-28 05:10 UTC (History)
3 users (show)

See Also:


Attachments
em.4: Remove non-applicable sections (3.13 KB, patch)
2020-08-29 00:21 UTC, Jose Luis Duran
no flags Details | Diff
Remove LED-related sections (1.25 KB, patch)
2020-08-29 01:09 UTC, Jose Luis Duran
no flags Details | Diff
Add back LED device node. (722 bytes, patch)
2021-05-16 06:42 UTC, Jose Luis Duran
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jose Luis Duran 2020-05-30 22:48:09 UTC
if_igb(4) describe some hw.igb tunables (rxd, txd, enable_aim, num_queues).  I guess these were gone after iflib conversion.

Another side effect, I am not able to control the LEDs via led(4).

Tested on 12.1-RELEASE, device river i211.

Reference: base r223676, base r228788.
Comment 1 Jose Luis Duran 2020-05-30 23:44:06 UTC
Additional references: review D8299
Comment 2 Jeff Pieper 2020-05-31 12:56:23 UTC
Please see https://www.freebsd.org/cgi/man.cgi?query=iflib&sektion=4&manpath=freebsd-release-ports for a list of iflib sysctl variables.
Comment 3 Jose Luis Duran 2020-05-31 13:08:07 UTC
(In reply to Jeff Pieper from comment #2)

Does it mean that the section "LOADER TUNABLES" from if_igb(4) manual should be removed?
Comment 4 Kevin Bowling freebsd_committer freebsd_triage 2020-08-28 23:40:35 UTC
(In reply to Jose Luis Duran from comment #3)
yes, can you submit a patch?
Comment 5 Jose Luis Duran 2020-08-29 00:21:21 UTC
Created attachment 217603 [details]
em.4: Remove non-applicable sections

Update manual to reflect current state.
Comment 6 Jose Luis Duran 2020-08-29 00:51:24 UTC
(In reply to Jose Luis Durhttps://bugs.freebsd.org/bugzilla/an from comment #5)

Wait... I think I have to create a separate igb.4/if_igb.4 man page (revert base r350075), because if_em do have these tunables.
Comment 7 Jose Luis Duran 2020-08-29 01:09:26 UTC
Created attachment 217604 [details]
Remove LED-related sections

Sorry, I was reading the on-line version of the man page and got confused.
Comment 8 Jose Luis Duran 2021-05-16 06:42:00 UTC
Created attachment 224987 [details]
Add back LED device node.

Add `iflib_led_create` late during `attach_post()` (don't know where else to put it).

I could not find any other device using `iflib_led_create` (I must be identifying NICs wrong).

Test plan:

    # echo f2 > /dev/led/em0

LEDs blink.

    # echo 0 > /dev/led/em0

LEDs stop blinking.
Comment 9 Kevin Bowling freebsd_committer freebsd_triage 2021-10-09 03:16:05 UTC
https://reviews.freebsd.org/D32389, requires https://reviews.freebsd.org/D32388