Lines Matching full:bridge
48 * @DRM_BRIDGE_ATTACH_NO_CONNECTOR: When this flag is set the bridge
61 * This callback is invoked whenever our bridge is being attached to a
71 int (*attach)(struct drm_bridge *bridge,
77 * This callback is invoked whenever our bridge is being detached from a
82 void (*detach)(struct drm_bridge *bridge);
88 * bridge. This should be implemented if the bridge has some sort of
89 * restriction in the modes it can display. For example, a given bridge
115 enum drm_mode_status (*mode_valid)(struct drm_bridge *bridge,
125 * &drm_bridge. The parameter adjusted_mode is the input mode the bridge
129 * This is the only hook that allows a bridge to reject a modeset. If
148 * that modes are filtered consistently put any bridge constraints and
156 bool (*mode_fixup)(struct drm_bridge *bridge,
162 * This callback should disable the bridge. It is called right before
164 * preceding element is a bridge this means it's called before that
165 * bridge's @disable vfunc. If the preceding element is a &drm_encoder
170 * The bridge can assume that the display pipe (i.e. clocks and timing
180 void (*disable)(struct drm_bridge *bridge);
185 * This callback should disable the bridge. It is called right after the
187 * element is a bridge this means it's called after that bridge's
193 * The bridge must assume that the display pipe (i.e. clocks and timing
204 void (*post_disable)(struct drm_bridge *bridge);
209 * This callback should set the given mode on the bridge. It is called
211 * pipeline has been called already. If the bridge is the first element
217 * first bridge in the chain. It can be different from the mode
219 * of the bridges chain, for instance when the first bridge in the chain
221 * bridge in the chain and is likely irrelevant for the other bridges.
232 void (*mode_set)(struct drm_bridge *bridge,
238 * This callback should enable the bridge. It is called right before
240 * preceding element is a bridge this means it's called before that
241 * bridge's @pre_enable function. If the preceding element is a
246 * The display pipe (i.e. clocks and timing signals) feeding this bridge
247 * will not yet be running when this callback is called. The bridge must
248 * not enable the display link feeding the next bridge in the chain (if
258 void (*pre_enable)(struct drm_bridge *bridge);
263 * This callback should enable the bridge. It is called right after
265 * preceding element is a bridge this means it's called after that
266 * bridge's @enable function. If the preceding element is a
271 * The bridge can assume that the display pipe (i.e. clocks and timing
273 * callback must enable the display link feeding the next bridge in the
283 void (*enable)(struct drm_bridge *bridge);
288 * This callback should enable the bridge. It is called right before
290 * preceding element is a bridge this means it's called before that
291 * bridge's @atomic_pre_enable or @pre_enable function. If the preceding
295 * The display pipe (i.e. clocks and timing signals) feeding this bridge
296 * will not yet be running when this callback is called. The bridge must
297 * not enable the display link feeding the next bridge in the chain (if
308 void (*atomic_pre_enable)(struct drm_bridge *bridge,
314 * This callback should enable the bridge. It is called right after
316 * preceding element is a bridge this means it's called after that
317 * bridge's @atomic_enable or @enable function. If the preceding element
321 * The bridge can assume that the display pipe (i.e. clocks and timing
323 * callback must enable the display link feeding the next bridge in the
333 void (*atomic_enable)(struct drm_bridge *bridge,
338 * This callback should disable the bridge. It is called right before
340 * preceding element is a bridge this means it's called before that
341 * bridge's @atomic_disable or @disable vfunc. If the preceding element
345 * The bridge can assume that the display pipe (i.e. clocks and timing
356 void (*atomic_disable)(struct drm_bridge *bridge,
362 * This callback should disable the bridge. It is called right after the
364 * element is a bridge this means it's called after that bridge's
369 * The bridge must assume that the display pipe (i.e. clocks and timing
382 void (*atomic_post_disable)(struct drm_bridge *bridge,
388 * Duplicate the current bridge state object (which is guaranteed to be
391 * The atomic_duplicate_state hook is mandatory if the bridge
400 struct drm_bridge_state *(*atomic_duplicate_state)(struct drm_bridge *bridge);
405 * Destroy a bridge state object previously allocated by
408 * The atomic_destroy_state hook is mandatory if the bridge implements
414 void (*atomic_destroy_state)(struct drm_bridge *bridge,
420 * Return the supported bus formats on the output end of a bridge.
428 * This method is only called on the last element of the bridge chain
436 u32 *(*atomic_get_output_bus_fmts)(struct drm_bridge *bridge,
445 * Return the supported bus formats on the input end of a bridge for
456 * This method is called on all elements of the bridge chain as part of
460 * bus format negotiation on this element of the bridge without
464 * Bridge drivers that need to support being linked to bridges that are
470 * Note: Even if input format selection on the first bridge has no
476 u32 *(*atomic_get_input_bus_fmts)(struct drm_bridge *bridge,
486 * This method is responsible for checking bridge state correctness.
491 * order (from the last to the first bridge).
500 * field is set to the next bridge
502 * &drm_connector.display_info.bus_flags if the bridge is the last
508 int (*atomic_check)(struct drm_bridge *bridge,
516 * Reset the bridge to a predefined state (or retrieve its current
520 * The atomic_reset hook is mandatory if the bridge implements any of
529 * 1. The reset operation happens when the bridge is attached, not when
538 struct drm_bridge_state *(*atomic_reset)(struct drm_bridge *bridge);
543 * Check if anything is attached to the bridge output.
545 * This callback is optional, if not implemented the bridge will be
552 * drm_connector_status indicating the bridge output status.
554 enum drm_connector_status (*detect)(struct drm_bridge *bridge);
571 * filling modes, and shall not be stored internally by bridge drivers
578 int (*get_modes)(struct drm_bridge *bridge,
587 * information for a display connected to the bridge output. Bridges
599 * retrieval and parsing, and shall not be stored internally by bridge
608 struct edid *(*get_edid)(struct drm_bridge *bridge,
614 * Notify the bridge of hot plug detection.
621 void (*hpd_notify)(struct drm_bridge *bridge,
627 * Enable hot plug detection. From now on the bridge shall call
637 void (*hpd_enable)(struct drm_bridge *bridge);
642 * Disable hot plug detection. Once this function returns the bridge
651 void (*hpd_disable)(struct drm_bridge *bridge);
656 * Allows bridges to create bridge-specific debugfs files.
658 void (*debugfs_init)(struct drm_bridge *bridge, struct dentry *root);
662 * struct drm_bridge_timings - timing information for the bridge
669 * this bridge requires (like pixel signal polarity). See also
683 * Defines the time in picoseconds taken for the bridge to sample the
698 * enum drm_bridge_ops - Bitmask of operations supported by the bridge
702 * @DRM_BRIDGE_OP_DETECT: The bridge can detect displays connected to
708 * @DRM_BRIDGE_OP_EDID: The bridge can retrieve the EDID of the display
714 * @DRM_BRIDGE_OP_HPD: The bridge can detect hot-plug and hot-unplug
722 * @DRM_BRIDGE_OP_MODES: The bridge can retrieve the modes supported
731 * struct drm_bridge - central DRM bridge control structure
736 /** @dev: DRM device this bridge belongs to */
738 /** @encoder: encoder to which this bridge is connected */
740 /** @chain_node: used to form a bridge chain */
743 /** @of_node: device node pointer to the bridge */
751 * the timing specification for the bridge, if any (may be NULL)
756 /** @driver_private: pointer to the bridge driver's internal context */
758 /** @ops: bitmask of operations supported by the bridge */
761 * @type: Type of the connection at the bridge output
767 * @interlace_allowed: Indicate that the bridge can handle interlaced
798 void drm_bridge_add(struct drm_bridge *bridge);
799 int devm_drm_bridge_add(struct device *dev, struct drm_bridge *bridge);
800 void drm_bridge_remove(struct drm_bridge *bridge);
801 int drm_bridge_attach(struct drm_encoder *encoder, struct drm_bridge *bridge,
815 * drm_bridge_get_next_bridge() - Get the next bridge in the chain
816 * @bridge: bridge object
819 * the next bridge in the chain after @bridge, or NULL if @bridge is the last.
822 drm_bridge_get_next_bridge(struct drm_bridge *bridge) in drm_bridge_get_next_bridge() argument
824 if (list_is_last(&bridge->chain_node, &bridge->encoder->bridge_chain)) in drm_bridge_get_next_bridge()
827 return list_next_entry(bridge, chain_node); in drm_bridge_get_next_bridge()
831 * drm_bridge_get_prev_bridge() - Get the previous bridge in the chain
832 * @bridge: bridge object
835 * the previous bridge in the chain, or NULL if @bridge is the first.
838 drm_bridge_get_prev_bridge(struct drm_bridge *bridge) in drm_bridge_get_prev_bridge() argument
840 if (list_is_first(&bridge->chain_node, &bridge->encoder->bridge_chain)) in drm_bridge_get_prev_bridge()
843 return list_prev_entry(bridge, chain_node); in drm_bridge_get_prev_bridge()
847 * drm_bridge_chain_get_first_bridge() - Get the first bridge in the chain
851 * the first bridge in the chain, or NULL if @encoder has no bridge attached
864 * @bridge: a bridge pointer updated to point to the current bridge at each
867 * Iterate over all bridges present in the bridge chain attached to @encoder.
869 #define drm_for_each_bridge_in_chain(encoder, bridge) \ argument
870 list_for_each_entry(bridge, &(encoder)->bridge_chain, chain_node)
872 bool drm_bridge_chain_mode_fixup(struct drm_bridge *bridge,
876 drm_bridge_chain_mode_valid(struct drm_bridge *bridge,
879 void drm_bridge_chain_disable(struct drm_bridge *bridge);
880 void drm_bridge_chain_post_disable(struct drm_bridge *bridge);
881 void drm_bridge_chain_mode_set(struct drm_bridge *bridge,
884 void drm_bridge_chain_pre_enable(struct drm_bridge *bridge);
885 void drm_bridge_chain_enable(struct drm_bridge *bridge);
887 int drm_atomic_bridge_chain_check(struct drm_bridge *bridge,
890 void drm_atomic_bridge_chain_disable(struct drm_bridge *bridge,
892 void drm_atomic_bridge_chain_post_disable(struct drm_bridge *bridge,
894 void drm_atomic_bridge_chain_pre_enable(struct drm_bridge *bridge,
896 void drm_atomic_bridge_chain_enable(struct drm_bridge *bridge,
900 drm_atomic_helper_bridge_propagate_bus_fmt(struct drm_bridge *bridge,
907 enum drm_connector_status drm_bridge_detect(struct drm_bridge *bridge);
908 int drm_bridge_get_modes(struct drm_bridge *bridge,
910 struct edid *drm_bridge_get_edid(struct drm_bridge *bridge,
912 void drm_bridge_hpd_enable(struct drm_bridge *bridge,
916 void drm_bridge_hpd_disable(struct drm_bridge *bridge);
917 void drm_bridge_hpd_notify(struct drm_bridge *bridge,
921 bool drm_bridge_is_panel(const struct drm_bridge *bridge);
925 void drm_panel_bridge_remove(struct drm_bridge *bridge);
927 struct drm_bridge *bridge);
935 struct drm_connector *drm_panel_bridge_connector(struct drm_bridge *bridge);
937 static inline bool drm_bridge_is_panel(const struct drm_bridge *bridge) in drm_bridge_is_panel() argument
943 struct drm_bridge *bridge) in drm_panel_bridge_set_orientation() argument