mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-15 07:36:42 +07:00
8d2c3ab444
The purpose of gigaset_device_release() is to kfree() the struct ser_cardstate that contains our struct device. This is done via a bit of a detour. First we make our struct device's driver_data point to the container of our struct ser_cardstate (which is a struct cardstate). In gigaset_device_release() we then retrieve that driver_data again. And after that we finally kfree() the struct ser_cardstate that was saved in the struct cardstate. All of this can be achieved much easier by using container_of() to get from our struct device to its container, struct ser_cardstate. Do so. Note that at the time the detour was implemented commit |
||
---|---|---|
.. | ||
asyncdata.c | ||
bas-gigaset.c | ||
capi.c | ||
common.c | ||
dummyll.c | ||
ev-layer.c | ||
gigaset.h | ||
i4l.c | ||
interface.c | ||
isocdata.c | ||
Kconfig | ||
Makefile | ||
proc.c | ||
ser-gigaset.c | ||
usb-gigaset.c |