summaryrefslogtreecommitdiffstats
path: root/drivers/pwm
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2013-11-13 09:32:22 +0100
committerSarah Sharp <sarah.a.sharp@linux.intel.com>2014-03-04 15:38:24 -0800
commit21fc05b680f6fba868b41e2713ade3fdea4049f9 (patch)
tree88d5fa34ee36c50352df7487926e246a040f5c18 /drivers/pwm
parentc6f63207a3ba689025b2120792ea831cf72f9a81 (diff)
downloadop-kernel-dev-21fc05b680f6fba868b41e2713ade3fdea4049f9.zip
op-kernel-dev-21fc05b680f6fba868b41e2713ade3fdea4049f9.tar.gz
uas: Fix memory management
The scsi-host structure is refcounted, scsi_remove_host tears down the scsi-host but does not decrement the refcount, so we need to call scsi_put_host on disconnect to get the underlying memory to be freed. After calling scsi_remove_host, the scsi-core may still hold a reference to the scsi-host, iow we may still get called after uas_disconnect, but we do our own life cycle management of uas_devinfo, freeing it on disconnect, and thus may end up using devinfo after it has been freed. Switch to letting scsi_host_alloc allocate and manage the memory for us. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Diffstat (limited to 'drivers/pwm')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud