if_bridge: unused 'disable' parameter in bridge_stop()
Aaron Espinoza <[email protected]> Thu, 11 Jun 2026 16:05:35 -0500
| Newsgroups | gmane.os.freebsd.devel.net |
|---|---|
| Message-ID | <CAM6_VK=Sh8mGO7zHHck=Q5K_ji-NCDc2prgYZXDSNJrqAF2fOw@mail.gmail.com> |
Hello, I was tracing the if_bridge driver on the current main branch and noticed that the bridge_stop method takes in an 'int disable' parameter that doesn't seem to be used in the function itself. Currently, there are two calls to bridge_stop() in the driver: 1. In bridge_clone_destroy() - Line 940 2. In bridge_ioctl() - Line 1073 In both of these calls, the disable parameter is hard-coded to 1. There doesn't seem to be any case where 0 is used for the parameter. Since the ifnet structure doesn't require a stop function, I assume this is purely for the bridge itself. Is this parameter still relevant/needed in the driver architecture? If not, I'd be happy to make a small pr to update this. I'm still finding my footing around the FreeBSD network stack so please let me know if this parameter has a purpose I overlooked. Best, Aaron