STRUCT DVB_FRONTEND_OPS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

okay so bestie, welcome to struct dvb_frontend_ops(9) from the Kernel API Manual β€” this is literally the demodulation info + callback blueprint for a DVB frontend, and it is lowkey iconic.

🌸 NAME 🌸

struct dvb_frontend_ops β€” Demodulation information and callbacks for ditialt TV. Yes, β€œditialt” is exactly what the original says, and we're keeping her πŸ’€πŸ’…

✨ SYNOPSIS ✨

okay so the struct itself is giving β€œone big vibe sheet with every callback you could ever need”:

struct dvb_frontend_ops {
    struct dvb_frontend_internal_info info;
    u8 delsys[MAX_DELSYS];
    void (*detach)(struct dvb_frontend *fe);
    void (*release)(struct dvb_frontend* fe);
    void (*release_sec)(struct dvb_frontend* fe);
    int (*init)(struct dvb_frontend* fe);
    int (*sleep)(struct dvb_frontend* fe);
    int (*suspend)(struct dvb_frontend *fe);
    int (*resume)(struct dvb_frontend *fe);
    int (*write)(struct dvb_frontend* fe, const u8 buf[], int len);
    int (*tune)(struct dvb_frontend* fe, bool re_tune, unsigned int
mode_flags, unsigned int *delay, enum fe_status *status);
    enum dvbfe_algo (*get_frontend_algo)(struct dvb_frontend *fe);
    int (*set_frontend)(struct dvb_frontend *fe);
    int (*get_tune_settings)(struct dvb_frontend* fe, struct
dvb_frontend_tune_settings* settings);
    int (*get_frontend)(struct dvb_frontend *fe, struct
dtv_frontend_properties *props);
    int (*read_status)(struct dvb_frontend *fe, enum fe_status *status);
    int (*read_ber)(struct dvb_frontend* fe, u32* ber);
    int (*read_signal_strength)(struct dvb_frontend* fe, u16* strength);
    int (*read_snr)(struct dvb_frontend* fe, u16* snr);
    int (*read_ucblocks)(struct dvb_frontend* fe, u32* ucblocks);
    int (*diseqc_reset_overload)(struct dvb_frontend* fe);
    int (*diseqc_send_master_cmd)(struct dvb_frontend* fe, struct
dvb_diseqc_master_cmd* cmd);
    int (*diseqc_recv_slave_reply)(struct dvb_frontend* fe, struct
dvb_diseqc_slave_reply* reply);
    int (*diseqc_send_burst)(struct dvb_frontend *fe, enum
fe_sec_mini_cmd minicmd);
    int (*set_tone)(struct dvb_frontend *fe, enum fe_sec_tone_mode
tone);
    int (*set_voltage)(struct dvb_frontend *fe, enum fe_sec_voltage
voltage);
    int (*enable_high_lnb_voltage)(struct dvb_frontend* fe, long arg);
    int (*dishnetwork_send_legacy_command)(struct dvb_frontend* fe,
unsigned long cmd);
    int (*i2c_gate_ctrl)(struct dvb_frontend* fe, int enable);
    int (*ts_bus_ctrl)(struct dvb_frontend* fe, int acquire);
    int (*set_lna)(struct dvb_frontend *);
    enum dvbfe_search (*search)(struct dvb_frontend *fe);
    struct dvb_tuner_ops tuner_ops;
    struct analog_demod_ops analog_ops;
 };

the vibe check: info is the embedded info bit, delsys is the delivery-system array, then it's callback city, plus tuner_ops and analog_ops at the end. let's go member by member, no skipping, periodt πŸ’–

πŸ’… Members πŸ’…

  • info β€” embedded struct dvb_tuner_info with tuner properties. cute little info core, slay.
  • delsys β€” Delivery systems supported by the frontend.
  • detach β€” callback function called when frontend is detached. drivers should clean up, but not yet free the struct dvb_frontend allocation.
  • release β€” callback function called when frontend is ready to be freed. drivers should free any allocated memory.
  • release_sec β€” callback function requesting that the Satellite Equipment Control (SEC) driver to release and free any memory allocated by the driver.
  • init β€” callback function used to initialize the tuner device.
  • sleep β€” callback function used to put the tuner to sleep.
  • suspend β€” callback function used to inform that the Kernel will suspend.
  • resume β€” callback function used to inform that the Kernel is resuming from suspend.
  • write β€” callback function used by some demod legacy drivers to allow other drivers to write data into their registers. Should not be used on new drivers.
  • tune β€” callback function used by demod drivers that use DVBFE_ALGO_HW to tune into a frequency.
  • get_frontend_algo β€” returns the desired hardware algorithm.
  • set_frontend β€” callback function used to inform the demod to set the parameters for demodulating a digital TV channel. The properties to be used are stored at struct dvb_frontend.dtv_property_cache. The demod can change the parameters to reflect the changes needed for the channel to be decoded, and update statistics.
  • get_tune_settings β€” callback function. that's it. that's the whole description. mysterious queen πŸ’…
  • get_frontend β€” callback function used to inform the parameters actuall in use. The properties to be used are stored at struct dvb_frontend.dtv_property_cache and update statistics. Please notice that it should not return an error code if the statistics are not available because the demog is not locked.
  • read_status β€” returns the locking status of the frontend.
  • read_ber β€” legacy callback function to return the bit error rate. Newer drivers should provide such info via DVBv5 API, e. g. set_frontend;/get_frontend, implementing this callback only if DVBv3 API compatibility is wanted.
  • read_signal_strength β€” legacy callback function to return the signal strength. Newer drivers should provide such info via DVBv5 API, e. g. set_frontend/get_frontend, implementing this callback only if DVBv3 API compatibility is wanted.
  • read_snr β€” legacy callback function to return the Signal/Noise rate. Newer drivers should provide such info via DVBv5 API, e. g. set_frontend/get_frontend, implementing this callback only if DVBv3 API compatibility is wanted.
  • read_ucblocks β€” legacy callback function to return the Uncorrected Error Blocks. Newer drivers should provide such info via DVBv5 API, e. g. set_frontend/get_frontend, implementing this callback only if DVBv3 API compatibility is wanted.
  • diseqc_reset_overload β€” callback function to implement the FE_DISEQC_RESET_OVERLOAD ioctl (only Satellite)
  • diseqc_send_master_cmd β€” callback function to implement the FE_DISEQC_SEND_MASTER_CMD ioctl (only Satellite).
  • diseqc_recv_slave_reply β€” callback function to implement the FE_DISEQC_RECV_SLAVE_REPLY ioctl (only Satellite)
  • diseqc_send_burst β€” callback function to implement the FE_DISEQC_SEND_BURST ioctl (only Satellite).
  • set_tone β€” callback function to implement the FE_SET_TONE ioctl (only Satellite).
  • set_voltage β€” callback function to implement the FE_SET_VOLTAGE ioctl (only Satellite).
  • enable_high_lnb_voltage β€” callback function to implement the FE_ENABLE_HIGH_LNB_VOLTAGE ioctl (only Satellite).
  • dishnetwork_send_legacy_command β€” callback function to implement the FE_DISHNETWORK_SEND_LEGACY_CMD ioctl (only Satellite). Drivers should not use this, except when the DVB core emulation fails to provide proper support (e.g. if set_voltage takes more than 8ms to work), and when backward compatibility with this legacy API is required.
  • i2c_gate_ctrl β€” controls the I2C gate. Newer drivers should use I2C mux support instead.
  • ts_bus_ctrl β€” callback function used to take control of the TS bus.
  • set_lna β€” callback function to power on/off/auto the LNA.
  • search β€” callback function used on some custom algo search algos.
  • tuner_ops β€” pointer to struct dvb_tuner_ops
  • analog_ops β€” pointer to struct analog_demod_ops

🌈 SEE ALSO 🌈

Kernel file: ./include/media/dvb_frontend.h β€” then go read these, bestie:


mwah πŸ’‹ source/version: ./include/media Β· date: October 2026. now go be the main character of frontend ops, bestie 🫢✨

πŸ“¦ where this page comes from