/* * Copyright 2018 Advanced Micro Devices, Inc. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, publish, distribute, sublicense, * and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. * * Authors: AMD *
*/
void dc_dmub_srv_apply_idle_power_optimizations(conststruct dc *dc, bool allow_idle);
/** * dc_dmub_srv_set_power_state() - Sets the power state for DMUB service. * * Controls whether messaging the DMCUB or interfacing with it via HW register * interaction is permittable. * * @dc_dmub_srv - The DC DMUB service pointer * @power_state - the DC power state
*/ void dc_dmub_srv_set_power_state(struct dc_dmub_srv *dc_dmub_srv, enum dc_acpi_cm_power_state power_state);
/** * dc_dmub_srv_notify_fw_dc_power_state() - Notifies firmware of the DC power state. * * Differs from dc_dmub_srv_set_power_state in that it needs to access HW in order * to message DMCUB of the state transition. Should come after the D0 exit and * before D3 set power state. * * @dc_dmub_srv - The DC DMUB service pointer * @power_state - the DC power state
*/ void dc_dmub_srv_notify_fw_dc_power_state(struct dc_dmub_srv *dc_dmub_srv, enum dc_acpi_cm_power_state power_state);
/** * @dc_dmub_srv_should_detect() - Checks if link detection is required. * * While in idle power states we may need driver to manually redetect in * the case of a missing hotplug. Should be called from a polling timer. * * Return: true if redetection is required.
*/ bool dc_dmub_srv_should_detect(struct dc_dmub_srv *dc_dmub_srv);
/** * dc_wake_and_execute_dmub_cmd() - Wrapper for DMUB command execution. * * Refer to dc_wake_and_execute_dmub_cmd_list() for usage and limitations, * This function is a convenience wrapper for a single command execution. * * @ctx: DC context * @cmd: The command to send/receive * @wait_type: The wait behavior for the execution * * Return: true on command submission success, false otherwise
*/ bool dc_wake_and_execute_dmub_cmd(conststruct dc_context *ctx, union dmub_rb_cmd *cmd, enum dm_dmub_wait_type wait_type);
/** * dc_wake_and_execute_dmub_cmd_list() - Wrapper for DMUB command list execution. * * If the DMCUB hardware was asleep then it wakes the DMUB before * executing the command and attempts to re-enter if the command * submission was successful. * * This should be the preferred command submission interface provided * the DC lock is acquired. * * Entry/exit out of idle power optimizations would need to be * manually performed otherwise through dc_allow_idle_optimizations(). * * @ctx: DC context * @count: Number of commands to send/receive * @cmd: Array of commands to send * @wait_type: The wait behavior for the execution * * Return: true on command submission success, false otherwise
*/ bool dc_wake_and_execute_dmub_cmd_list(conststruct dc_context *ctx, unsignedint count, union dmub_rb_cmd *cmd, enum dm_dmub_wait_type wait_type);
/** * dc_wake_and_execute_gpint() * * @ctx: DC context * @command_code: The command ID to send to DMCUB * @param: The parameter to message DMCUB * @response: Optional response out value - may be NULL. * @wait_type: The wait behavior for the execution
*/ bool dc_wake_and_execute_gpint(conststruct dc_context *ctx, enum dmub_gpint_command command_code,
uint16_t param, uint32_t *response, enum dm_dmub_wait_type wait_type);
/** * struct ips_residency_info - struct containing info from dmub_ips_residency_stats * * @ips_mode: The mode of IPS that the follow stats appertain to * @residency_percent: The percentage of time spent in given IPS mode in millipercent * @entry_counter: The number of entries made in to this IPS state * @total_active_time_us: uint32_t array of length 2 representing time in the given IPS mode * in microseconds. Index 0 is lower 32 bits, index 1 is upper 32 bits. * @total_inactive_time_us: uint32_t array of length 2 representing time outside the given IPS mode * in microseconds. Index 0 is lower 32 bits, index 1 is upper 32 bits. * @histogram: Histogram of given IPS state durations - bucket definitions in dmub_ips.c
*/ struct ips_residency_info { enum ips_residency_mode ips_mode; unsignedint residency_percent; unsignedint entry_counter; unsignedint total_active_time_us[2]; unsignedint total_inactive_time_us[2]; unsignedint histogram[16];
};
/** * dc_dmub_srv_release_hw() - Notifies DMUB service that HW access is no longer required. * * @dc - pointer to DC object
*/ void dc_dmub_srv_release_hw(conststruct dc *dc); #endif/* _DMUB_DC_SRV_H_ */
Messung V0.5
¤ Dauer der Verarbeitung: 0.12 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.