linux/drivers/staging
Ian Abbott 682b911938 staging: comedi: cleanup all board minors on module exit
The comedi core module optionally allocates some legacy board minor
devices on module load and cleans these up on module exit.  These are
used for manual configuration of comedi boards (for those low-level
comedi drivers that support manual configuration - mainly for ISA
boards).  Other board minor devices are created and destroyed
dynamically in response to bus device probe and remove requests.  The
ioctl used for manual configuration (attachment) and removal
(detachment) of devices is COMEDI_DEVCONFIG, but that works for any
board minor device, including those that were originally created
dynamically.

If the COMEDI_DEVCONFIG ioctl is used to manually detach an
automatically created and attached device, commit
7d3135af39 ("staging: comedi: prevent
auto-unconfig of manually configured devices") ensures that the board
minor will no longer be automatically detached and destroyed by a bus
device remove request.  From that point on the board minor behaves more
like one of the comedi "legacy" board minors.  (There would be some
justification for destroying the board minor instead, but I'd rather
leave that decision until removal of board minors has been
made safer than it currently is.)  Although the board minor behaves more
like a legacy board minor, it is not currently cleaned up on module
exit.  In fact, the module exit code will bug out because this board
minor has not been cleaned up.

Change comedi_cleanup_legacy_minors() (called from the module exit code,
and from the module init code on error) to clean up all board minors.
Rename the function to comedi_cleanup_board_minors() to reflect the
change in functionality.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-30 11:47:47 +01:00
..
android staging: alarm-dev: Implement compat_ioctl support 2013-01-18 12:37:11 -08:00
asus_oled
bcm Staging: bcm: copying more data than intended 2013-01-17 13:52:37 -08:00
ccg
ced1401
comedi staging: comedi: cleanup all board minors on module exit 2013-01-30 11:47:47 +01:00
cptm1217
crystalhd
csr staging/csr: Use kmemdup rather than duplicating its implementation 2013-01-29 23:22:16 -05:00
cxt1e1 staging: cxt1e1: buffer overflow in do_del_chan() 2013-01-25 11:21:26 -08:00
dgrp staging: dgrp: check for a valid proc dir entry pointer 2013-01-22 08:58:44 -08:00
echo
et131x staging: et131x: Fix all sparse warnings 2013-01-22 09:15:18 -08:00
frontier
ft1000
fwserial staging/fwserial: Fix endian issue in unit directory 2013-01-29 23:31:34 -05:00
gdm72xx
goldfish goldfish: NAND flash driver 2013-01-24 13:53:23 -08:00
iio iio:light:tsl2563 move out of staging 2013-01-27 17:37:24 +00:00
imx-drm staging: ipu-di: Change DI address info to dev_dbg 2013-01-17 13:52:37 -08:00
keucr
line6 staging: line6: clean up line6_variax_process_message() 2013-01-20 15:57:47 -08:00
media
net
nvec staging: nvec: cleanup the string mess 2013-01-29 23:25:10 -05:00
octeon
olpc_dcon
omap-thermal staging: omap-thermal/omap-bandgap.c: adjust duplicate test 2013-01-21 14:00:10 -08:00
omapdrm staging/omapdrm: Use kmemdup rather than duplicating its implementation 2013-01-29 23:22:16 -05:00
ozwpan staging:ozwpan: Fix following warning. 2013-01-29 23:25:10 -05:00
panel
phison
quickstart
rtl8187se
rtl8192e
rtl8192u
rtl8712
rts5139
sb105x Merge 3.8-rc5 into staging-next 2013-01-25 21:25:02 -08:00
sbe-2t3e3
sep staging: sep: remove assignment to i and j in sep_crypto_setup 2013-01-22 08:58:44 -08:00
serqt_usb2
silicom
slicoss staging: slicoss: Fix space-related checkpatch.pl warnings 2013-01-17 13:53:06 -08:00
sm7xxfb
speakup Staging: speakup: kobjects.c: checkpatch.pl fixes 2013-01-17 13:31:07 -08:00
ste_rmi4
tidspbridge staging: tidspbridge/pmgr: another using strlcpy instead of strncpy 2013-01-21 14:00:10 -08:00
usbip staging: usbip: replace the interrupt safe spinlocks with common ones. 2013-01-22 09:00:10 -08:00
vme
vt6655
vt6656 Merge 3.8-rc5 into staging-next 2013-01-25 21:25:02 -08:00
winbond
wlags49_h2
wlags49_h25
wlan-ng Merge 3.8-rc5 into staging-next 2013-01-25 21:25:02 -08:00
xgifb staging: xgifb: delete pVBInfo->BaseAddr 2013-01-21 14:00:10 -08:00
zcache Staging: zcache: remove unnecessary braces in zcache-main.c 2013-01-29 23:22:16 -05:00
zram Merge 3.8-rc5 into staging-next 2013-01-25 21:25:02 -08:00
zsmalloc staging: zsmalloc: Fix TLB coherency and build problem 2013-01-29 23:22:16 -05:00
Kconfig goldfish: audio support 2013-01-24 13:51:38 -08:00
Makefile goldfish: audio support 2013-01-24 13:51:38 -08:00
staging.c