sometimes we should use "disable fork" instead of "disable block_name"
A disable named block statement stops the execution of all blocks with that same name in all threads, which probably causes unexpected behavior.
Specific to this test, the “disable PM_LINK_WAIT_USB2_L1” statement will stops all active threads of PM_LINK_WAIT_USB2_L1 blocks, even if these PM_LINK_WAIT_USB2_L1 blocks are in different sequences.
Below I list the process of this issue.
1. In sequence “fch_usb_multi_port_trans_seqs”, sequence “fch_usb_lpm_trans_seqs” was called twice for each Port.
//Start transfers for devices
for(int dn=0;dn<number_of_device;dn++) begin
automatic int j=dn;
fork
begin
for(int k=0;k<2;k++) begin
usb_lpm_trans_seqs[j].otg_xhc_device_transfer= otg_xhc_device_transfer[j];
usb_lpm_trans_seqs[j].start(p_sequencer, this);
end
end
join_none
end
2. In sequence “fch_usb_lpm_trans_seqs”, we need to read register PORTSC_20 to check whether Port is in L1 LPM state.
//Enter low power
reg_port_num = otg_xhc_device_transfer.device_cfg.port_number;
if( pm_controller.pm_link_state == fch_otg_pm_controller::U1_L1 ||
pm_controller.pm_link_state == fch_otg_pm_controller::U2_L1 ) begin
fork : PM_LINK_WAIT_USB2_L1
begin
do begin
#5us;
expected_pm_link_state = 4'd2;
uvm_ext_fd_reg_access(`uvm_ext_fileline,RD,"dwc_usb3_reg","PORTSC_20",reg_data, reg_port_num);
end while(reg_data[8:5] != 4'd2);
end
begin
if(otg_xhc_device_transfer.device_cfg.connected_bus_speed == svt_usb_types::LS) begin
#3500us;
end else if(otg_xhc_device_transfer.device_cfg.connected_bus_speed == svt_usb_types::FS) begin
#2500us;
end else begin
#500us;
end
`uvm_fatal(get_type_name(), $psprintf("PM: Link, waiting for USB2.0 L1 failed for port %0d", otg_xhc_device_transfer.device_cfg.port_number));
end
join_any
disable PM_LINK_WAIT_USB2_L1;
`uvm_info(get_type_name(), $psprintf("PM: Link, Port %0d is L1", otg_xhc_device_transfer.device_cfg.port_number), UVM_LOW);
end
3. below waveform snapshot,
At #T1, usb_lpm_trans_seqs_0 read register PORTSC_20, and the RDATA is 32’h603
At #T2, usb_lpm_trans_seqs_1 read register PORTSC_20, and the RDATA is 32’h643.
That is, Port0 is in L1 state, and Port1 is not.

4. However, The sequence mistakenly checked the Port0 and Port1 were both in L1 state, which was reported in below log.

sometimes we should use "disable fork" instead of "disable block_name"的更多相关文章
- Disable Maven Nature和disable workspace resolution
1.Disable Maven Nature myeclipse更新maven的时候,手抖了一下,点上了Disable Maven Nature,然后工程右键菜单中的Maven栏就不见了! 其实这是把 ...
- How to detect, enable and disable SMBv1, SMBv2, and SMBv3 in Windows and Windows Server
转自:https://support.microsoft.com/en-us/help/2696547/detect-enable-disable-smbv1-smbv2-smbv3-in-windo ...
- How to Disable/Enable IP forwarding in Linux
This article describes how to Disable or Enable an IP forwarding in Linux. Current IP forwarding sta ...
- How To Disable MacBook ProTrackpad
How To Disable MacBook Pro Trackpad how to close macbook pro touchpad? https://www.wikihow.com/Chang ...
- 最近遇到的若干Web前端问题:disable和readonly,JqueryEasyUI,KindEditor
最近项目中用到了Jquery Easyui和KindEditor等框架组件,问题真不少啊~ 一些看起来很简单理所当然的事情,竟然花费了不少时间,才解决好~ 1.readonly和disable的区 ...
- FFMPEG ./configure 参数及意义
FFMPEG版本:2.6.2,编译环境:ubuntu 14.4. 不同版本的FFMPEG参数可能不同,可在FFMPEG目录下使用以下命令查看 ./configure --help --help pri ...
- GDB教程详解
GDB是GNU开源组织发布的一个强大的UNIX下的程序调试工具.或许,各位比较喜欢那种图形界面方式的,像VC.BCB等IDE的调试,但如果你是在UNIX平台下做软件,你会发现GDB这个调试工具有比VC ...
- centos 7.0 PHP 5.6.5 安装过程 (php+nginx)
php网址 http://php.net/downloads.php 首先下载 php-5.6.5.tar.gz [root@localhost src]# wget http://cn2.php.n ...
- GDB中文手册
用GDB调试程序GDB概述 2使用GDB 5GDB中运行UNIX的shell程序 8在GDB中运行程序 8调试已运行的程序 两种方法: 9暂停 / 恢复程序运行 9一.设置断点(BreakPoint) ...
随机推荐
- 基于Centos体验自然语言处理 by Python SDK
系统要求: CentOS 7.2 64 位操作系统 准备工作 获取 SecretId 和 SecretKey 前往 密钥管理 页面获取你的 SecretId 和 SecretKey 信息,这些信息将会 ...
- Mac Apache WebDav 服务器配置
1.WebDav 服务器 基于 http 协议的 "文件" 服务器. 实现文件的上传/下载/修改/删除. WebDav 权限 授权信息的格式 BASIC (用户名:口令)base6 ...
- 谈谈MySQL的do语句
[select在某些场景下的不足] 比如说我们想让MySQL暂停5秒.那么可以这样写 ); +----------+ ) | +----------+ | +----------+ row in se ...
- ansible执行shell模块和command模块报错| FAILED | rc=127 >> /bin/sh: lsof: command not found和| rc=2 >> [Errno 2] No such file or directory
命令: ansible -i hosts_20 st -m shell -a 'service zabbix_agentd star' -K --become ansible -i hosts_2 ...
- 图解ByteBuffer
https://www.cnblogs.com/ruber/p/6857159.html https://www.e-learn.cn/content/qita/750752 https://blog ...
- Fluent动网格【8】:网格节点运动案例
Fluent动网格中的DEFINE_GRID_MOTION宏允许用户定义网格节点的运动.本案例演示采用DEFINE_GRID_MOTION宏指定边界节点的运动. 案例动网格效果如图所示. 案例描述 本 ...
- 使用自定义端口连接SQL Server 的方法
SQL默认是1433,使用MSSL连接时默认不需要加端口号,但是在修改了SQL端口之后,就需要添加自定义端口号了,加端口号使用的是逗号(,)而不是冒号(:). 看一下连接截图吧
- 利用堆实现堆排序&优先队列
数据结构之(二叉)堆一文在末尾提到"利用堆能够实现:堆排序.优先队列.".本文代码实现之. 1.堆排序 如果要实现非递减排序.则须要用要大顶堆. 此处设计到三个大顶堆的操作:(1) ...
- Hadoop2.6新增用户隔离
1.hadoop文件权限介绍 (这部分内容参考成品 https://blog.csdn.net/skywalker_only/article/details/40709447) 之前在论坛看到一个关 ...
- Fixed Partition Memory Management UVALive - 2238 建图很巧妙 km算法左右顶点个数不等模板以及需要注意的问题 求最小权匹配
/** 题目: Fixed Partition Memory Management UVALive - 2238 链接:https://vjudge.net/problem/UVALive-2238 ...