Hello, > + if (err > 0) { You could drop > 0 here. > + /* Get the maximum speed supported by the controller */ > + max_speed = mtk_pcie_get_controller_max_link_speed(pcie); > + > + /* Set max_link_speed only if the controller supports it */ > + if (max_speed >= 0 && max_speed <= err) { > + pcie->max_link_speed = err; > + dev_dbg(pcie->dev, > + "Max controller link speed Gen%d, override to Gen%u", > + max_speed, pcie->max_link_speed); > + } > + } I wonder if this debug message would be better served as a warning to let the user know that the speed has been overridden due to the platform limitation. Thoughts? Also, there is no need to sent a new series if you fine with the suggestions. I will mend the code on the branch when applying. Krzysztof