SF(4)

πŸ’– sf β€” the Adaptec AIC-6915 "Starfire" PCI Fast Ethernet adapter driver πŸ’–

okay bestie, buckle up, we're doing a Kernel Interfaces Manual deep dive and this one's giving vintage networking royalty. this is the page for sf, the driver for the Adaptec AIC-6915 "Starfire" PCI Fast Ethernet adapter. she's an icon, she's retired-ish, and we're gonna stan her properly. ✨


🌸 NAME 🌸

sf β€” the Adaptec AIC-6915 "Starfire" PCI Fast Ethernet adapter driver. that's the whole vibe. a driver. for a NIC. with a cute space name. πŸ’«


πŸŽ€ SYNOPSIS πŸŽ€

so if you wanna bake this driver into the kernel (no cap, some people do), you drop these lines into your kernel configuration file:

device miibus
device sf

OR β€” if you'd rather load it as a module at boot time like a normal person with places to be β€” put this line in loader.conf(5):

if_sf_load="YES"

two roads, one destination, and the destination is networking. πŸ›£οΈ


🚨 DEPRECATION NOTICE 🚨

bestie. listen. the sf driver is not present in FreeBSD 13.0 and later. she's gone. she has left the building.

if you need the receipts, they're right here: https://github.com/freebsd/fcp/blob/master/fcp-0101.md

not me getting emotional over a kernel module 😭 but here we are.


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the lore. the sf driver provides support for Adaptec Duralink Fast Ethernet adapters based on the Adaptec AIC-6915 "Starfire" chipset. the name alone? main character energy. ⭐πŸ”₯

the AIC-6915 is a bus master controller with an MII interface. and the way that she has range: she supports high and low priority transmit and receive queues, TCP/IP checksum offload, multiple DMA descriptor formats, AND both polling and producer/consumer DMA models. a multitasker. an overachiever. we love to see it. πŸ‘‘

her receive filtering options? also stacked:

  • a 16 entry perfect filter
  • a 512-bit hash table for multicast addresses
  • a 512-bit hash table for priority address matching
  • and VLAN filtering

and heads up β€” an external MII-compliant transceiver is required for media interfacing. she doesn't do that part herself, she outsources. respect. 🫢

multiport adapters, btw, are literally just several AIC-6915 controllers connected via a PCI to PCI bridge, and each controller gets treated as a separate interface by the sf driver. more controllers, more interfaces, more chaos, more fun. 🌈

the sf driver supports the following media types:

  • autoselect β€” enables autoselection of the media type and options. the user can manually override the autoselected mode by adding media options to the /etc/rc.conf file. she picks for you, but you can step in. girlboss autonomy. πŸ’…
  • 10baseT/UTP β€” sets 10Mbps operation. the mediaopt option can also be used to select either full-duplex or half-duplex modes.
  • 100baseTX β€” sets 100Mbps (Fast Ethernet) operation. the mediaopt option can also be used to select either full-duplex or half-duplex modes.

and the media options she supports:

  • full-duplex β€” force full duplex operation.
  • half-duplex β€” force half duplex operation.

for more info on configuring this device, see ifconfig(8). go read it, i'll wait. πŸ“–


πŸ”₯ HARDWARE πŸ”₯

the adapters that the sf driver plays nice with include:

  • ANA-62011 64-bit single port 10/100baseTX adapter
  • ANA-62022 64-bit dual port 10/100baseTX adapter
  • ANA-62044 64-bit quad port 10/100baseTX adapter
  • ANA-69011 32-bit single port 10/100baseTX adapter
  • ANA-62020 64-bit single port 100baseFX adapter

five queens. all iconic. all built different. πŸ‘‘πŸ‘‘πŸ‘‘πŸ‘‘πŸ‘‘


βš™οΈ SYSCTL VARIABLES βš™οΈ

these variables are available as both sysctl(8) variables AND loader(8) tunables. double duty, no complaints:

  • dev.sf.%d.int_mod β€” maximum amount of time to delay interrupt processing, in units of 102.4us. the accepted range is 0 to 31, and the default value is 1 (that's 102.4us, for the record). value 0 completely disables the interrupt moderation. and the best part? the interface does not need to be brought down and up again before a change takes effect. live updates, we love a low-maintenance queen. ✨
  • dev.sf.%d.stats β€” displays lots of useful MAC counters maintained in the driver. numbers! stats! data! the nerd in me is thriving. πŸ“

πŸ’€ DIAGNOSTICS πŸ’€

the messages she might throw at you, and what they mean:

  • sf%d: couldn't map memory β€” a fatal initialization error has occurred. this may happen if the PCI BIOS did not configure the device, which may be because the BIOS has been configured for a "Plug and Play" operating system. the "Plug and Play OS" setting in the BIOS should be set to "no" or "off" in order for PCI devices to work properly with FreeBSD. πŸ™ˆ
  • sf%d: couldn't map ports β€” a fatal initialization error has occurred. this may happen if the PCI BIOS did not configure the device, which may be because the BIOS has been configured for a "Plug and Play" operating system. the "Plug and Play OS" setting in the BIOS should be set to "no" or "off" in order for PCI devices to work properly with FreeBSD.
  • sf%d: couldn't map interrupt β€” a fatal initialization error has occurred.
  • sf%d: no memory for softc struct! β€” the driver failed to allocate memory for per-device instance information during initialization.
  • sf%d: failed to enable I/O ports/memory mapping! β€” the driver failed to initialize PCI I/O port or shared memory access. this might happen if the card is not in a bus-master slot.
  • sf%d: watchdog timeout β€” the device has stopped responding to the network, or there is a problem with the network connection (cable). check ya cable, bestie. πŸ”Œ
ngl the "couldn't map memory" and "couldn't map ports" twins are giving "same error, different font." if you see them, go fix that BIOS setting. fr fr.

🌈 SEE ALSO 🌈

altq(4), arp(4), miibus(4), netintro(4), ng_ether(4), polling(4), vlan(4), ifconfig(8)

and also β€” The Adaptec AIC-6915 Programmer's Manual, at http://download.adaptec.com/pdfs/user_guides/aic6915_pg.pdf. go read the source material, iykyk. πŸ“š


🧚 HISTORY 🧚

the sf device driver first appeared in FreeBSD 3.0. a true OG. she's been around. she's seen things. πŸ•°οΈ


πŸ’œ AUTHORS πŸ’œ

the sf driver was written by Bill Paul <wpaul@ctr.columbia.edu>. thank you Bill, king behavior, we appreciate you. πŸ™βœ¨


and that's the whole page bestie, every flag, every counter, every dramatic BIOS warning, untouched and accounted for. mwah. πŸ’‹

this lil rewrite came to you courtesy of the Debian crew, dated October 24, 2018, and filed under SF(4) in the Kernel Interfaces Manual. take care of her, she's deprecated but she's ours. πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from