luckfox-pico-sdk/sysdrv/source/uboot/u-boot/include/power-domain-uclass.h
luckfox-eng29 8f34c2760d project:build.sh: Added fastboot support; custom modifications to U-Boot and kernel implemented using patches.
project:cfg:BoardConfig_IPC: Added fastboot BoardConfig file and firmware post-scripts, distinguishing between
the BoardConfigs for Luckfox Pico Pro and Luckfox Pico Max. project:app: Added fastboot_client and rk_smart_door
for quick boot applications; updated rkipc app to adapt to the latest media library. media:samples: Added more
usage examples. media:rockit: Fixed bugs; removed support for retrieving data frames from VPSS. media:isp:
Updated rkaiq library and related tools to support connection to RKISP_Tuner. sysdrv:Makefile: Added support for
compiling drv_ko on Luckfox Pico Ultra W using Ubuntu; added support for custom root filesystem.
sysdrv:tools:board: Updated Buildroot optional mirror sources, updated some software versions, and stored device
tree files and configuration files that undergo multiple modifications for U-Boot and kernel separately.
sysdrv:source:mcu: Used RISC-V MCU SDK with RT-Thread system, mainly for initializing camera AE during quick
boot. sysdrv:source:uboot: Added support for fastboot; added high baud rate DDR bin for serial firmware upgrades.
sysdrv:source:kernel: Upgraded to version 5.10.160; increased NPU frequency for RV1106G3; added support for
fastboot.

Signed-off-by: luckfox-eng29 <eng29@luckfox.com>
2024-10-14 09:47:04 +08:00

83 lines
2.4 KiB
C

/*
* Copyright (c) 2016, NVIDIA CORPORATION.
*
* SPDX-License-Identifier: GPL-2.0
*/
#ifndef _POWER_DOMAIN_UCLASS_H
#define _POWER_DOMAIN_UCLASS_H
/* See power-domain.h for background documentation. */
#include <power-domain.h>
struct udevice;
/**
* struct power_domain_ops - The functions that a power domain controller driver
* must implement.
*/
struct power_domain_ops {
/**
* of_xlate - Translate a client's device-tree (OF) power domain
* specifier.
*
* The power domain core calls this function as the first step in
* implementing a client's power_domain_get() call.
*
* If this function pointer is set to NULL, the power domain core will
* use a default implementation, which assumes #power-domain-cells =
* <1>, and that the DT cell contains a simple integer power domain ID.
*
* At present, the power domain API solely supports device-tree. If
* this changes, other xxx_xlate() functions may be added to support
* those other mechanisms.
*
* @power_domain: The power domain struct to hold the
* translation result.
* @args: The power domain specifier values from device
* tree.
* @return 0 if OK, or a negative error code.
*/
int (*of_xlate)(struct power_domain *power_domain,
struct ofnode_phandle_args *args);
/**
* request - Request a translated power domain.
*
* The power domain core calls this function as the second step in
* implementing a client's power_domain_get() call, following a
* successful xxx_xlate() call.
*
* @power_domain: The power domain to request; this has been
* filled in by a previous xxx_xlate() function
* call.
* @return 0 if OK, or a negative error code.
*/
int (*request)(struct power_domain *power_domain);
/**
* rfree - Free a previously requested power domain.
*
* This is the implementation of the client power_domain_free() API.
*
* @power_domain: The power domain to free.
* @return 0 if OK, or a negative error code.
*/
int (*rfree)(struct power_domain *power_domain);
/**
* on - Power on a power domain.
*
* @power_domain: The power domain to turn on.
* @return 0 if OK, or a negative error code.
*/
int (*on)(struct power_domain *power_domain);
/**
* off - Power off a power domain.
*
* @power_domain: The power domain to turn off.
* @return 0 if OK, or a negative error code.
*/
int (*off)(struct power_domain *power_domain);
};
#endif