File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -738,11 +738,18 @@ static int apple_pcie_setup_port(struct apple_pcie *pcie,
738
738
739
739
link_stat = readl_relaxed (port -> base + PORT_LINKSTS );
740
740
if (!(link_stat & PORT_LINKSTS_UP )) {
741
+ unsigned long timeout , left ;
741
742
/* start link training */
742
743
writel_relaxed (PORT_LTSSMCTL_START , port -> base + PORT_LTSSMCTL );
743
744
744
- if (!wait_for_completion_timeout (& pcie -> event , link_up_timeout * HZ / 1000 ))
745
+ timeout = link_up_timeout * HZ / 1000 ;
746
+ left = wait_for_completion_timeout (& pcie -> event , timeout );
747
+ if (!left )
745
748
dev_warn (pcie -> dev , "%pOF link didn't come up\n" , np );
749
+ else
750
+ dev_info (pcie -> dev , "%pOF link up after %ldms\n" , np ,
751
+ (timeout - left ) * 1000 / HZ );
752
+
746
753
}
747
754
748
755
if (pcie -> hw -> port_refclk )
You can’t perform that action at this time.
0 commit comments