STRUCT TI_SCI_MSG_REQ_SET_CLOCK_FREQ(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct ti_sci_msg_req_set_clock_freq(9) β€” Kernel API Manual ✨

okay so bestie, we’re in the Kernel API Manual and this page is all about the Request to setup a clock frequency struct. it’s giving very specific firmware behavior and we’re gonna get into every field, no skips πŸ’–


πŸ’– NAME πŸ’–

struct ti_sci_msg_req_set_clock_freq β€” the Request to setup a clock frequency struct. periodt.


✨ SYNOPSIS ✨

here’s the exact shape, no cap:

struct ti_sci_msg_req_set_clock_freq {
    struct ti_sci_msg_hdr hdr;
    u32 dev_id;
    u64 min_freq_hz;
    u64 target_freq_hz;
    u64 max_freq_hz;
    u8 clk_id;
    u32 clk_id_32;
 };

πŸŽ€ Members πŸŽ€

  • hdr β€” Generic Header 🫢
  • dev_id β€” the Device identifier this request is for πŸ’«
  • min_freq_hz β€” the minimum allowable frequency in Hz. like, this is the minimum allowable programmed frequency, and it does not account for clock tolerances and jitter. important bestie πŸŽ€
  • target_freq_hz β€” the target clock frequency. the clock will be programmed at a rate as close to this target frequency as possible. iconic behavior fr fr ⭐
  • max_freq_hz β€” the maximum allowable frequency in Hz. this is the maximum allowable programmed frequency, and it does not account for clock tolerances and jitter. same energy as min_freq_hz, just the ceiling πŸ¦‹
  • clk_id β€” Clock identifier for the device for this request. Set to 255 if clock ID is greater than or equal to 255. iykyk πŸ‘‘
  • clk_id_32 β€” Clock identifier if clk_id field is set to 255. the backup field ate πŸ’…

🌸 NOTE 🌸

so normally, clock frequency management is automatically done by the TISCI entity. but for specific requests, TISCI evaluates capability to achieve the requested range and responds with a success/failure message. lowkey very responsible of it πŸ’œ

this sets the desired frequency for a clock within an allowable range.

⚠️ warning vibe: this message will fail on an enabled clock unless MSG_FLAG_CLOCK_ALLOW_FREQ_CHANGE is set for the clock. additionally, if other clocks have their frequency modified due to this message, they also must have the MSG_FLAG_CLOCK_ALLOW_FREQ_CHANGE or be disabled. not me being dramatic, that’s just the rule 😭

calling set frequency on a clock input to the SoC pseudo-device will inform the PMMC of that clock’s frequency. setting a frequency of zero will indicate the clock is disabled. zero = off, got it 🫢

calling set frequency on clock outputs from the SoC pseudo-device will function similarly to setting the clock frequency on a device. same vibe, different direction πŸ’«

request type is TI_SCI_MSG_SET_CLOCK_FREQ, response is a generic ACK/NACK message. that’s the whole handshake, bestie 🀝


πŸ’« SEE ALSO πŸ’«

  • Kernel file ./drivers/firmware/ti_sci.h πŸ¦‹
  • struct ti_sci_msg_hdr(9)
  • struct ti_sci_msg_resp_version(9)
  • struct ti_sci_msg_req_reboot(9)
  • struct ti_sci_msg_resp_query_fw_caps(9)
  • struct ti_sci_msg_req_set_device_state(9)
  • struct ti_sci_msg_req_get_device_state(9)
  • struct ti_sci_msg_resp_get_device_state(9)
  • struct ti_sci_msg_req_set_device_resets(9)
  • struct ti_sci_msg_req_set_clock_state(9)
  • struct ti_sci_msg_req_get_clock_state(9)
  • struct ti_sci_msg_resp_get_clock_state(9)
  • struct ti_sci_msg_req_set_clock_parent(9)
  • struct ti_sci_msg_req_get_clock_parent(9)
  • struct ti_sci_msg_resp_get_clock_parent(9)
  • struct ti_sci_msg_req_get_clock_num_parents(9)
  • struct ti_sci_msg_resp_get_clock_num_parents(9)
  • struct ti_sci_msg_req_query_clock_freq(9)
  • struct ti_sci_msg_resp_query_clock_freq(9)
  • struct ti_sci_msg_req_get_clock_freq(9)
  • struct ti_sci_msg_resp_get_clock_freq(9)
  • struct ti_sci_msg_req_prepare_sleep(9)
  • struct ti_sci_msg_req_set_io_isolation(9)
  • struct ti_sci_msg_resp_lpm_wake_reason(9)
  • struct ti_sci_msg_req_lpm_set_device_constraint(9)
  • struct ti_sci_msg_req_lpm_set_latency_constraint(9)
  • struct ti_sci_msg_req_get_resource_range(9)
  • struct ti_sci_msg_resp_get_resource_range(9)
  • struct ti_sci_msg_req_manage_irq(9)
  • struct ti_sci_msg_rm_ring_cfg_req(9)
  • struct ti_sci_msg_psil_pair(9)
  • struct ti_sci_msg_psil_unpair(9)
  • struct ti_sci_msg_udmap_rx_flow_cfg(9)
  • struct rm_ti_sci_msg_udmap_rx_flow_opt_cfg(9)
  • struct ti_sci_msg_rm_udmap_tx_ch_cfg_req(9)
  • struct ti_sci_msg_rm_udmap_rx_ch_cfg_req(9)
  • struct ti_sci_msg_rm_udmap_flow_cfg_req(9)
  • struct ti_sci_msg_req_proc_request(9)
  • struct ti_sci_msg_req_proc_release(9)
  • struct ti_sci_msg_req_proc_handover(9)
  • struct ti_sci_msg_req_set_config(9)
  • struct ti_sci_msg_req_set_ctrl(9)
  • struct ti_sci_msg_req_get_status(9)
  • struct ti_sci_msg_resp_get_status(9)

okay bestie that’s the whole page πŸ’œ source/version is ./drivers/firmware, date is October 2026, and the footer vibe is struct ti_sc...t_clock_freq(9) β€” bye! 🫢✨

πŸ“¦ where this page comes from