UFS Power Mode Change 介绍

一. UFS Power Mode Change简介

1.UFS Power Mode指的是Unipro层的Power State, 也可以称为链路(Link)上的Power Mode, 可以通过配置Unipro Attribute, 然后控制切换Unipro Power State,  当前Power Mode Change有两种触发方式:

(1) 通过DME Power Mode Change触发Power Mode Change 

(2)通过DME SET PA_PWRMode[0x1571]触发Power Mode Change

目前主流的安卓平台(QCOM/MTK)使用第二种方式,先设置好本地端(Local )Local 端的Power Mode属性, 然后通过发送DME SET PA_PWRMode切换对端(Peer)的Power Mode. 

UFS Power Mode相关的Unipro Attribute:

(1)PA_ACTIVETXDATALANES[0x1560]/PA_ACTIVERXDATALANES[0x1580]:  Number of active Data Lanes per direction, 通过DME GET 获取对应的属性值,

(2)PA_RxGear[0x1583]/PA_TxGear[0x1568]: PWM-GEAR per direction, 默认Link Startup之后的状态就是PWM_G1

(3)PA_RxGear[0x1583]/PA_TxGear[0x1568]: HS-GEAR used per direction, 需要通过DME SET PA_PWRMode从PWM_G1切换到HS Gear1~ HS Gear4, UFS3.1最高支持HS Gear4, UFS4.0最高支持HS Gear5

(4)PA_HSSeries[0x156A]: HS RATE series (same value used for both directions)

(5)PA_TxTermination[0x1569]/PA_RxTermination[0x1584]: Line termination per direction

(6)PA_PWRMode[0x1571]: Power Mode for each direction combined into a single PA_PWRMode Attribute, 安卓UFS驱动就是通过DME SET PA_PWRMode触发Peer端Power Mode Change流程

  UniPro Power Modes:

Power Mode Description UniPro Power State
Fast_ModeThe Fast_Mode is capable of the highest data transmission rate of all Power Modes. The Link is always ready to send and receive data while providing a well-defined latency, which is 
the lowest of any UniPro Power Modes. The actual data rate per Data Lane in the Fast_Mode is PHY-specific.
FAST_STATE
Slow_ModeThe Slow_Mode is also capable of transmitting data. It should be less than, or equal to, the data rate in Fast_Mode and consume less, or equal, power. The provided latency is welldefined but might be higher than in the Fast_Mode. The actual data rate in the Slow_Mode is PHY-specific.SLOW_STATE
FastAuto_ModeThe FastAuto_Mode allows the UniPro stack to autonomously switch between the FAST_STATE and the SLEEP_STATE, depending whether or not the DL Layer has data to send. By switching between states, the FastAuto_Mode might save 
power compared to the Fast_Mode, but at the cost of a possibly less well-defined latency. UniPro does not dictate a certain method for the autonomous switching. In any case, a 
PA Layer shall be able to transmit DL Layer data when in FastAuto_Mode.
FAST_STATE,
SLEEP_STATE
SlowAuto_ModeThe SlowAuto_Mode allows the UniPro stack to autonomously switch between the SLOW_STATE and the SLEEP_STATE, depending on whether or not the DL Layer has data to send. By switching between states, the SlowAuto_Mode might save 
power compared to the Slow_Mode, but at the cost of a possibly less well-defined latency. UniPro does not dictate a certain method for the autonomous switching. In case a UniPro stack does not provide any method for autonomous 
switching, its SlowAuto_Mode shall be strictly mapped to the SLOW_STATE. In any case, a PA Layer shall be able to transmit DL Layer data when in SlowAuto_Mode

SLOW_STATE,

SLEEP_STATE

Hibernate_ModeThe Hibernate_Mode is a low Power Mode in which no data transmission is possible. There may be a long latency returning from this mode to one of the other modes. The Hibernate_Mode should consume less power than any of the 
other modes in this table, except Off_Mode.
HIBERNATE_STATE
Off_ModeThe Off_Mode prepares for the removal of power. When a Device is ready to have its power removed it enters the OFF_STATE

OFF_STATE\

Unipro Power State to M-PHY state Mapping:

HS Gear Rates:UFS3.1最高支持HS Gear4, RateB, 

二. UFS Power Mode Change概述

Power Mode Change using PACP_PWR_req and PACP_PWR_cnf流程:

(1) UFS Host侧(通常是UFS Host Driver)通过HCI发送DME SET  PA_PWRMode[0x1571]原语到本端的PA层,

(2)本地Local端会检查Capability, 检查合适之后发送回复给本地的Host侧的 PA_PWRMode 原语,

(3)PA层启动TX链路,并且发送PACP_PWR_req(Power Mode change request)给远端(Remote)侧的PA层,

(4)远端(Remote)侧的PA层会检查Capability, 检查合适之后发送PA_LM_PWR_MODE.ind通知远端进行Power Mode Change, 

(5)远端收到之后,会回复PA_LM_PWR_MODE.rsp_L,表示收到Power Mode Change请求

(6)远端启动TX, 并且发送PACP_PWR_cnf用来回复本地Local端的PACP_PWR_req请求

(7)本地端收到PACP_PWR_cnf后,检查合适之后发送PA_LM_PWR_MODE.ind通知本地端进行Power Mode Change,  

(8)本地端收到之后,会回复PA_LM_PWR_MODE.rsp_L,表示收到Power Mode Change请求

(9)本地端关闭TX活动,远端关闭TX活动

(10)本地端发送PA_DL_RESUME.ind唤醒Data Link Layer,远端发送PA_DL_RESUME.ind唤醒Data Link Layer

(11)本地端发送PA_LM_PWR_MODE_CHANGED.ind (PWR_LOCAL)回复Power Mode Change的结果给本地端DME层

(12)远端PA层通过发送PA_LM_PWR_MODE_CHANGED.ind(PWR_REMOTE)回复Power Mode Change的结果给本地端DME层

Note1: PA 层之间(Local PA层和Remote PA层)的通信需要使用协议定义PA Control Protocol (PACP)数据包。

Note2: 可以通过PA协议分析仪抓取PA数据包,分析Power Mode Change的流程,PA协议分析仪抓取的数据是Local PA和Remote PA之间的数据。

三. UFS Power Mode Change详解

1. 安卓系统的Power Mode Change: 

(1). 在安卓系统上,UFS初始化LinkStartup之后的Power Mode是PWM Gear1, Slow_Mode,RateA, Lane1, 

(2). 获取最大的HSGEAR,获取PA的Connect Data Lane,通过DME Get获取对应的值

(3). 进行Power Mode Change, 切换完之后的Power Mode是HS Gear4, FastMode, RateB, Lane2.

2. Power Mode Change失败遇到的问题:

(1). UFS Host侧的Reference clock和UFS Device侧的bRefClkFreq Attribute不匹配,切换失败,可以使用可以使用UFS协议分析仪或者ufs utils调试

(2). UFS切高速的时候没有设置adapt, 目前HS Gear4及以上需要进行设置adapt, 用来做数据传输的时序训练,保证链路层数据传输的稳定性,可以使用UFS协议分析仪调试

(3)  UFS Device侧没有进行LinkStartup或者Link Down,可以使用UFS协议分析仪调试

(4)  UFS 相关的Vcc/Vccq/Vccq2异常,可以使用万用表或者示波器调试

(5)  UFS 状态异常,可能需要重新刷UFS FW恢复, 可以通过FFU升级UFS FW

3. Power Mode Change省电:

(1). 安卓系统侧在省电的时候,会把UFS Power Mode切换为HS Gear1, FastMode, RateB, Lane2

(2) UFS Device侧在省电的时候,会关闭Vcc,  Link 进入Hibernate状态,UFS Device进入省电模式

(3) UFS Device侧在省电的时候,会将UFS Cache的数据刷到UFS Nand存储介质

四. UFS Power Mode Change代码实现

1. 获取UFS Device支持的最大Power Mode, 需要通过DME GET命令读取连接的Lane Count, 最大的HS Gear, 调试的时候可以通过UFS Event Trace分析流程

/*** ufshcd_get_max_pwr_mode - reads the max power mode negotiated with device* @hba: per-adapter instance*/
static int ufshcd_get_max_pwr_mode(struct ufs_hba *hba)
{struct ufs_pa_layer_attr *pwr_info = &hba->max_pwr_info.info;if (hba->max_pwr_info.is_valid)return 0;pwr_info->pwr_tx = FAST_MODE;pwr_info->pwr_rx = FAST_MODE;pwr_info->hs_rate = PA_HS_MODE_B;/* Get the connected lane count */ufshcd_dme_get(hba, UIC_ARG_MIB(PA_CONNECTEDRXDATALANES),&pwr_info->lane_rx);ufshcd_dme_get(hba, UIC_ARG_MIB(PA_CONNECTEDTXDATALANES),&pwr_info->lane_tx);if (!pwr_info->lane_rx || !pwr_info->lane_tx) {dev_err(hba->dev, "%s: invalid connected lanes value. rx=%d, tx=%d\n",__func__,pwr_info->lane_rx,pwr_info->lane_tx);return -EINVAL;}/** First, get the maximum gears of HS speed.* If a zero value, it means there is no HSGEAR capability.* Then, get the maximum gears of PWM speed.*/ufshcd_dme_get(hba, UIC_ARG_MIB(PA_MAXRXHSGEAR), &pwr_info->gear_rx);if (!pwr_info->gear_rx) {ufshcd_dme_get(hba, UIC_ARG_MIB(PA_MAXRXPWMGEAR),&pwr_info->gear_rx);if (!pwr_info->gear_rx) {dev_err(hba->dev, "%s: invalid max pwm rx gear read = %d\n",__func__, pwr_info->gear_rx);return -EINVAL;}pwr_info->pwr_rx = SLOW_MODE;}ufshcd_dme_peer_get(hba, UIC_ARG_MIB(PA_MAXRXHSGEAR),&pwr_info->gear_tx);if (!pwr_info->gear_tx) {ufshcd_dme_peer_get(hba, UIC_ARG_MIB(PA_MAXRXPWMGEAR),&pwr_info->gear_tx);if (!pwr_info->gear_tx) {dev_err(hba->dev, "%s: invalid max pwm tx gear read = %d\n",__func__, pwr_info->gear_tx);return -EINVAL;}pwr_info->pwr_tx = SLOW_MODE;}hba->max_pwr_info.is_valid = true;return 0;
}

2.  配置UFS Device新的Power Mode, 主要分为两步,第一步是获取并配置UFS Host侧Power Mode信息,第二步是切换Power Mode, 

/*** ufshcd_config_pwr_mode - configure a new power mode* @hba: per-adapter instance* @desired_pwr_mode: desired power configuration*/
int ufshcd_config_pwr_mode(struct ufs_hba *hba,struct ufs_pa_layer_attr *desired_pwr_mode)
{struct ufs_pa_layer_attr final_params = { 0 };int ret;ret = ufshcd_vops_pwr_change_notify(hba, PRE_CHANGE,desired_pwr_mode, &final_params);if (ret)memcpy(&final_params, desired_pwr_mode, sizeof(final_params));ret = ufshcd_change_power_mode(hba, &final_params);if (!ret)ufshcd_print_pwr_info(hba);return ret;
}
EXPORT_SYMBOL_GPL(ufshcd_config_pwr_mode);

(1) 获取UFS Host侧的Power Mode能力信息,包括支持的HS Gear, 使能Data Lane, 

static int ufs_qcom_pwr_change_notify(struct ufs_hba *hba,enum ufs_notify_change_status status,struct ufs_pa_layer_attr *dev_max_params,struct ufs_pa_layer_attr *dev_req_params)
{u32 val;struct ufs_qcom_host *host = ufshcd_get_variant(hba);struct phy *phy = host->generic_phy;struct ufs_qcom_dev_params ufs_qcom_cap;int ret = 0;int res = 0;if (!dev_req_params) {pr_err("%s: incoming dev_req_params is NULL\n", __func__);ret = -EINVAL;goto out;}switch (status) {case PRE_CHANGE:ufs_qcom_cap.tx_lanes = UFS_QCOM_LIMIT_NUM_LANES_TX;ufs_qcom_cap.rx_lanes = UFS_QCOM_LIMIT_NUM_LANES_RX;ufs_qcom_cap.hs_rx_gear = UFS_QCOM_LIMIT_HSGEAR_RX;ufs_qcom_cap.hs_tx_gear = UFS_QCOM_LIMIT_HSGEAR_TX;ufs_qcom_cap.pwm_rx_gear = UFS_QCOM_LIMIT_PWMGEAR_RX;ufs_qcom_cap.pwm_tx_gear = UFS_QCOM_LIMIT_PWMGEAR_TX;ufs_qcom_cap.rx_pwr_pwm = UFS_QCOM_LIMIT_RX_PWR_PWM;ufs_qcom_cap.tx_pwr_pwm = UFS_QCOM_LIMIT_TX_PWR_PWM;ufs_qcom_cap.rx_pwr_hs = UFS_QCOM_LIMIT_RX_PWR_HS;ufs_qcom_cap.tx_pwr_hs = UFS_QCOM_LIMIT_TX_PWR_HS;ufs_qcom_cap.hs_rate = UFS_QCOM_LIMIT_HS_RATE;ufs_qcom_cap.desired_working_mode =UFS_QCOM_LIMIT_DESIRED_MODE;if (host->hw_ver.major == 0x1) {/** HS-G3 operations may not reliably work on legacy QCOM* UFS host controller hardware even though capability* exchange during link startup phase may end up* negotiating maximum supported gear as G3.* Hence downgrade the maximum supported gear to HS-G2.*/if (ufs_qcom_cap.hs_tx_gear > UFS_HS_G2)ufs_qcom_cap.hs_tx_gear = UFS_HS_G2;if (ufs_qcom_cap.hs_rx_gear > UFS_HS_G2)ufs_qcom_cap.hs_rx_gear = UFS_HS_G2;}ret = ufs_qcom_get_pwr_dev_param(&ufs_qcom_cap,dev_max_params,dev_req_params);if (ret) {pr_err("%s: failed to determine capabilities\n",__func__);goto out;}/* enable the device ref clock before changing to HS mode */if (!ufshcd_is_hs_mode(&hba->pwr_info) &&ufshcd_is_hs_mode(dev_req_params))ufs_qcom_dev_ref_clk_ctrl(host, true);break;case POST_CHANGE:if (ufs_qcom_cfg_timers(hba, dev_req_params->gear_rx,dev_req_params->pwr_rx,dev_req_params->hs_rate, false)) {dev_err(hba->dev, "%s: ufs_qcom_cfg_timers() failed\n",__func__);/** we return error code at the end of the routine,* but continue to configure UFS_PHY_TX_LANE_ENABLE* and bus voting as usual*/ret = -EINVAL;}val = ~(MAX_U32 << dev_req_params->lane_tx);res = ufs_qcom_phy_set_tx_lane_enable(phy, val);if (res) {dev_err(hba->dev, "%s: ufs_qcom_phy_set_tx_lane_enable() failed res = %d\n",__func__, res);ret = res;}/* cache the power mode parameters to use internally */memcpy(&host->dev_req_params,dev_req_params, sizeof(*dev_req_params));ufs_qcom_update_bus_bw_vote(host);/* disable the device ref clock if entered PWM mode */if (ufshcd_is_hs_mode(&hba->pwr_info) &&!ufshcd_is_hs_mode(dev_req_params))ufs_qcom_dev_ref_clk_ctrl(host, false);break;default:ret = -EINVAL;break;}
out:return ret;
}

 (2)通过DME SET配置Local PA侧(UFS Host PA侧)的Power Mode信息,包括Hs Gear, TERMINATION, HSSERIES,  ACTIVETXDATALANES,  

static int ufshcd_change_power_mode(struct ufs_hba *hba,struct ufs_pa_layer_attr *pwr_mode)
{int ret;/* if already configured to the requested pwr_mode */if (pwr_mode->gear_rx == hba->pwr_info.gear_rx &&pwr_mode->gear_tx == hba->pwr_info.gear_tx &&pwr_mode->lane_rx == hba->pwr_info.lane_rx &&pwr_mode->lane_tx == hba->pwr_info.lane_tx &&pwr_mode->pwr_rx == hba->pwr_info.pwr_rx &&pwr_mode->pwr_tx == hba->pwr_info.pwr_tx &&pwr_mode->hs_rate == hba->pwr_info.hs_rate) {dev_dbg(hba->dev, "%s: power already configured\n", __func__);return 0;}/** Configure attributes for power mode change with below.* - PA_RXGEAR, PA_ACTIVERXDATALANES, PA_RXTERMINATION,* - PA_TXGEAR, PA_ACTIVETXDATALANES, PA_TXTERMINATION,* - PA_HSSERIES*/ufshcd_dme_set(hba, UIC_ARG_MIB(PA_RXGEAR), pwr_mode->gear_rx);ufshcd_dme_set(hba, UIC_ARG_MIB(PA_ACTIVERXDATALANES),pwr_mode->lane_rx);if (pwr_mode->pwr_rx == FASTAUTO_MODE ||pwr_mode->pwr_rx == FAST_MODE)ufshcd_dme_set(hba, UIC_ARG_MIB(PA_RXTERMINATION), TRUE);elseufshcd_dme_set(hba, UIC_ARG_MIB(PA_RXTERMINATION), FALSE);ufshcd_dme_set(hba, UIC_ARG_MIB(PA_TXGEAR), pwr_mode->gear_tx);ufshcd_dme_set(hba, UIC_ARG_MIB(PA_ACTIVETXDATALANES),pwr_mode->lane_tx);if (pwr_mode->pwr_tx == FASTAUTO_MODE ||pwr_mode->pwr_tx == FAST_MODE)ufshcd_dme_set(hba, UIC_ARG_MIB(PA_TXTERMINATION), TRUE);elseufshcd_dme_set(hba, UIC_ARG_MIB(PA_TXTERMINATION), FALSE);if (pwr_mode->pwr_rx == FASTAUTO_MODE ||pwr_mode->pwr_tx == FASTAUTO_MODE ||pwr_mode->pwr_rx == FAST_MODE ||pwr_mode->pwr_tx == FAST_MODE)ufshcd_dme_set(hba, UIC_ARG_MIB(PA_HSSERIES),pwr_mode->hs_rate);ret = ufshcd_uic_change_pwr_mode(hba, pwr_mode->pwr_rx << 4| pwr_mode->pwr_tx);if (ret) {dev_err(hba->dev,"%s: power mode change failed %d\n", __func__, ret);} else {ufshcd_vops_pwr_change_notify(hba, POST_CHANGE, NULL,pwr_mode);memcpy(&hba->pwr_info, pwr_mode,sizeof(struct ufs_pa_layer_attr));}return ret;
}

3. 通过发送DME SET PA_PWRMODE(0x0x1571)触发Remote PA侧(UFS Device PA侧)进行Power Mode Change.

#define PA_PWRMODE		0x1571/*** ufshcd_uic_change_pwr_mode - Perform the UIC power mode chage*				using DME_SET primitives.* @hba: per adapter instance* @mode: powr mode value** Returns 0 on success, non-zero value on failure*/
static int ufshcd_uic_change_pwr_mode(struct ufs_hba *hba, u8 mode)
{struct uic_command uic_cmd = {0};int ret;if (hba->quirks & UFSHCD_QUIRK_BROKEN_PA_RXHSUNTERMCAP) {ret = ufshcd_dme_set(hba,UIC_ARG_MIB_SEL(PA_RXHSUNTERMCAP, 0), 1);if (ret) {dev_err(hba->dev, "%s: failed to enable PA_RXHSUNTERMCAP ret %d\n",__func__, ret);goto out;}}uic_cmd.command = UIC_CMD_DME_SET;uic_cmd.argument1 = UIC_ARG_MIB(PA_PWRMODE);uic_cmd.argument3 = mode;ufshcd_hold(hba, false);ret = ufshcd_uic_pwr_ctrl(hba, &uic_cmd);ufshcd_release(hba);out:return ret;
}

五. 参考资料

1. UniPro v1.6 Specification

2. JESD220E Universal Flash Storage (UFS)  Version 3.1

3. Linux Kernel 4.19 Source Code

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/857691.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

手工清理Linux后门:深入分析与实践指南

手工清理Linux后门&#xff1a;深入分析与实践指南 后门概述 后门程序允许未授权用户绕过正常的认证过程&#xff0c;获取对系统的访问权限。攻击者可能会通过修改计划任务、开机启动脚本&#xff0c;甚至植入Rootkit来维持后门。 分析操作系统被动手脚 在清理后门之前&…

创建一个基本的网页爬虫

创建一个基本的网页爬虫通常涉及使用Python库如requests来获取网页内容&#xff0c;以及BeautifulSoup来解析HTML并提取所需的信息。下面是一个简单的Python爬虫示例&#xff0c;该爬虫从网站上抓取新闻标题。为了演示&#xff0c;我将使用一个假设的新闻网站&#xff0c;但你可…

Jvm针对分代垃圾回收算法配置调优

堆大小设置 年轻代的设置很关键 JVM中最大堆大小有三方面限制&#xff1a;相关操作系统的数据模型&#xff08;32-bt还是64-bit&#xff09;限制&#xff1b;系统的可用虚拟内存限制&#xff1b;系统的可用物理内存限制。32位系统下&#xff0c;一般限制在1.5G~2G&#xff1b…

java中实现Callable方式创建线程

一、为啥要引入Callable 在前面讲了通过继承Thread和实现Runnable方式创建线程的区别&#xff0c;那为什么有了Runnable还要引入Callable?下面通过实现Runnable方式的弊端给出答案 实现Runnable方式的弊端&#xff1a; package java.lang; FunctionalInterface public inte…

宁波银行票据案例解读,要注入科技赋能票据新形式

随着科技的飞速发展&#xff0c;金融行业正迎来一场前所未有的变革。作为一家以科技创新为驱动的现代化银行&#xff0c;宁波银行在这场变革中积极探索&#xff0c;宁波银行票据案例之后持续通过引入先进技术&#xff0c;为客户提供更加高效、智能的金融服务。 宁波银行推出的…

1095 解码PAT准考证(测试点3)

solution 测试点3超时&#xff1a;命令为3时&#xff0c;用unordered_map而非map&#xff0c;否则会超时 #include<iostream> #include<string> #include<algorithm> #include<unordered_map> using namespace std; const int maxn 1e4 10; struct…

2024山东大学软件学院创新项目实训(9)使用OpenCompass进行模型评估

下载好OpenCompassData-core-20231110.zip 之后&#xff0c;解压压缩包 unzip OpenCompassData-core-20231110.zip 运行代码&#xff1a; python run.py --datasets ceval_gen --hf-path /hy-tmp/7B21/merged --tokenizer-path /hy-tmp/7B21/merged --tokenizer-kwargs p…

步步精:连接器领域的卓越品牌

自1987年成立以来&#xff0c;步步精坐落于美丽的旅游城市——温州市乐清虹桥镇&#xff0c;被誉为“国家电子主体生产基地”、“国家精密模具制造基地”。公司拥有7大厂区、9大事业部&#xff0c;800名专职员工&#xff0c;致力于提供高品质的连接器解决方案。注册商标“BBJCO…

家庭成员目标管理系统设计

一、项目背景与目标 随着现代社会对家庭教育的重视&#xff0c;家庭成员之间的目标设定与达成成为家庭和谐与进步的关键。本项目旨在设计一个家庭成员目标管理系统&#xff0c;通过系统化的方式帮助家庭成员设定、追踪和达成个人及家庭目标&#xff0c;从而提升家庭成员的成就感…

百度ai人脸识别项目C#

一、项目描述 本项目通过集成百度AI人脸识别API&#xff0c;实现了人脸检测和识别功能。用户可以上传图片&#xff0c;系统将自动识别人脸并返回识别结果。 二、开发环境 Visual Studio 2019或更高版本.NET Framework 4.7.2或更高版本AForge.NET库百度AI平台人脸识别API 三、…

从网络配置文件中提取PEAP凭据

我的一位同事最近遇到了这样一种情况&#xff1a;他可以物理访问使用802.1X连接到有线网络的Windows计算机&#xff0c;同时保存了用于身份验证的用户凭据&#xff0c;随后他想提取这些凭据&#xff0c;您可能认为这没什么特别的&#xff0c;但是事情却有点崎岖波折…… 如何开…

Android C++系列:C++最佳实践2抽象类

1. 背景 OOP面向对象程序设计的核心是数据抽象&#xff0c;继承和动态绑定。前面的文章我们介绍了使用virtual的虚类实现动态绑定的多态&#xff0c;有时候我们在做抽象时&#xff0c;对于抽象的实体不想让被人实例化&#xff0c;虚类没有这个功能&#xff0c;我们Java里面我们…

攻防世界-5-1

下载文件发现是一个没有尾缀的文件&#xff0c;扔winhex&#xff0c;emmmm还是没看出来 搜了一圈&#xff0c;发现用xortool 得到key之后&#xff0c;跑一下脚本 得到flag&#xff1a; wdflag{You Are Very Smart}

pytest测试框架pytest-sugar插件生成进度条

Pytest提供了丰富的插件来扩展其功能&#xff0c;介绍下插件pytest-sugar&#xff0c;可以帮助我们在控制台中显示彩色的测试结果和进度条&#xff0c;提供失败的堆栈回溯信息。 为了使用 pytest-sugar&#xff0c;需要满足以下条件&#xff1a; Python 3.8 或更高版本pytest…

并行计算之SIMD与SPMD

SIMD (Single Instruction Multiple Data) SIMD&#xff0c;也就是单指令多数据计算&#xff0c;一条指令可以处理多个数据。通过向量寄存器存储多个数据元素&#xff0c;并使用单条指令同时对这些数据元素进行处理&#xff0c;从而提高了计算效率。 代码示例&#xff1a; fl…

联想Y7000P 2023款拆机教程及升级内存教程

0.电脑参数介绍 联想Y7000P 2023电脑&#xff0c;笔者电脑CPU为i7-13700H&#xff0c;14核20线程&#xff1b;标配内存为三星的DDR5-5600MHz-8GB*2&#xff0c;由于电脑CPU限制&#xff0c;实际内存跑的频率为5200MHz; 2个内存插槽&#xff0c;2个固态硬盘插槽。每个内存插槽最…

FineReport报表案例

普通报表 保存的文件类型为 cpt&#xff0c;依靠着单元格的扩展与父子格的关系来实现模板效果&#xff0c;可进行参数查询&#xff0c;填报报表&#xff0c;图表设计等等&#xff0c;但是在分页预览模式下不能在报表主体中展示控件&#xff0c;而且单元格间相互影响&#xff0c…

1.2 DataX 数据同步工具详细介绍

DataX 是阿里巴巴开源的一款高效的数据同步工具&#xff0c;旨在实现多种异构数据源之间的高效数据同步。以下是对 DataX 的详细介绍&#xff1a; 架构 DataX 的架构主要包括以下几个核心组件&#xff1a; DataX Core&#xff1a;负责任务调度、插件加载、日志管理等核心功能…

IDEA 学习之 编译内存问题

目录 1. 正常的 IDEA build 日志2. 编译工具内存不足日志 &#xff08;内存从小变大&#xff09;2.1. 干脆无法启动2.2. Ant 任务执行报错2.3. 内存溢出&#xff1a;超出 GC 上限2.4. 内存溢出&#xff1a;超出 GC 上限&#xff0c;编译报错2.5. 内存溢出&#xff1a; 堆空间2.…

鞋子分类数据集17399张69类别

数据集类型&#xff1a;图像分类用&#xff0c;不可用于目标检测无标注文件 数据集格式&#xff1a;仅仅包含jpg图片&#xff0c;每个类别文件夹下面存放着对应图片 图片数量(jpg文件个数)&#xff1a;17399 分类类别数&#xff1a;69 类别名称:[“0”,“1”,“2”,“3”,“4”…