summaryrefslogtreecommitdiffstats
path: root/drivers/rtc/class.c
diff options
context:
space:
mode:
authorLogan Gunthorpe <logang@deltatee.com>2017-03-17 12:48:20 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-03-21 06:44:33 +0100
commitdbef390d2eb0a7b0a6be21381a326d4e13953aba (patch)
tree959cf65e5592d2d397f92eef4141f70bf200860f /drivers/rtc/class.c
parent493cfaeaa0c9bc0c79ce5751193d49fdac9aaaec (diff)
downloadop-kernel-dev-dbef390d2eb0a7b0a6be21381a326d4e13953aba.zip
op-kernel-dev-dbef390d2eb0a7b0a6be21381a326d4e13953aba.tar.gz
rapidio: utilize new cdev_device_add helper function
This driver did not originally set kobj.parent so it likely had potential a use after free bug which this patch fixes. We convert from device_register to device_initialize/cdev_device_add. While we are at it we use put_device instead of kfree (as recommended by the device_initialize documentation). We also remove an unnecessary extra get_device from the code. Signed-off-by: Logan Gunthorpe <logang@deltatee.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/rtc/class.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud