Device properties framework fixes for 5.10-rc2
Fix the secondary firmware node handling while manipulating the primary firmware node for a given device (Andy Shevchenko). -----BEGIN PGP SIGNATURE----- iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAl+cO9USHHJqd0Byand5 c29ja2kubmV0AAoJEILEb/54YlRxTQkP/2BhlxtRxgywMrvIgWAlZF5Xj23GhjR0 qjaahbKw0Fqrw2XiOKa5A1lx4MRnfTVoyrOOoDINdV9Gq68ViPw+dV+Kwa3p+6kG K0qgp0A23WSBOdfoydlyXDs6qwEMFpzS/J/BaYYCRPxB7uH0UvAJ+GUGcR4YGpG9 INzjfvHzqUj3ZrvlF5bs4h9o+J+FvsoP7O9a+wtxtEIDw8It6MyoYJHfZ8JJ2g1A kvQWUWodLcDXdzg8zSTRAZcoIeKYmBytkr82taTapeU0PhQv9Dnqsc8heNArE24V U6L53z1/vvrmVHM0rdtAjMvbchejmhRZS4fB/FbVsb5sS6EAgRytbRaNBCJHIf52 /Snm+HTgdvv+82a/nFQ75v5NLJm2UfMdb2RdPTjAX4rzRe/pWJMLqSWfFQ9VG8mM AeIJWAH6iYtJkBn8cKWEJXNFtz4iUNRJfRlgTEYz28LxqY4KR2qyfQ9i59Ufp2K5 qWA8CJSJvvBMkCJQ3ysXwOUsLOcVYHpo2mLefb+HgLkrUXuLacCm1Hw1eIUb0FVF Y6ZaBw7y4JGDGmsFjH1A6/efgO3TsBn+o6kdxlZz4OKTTRqLuRlLjqbh7aP1x5KR snCUDKkaVGJwTb2eagQLLQUDRLMQP3/5wJsJVrDxM+rnmSLkq2N+jD2HJvcZKy9N DUj01unOvJsC =e0Ls -----END PGP SIGNATURE----- Merge tag 'devprop-5.10-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull device properties framework fixes from Rafael Wysocki: "Fix the secondary firmware node handling while manipulating the primary firmware node for a given device (Andy Shevchenko)" * tag 'devprop-5.10-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: device property: Don't clear secondary pointer for shared primary firmware node device property: Keep secondary firmware node secondary by type
This commit is contained in:
Коммит
a5a16050d7
|
@ -4264,6 +4264,7 @@ static inline bool fwnode_is_primary(struct fwnode_handle *fwnode)
|
|||
*/
|
||||
void set_primary_fwnode(struct device *dev, struct fwnode_handle *fwnode)
|
||||
{
|
||||
struct device *parent = dev->parent;
|
||||
struct fwnode_handle *fn = dev->fwnode;
|
||||
|
||||
if (fwnode) {
|
||||
|
@ -4278,7 +4279,8 @@ void set_primary_fwnode(struct device *dev, struct fwnode_handle *fwnode)
|
|||
} else {
|
||||
if (fwnode_is_primary(fn)) {
|
||||
dev->fwnode = fn->secondary;
|
||||
fn->secondary = NULL;
|
||||
if (!(parent && fn == parent->fwnode))
|
||||
fn->secondary = ERR_PTR(-ENODEV);
|
||||
} else {
|
||||
dev->fwnode = NULL;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче