Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux: Kernel

[BUGFIX] PM, domain, Fix link checking when add subdomain

 

 

Linux kernel RSS feed   Index | Next | Previous | View Threaded


ying.huang at intel

May 6, 2012, 10:28 PM

Post #1 of 2 (72 views)
Permalink
[BUGFIX] PM, domain, Fix link checking when add subdomain

Current pm_genpd_add_subdomain() will allow duplicated link between
master and slave domain. This patch fixed it.

Because when current pm_genpd_add_subdomain() checks whether the link
between the master and slave generic PM domain already exists,
slave_links instead of master_links of master domain is used.

Signed-off-by: Huang Ying <ying.huang [at] intel>
---
drivers/base/power/domain.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/base/power/domain.c
+++ b/drivers/base/power/domain.c
@@ -1378,7 +1378,7 @@ int pm_genpd_add_subdomain(struct generi
goto out;
}

- list_for_each_entry(link, &genpd->slave_links, slave_node) {
+ list_for_each_entry(link, &genpd->master_links, master_node) {
if (link->slave == subdomain && link->master == genpd) {
ret = -EINVAL;
goto out;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


rjw at sisk

May 7, 2012, 12:46 PM

Post #2 of 2 (73 views)
Permalink
Re: [BUGFIX] PM, domain, Fix link checking when add subdomain [In reply to]

On Monday, May 07, 2012, Huang Ying wrote:
> Current pm_genpd_add_subdomain() will allow duplicated link between
> master and slave domain. This patch fixed it.
>
> Because when current pm_genpd_add_subdomain() checks whether the link
> between the master and slave generic PM domain already exists,
> slave_links instead of master_links of master domain is used.
>
> Signed-off-by: Huang Ying <ying.huang [at] intel>

Thanks for the fix, applied to linux-pm/linux-next.

Thanks,
Rafael


> ---
> drivers/base/power/domain.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> --- a/drivers/base/power/domain.c
> +++ b/drivers/base/power/domain.c
> @@ -1378,7 +1378,7 @@ int pm_genpd_add_subdomain(struct generi
> goto out;
> }
>
> - list_for_each_entry(link, &genpd->slave_links, slave_node) {
> + list_for_each_entry(link, &genpd->master_links, master_node) {
> if (link->slave == subdomain && link->master == genpd) {
> ret = -EINVAL;
> goto out;
> --
> To unsubscribe from this list: send the line "unsubscribe linux-pm" in
> the body of a message to majordomo [at] vger
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
>

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Linux kernel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.