ENUM MEDIA_REQUEST_STATE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– enum media_request_state(9) πŸ’–

okay so bestie, welcome to the Kernel API Manual ✨ today's main character is enum media_request_state β€” literally the whole vibe-check system for media requests. it's giving "state machine but make it cute" πŸ¦‹


🌸 SYNOPSIS 🌸

here's the whole squad, in order, exactly as they live in the header:

enum media_request_state {
    MEDIA_REQUEST_STATE_IDLE ,
    MEDIA_REQUEST_STATE_VALIDATING ,
    MEDIA_REQUEST_STATE_QUEUED ,
    MEDIA_REQUEST_STATE_COMPLETE ,
    MEDIA_REQUEST_STATE_CLEANING ,
    MEDIA_REQUEST_STATE_UPDATING ,
    NR_OF_MEDIA_REQUEST_STATE

};

πŸŽ€ CONSTANTS πŸŽ€

these are the states, and yes, every single one of them matters πŸ‘‘

  • MEDIA_REQUEST_STATE_IDLE β€” the request is just... idle. chilling. doing nothing, living its best life πŸ’…
  • MEDIA_REQUEST_STATE_VALIDATING β€” it's validating the request rn, and ngl: no state changes allowed while this is happening. periodt. 🚫
  • MEDIA_REQUEST_STATE_QUEUED β€” queued, babes. it's in line, waiting its turn 🫢
  • MEDIA_REQUEST_STATE_COMPLETE β€” completed! the request is done, it ate and left no crumbs ✨
  • MEDIA_REQUEST_STATE_CLEANING β€” cleaning era 🧹 the request is being re-inited, gotta reset before the next round
  • MEDIA_REQUEST_STATE_UPDATING β€” the request is being updated, i.e. request objects are being added, modified or removed. lowkey the busiest state fr fr πŸ”₯
  • NR_OF_MEDIA_REQUEST_STATE β€” the number of media request states. it's used internally for sanity check purposes, so it's not really a state, it's the count πŸ‘€ a little icon, a little legend
real talk: that VALIDATING one is the one to remember β€” no state changes allowed there. not a drill πŸ’€

🌈 SEE ALSO 🌈

if you're obsessed (and you should be), go read these next. full list, no skips:

Kernel file ./include/media/media-request.h, plus struct media_request(9), media_request_lock_for_access(9), media_request_unlock_for_access(9), media_request_lock_for_update(9), media_request_unlock_for_update(9), media_request_get(9), media_request_put(9), media_request_get_by_fd(9), media_request_alloc(9), media_request_mark_manual_completion(9), media_request_manual_complete(9), struct media_request_object_ops(9), struct media_request_object(9), media_request_object_get(9), media_request_object_put(9), media_request_object_find(9), media_request_object_init(9), media_request_object_bind(9), media_request_object_unbind(9), media_request_object_complete(9) πŸ’œ


that's the whole page, bestie πŸŽ€ this one came from ./include/media, dated October 2026, and it's filed under the Kernel API Manual β€” go forth and state-machine responsibly πŸ§šπŸ’–

πŸ“¦ where this page comes from