Skip to content

Commit

Permalink
USB / PM: Don't try to hide PM QoS flags from usb_port_device_release()
Browse files Browse the repository at this point in the history
Remove the call to dev_pm_qos_hide_flags(), added by commit 6e30d7c
"usb: Add driver/usb/core/(port.c,hub.h) files", from
usb_port_device_release(), because (1) it is completely unnecessary
(the flags have been removed already by the PM core during the
unregistration of the device object) and (2) it triggers a NULL
pointer dereference in sysfs_find_dirent() (dev->kobj.sd is NULL at
this point).

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Rafael J. Wysocki committed Apr 1, 2013
1 parent 07961ac commit da25946
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion drivers/usb/core/port.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ static void usb_port_device_release(struct device *dev)
{
struct usb_port *port_dev = to_usb_port(dev);

dev_pm_qos_hide_flags(dev);
kfree(port_dev);
}

Expand Down

0 comments on commit da25946

Please sign in to comment.