freebsd-skq/sys/arm/at91
hselasky 0c88dabe9d Fix device delete child function.
When detaching device trees parent devices must be detached prior to
detaching its children. This is because parent devices can have
pointers to the child devices in their softcs which are not
invalidated by device_delete_child(). This can cause use after free
issues and panic().

Device drivers implementing trees, must ensure its detach function
detaches or deletes all its children before returning.

While at it remove now redundant device_detach() calls before
device_delete_child() and device_delete_children(), mostly in
the USB controller drivers.

Tested by:		Jan Henrik Sylvester <me@janh.de>
Reviewed by:		jhb
Differential Revision:	https://reviews.freebsd.org/D8070
MFC after:		2 weeks
2016-10-17 10:20:38 +00:00
..
at91_aic.c ARM: Remove unused includes. 2016-10-09 10:25:47 +00:00
at91_aicreg.h
at91_cfata.c ARM: Remove unused includes. 2016-10-09 10:25:47 +00:00
at91_common.c Restrict where we need to define fdt_fixup_table to just PowerPC and 2016-09-23 14:11:23 +00:00
at91_gpio.h
at91_machdep.c Use the new(-ish) CP15_SCTLR macro to generate system control reg accesses 2016-05-23 20:07:17 +00:00
at91_mci.c ARM: Remove unused includes. 2016-10-09 10:25:47 +00:00
at91_mcireg.h
at91_ohci_fdt.c Fix device delete child function. 2016-10-17 10:20:38 +00:00
at91_ohci.c Fix device delete child function. 2016-10-17 10:20:38 +00:00
at91_pdcreg.h
at91_pinctrl.c Use OF_prop_free instead of direct call to free(9) 2016-05-13 22:05:16 +00:00
at91_pio_sam9g20.h
at91_pio_sam9g45.h
at91_pio.c
at91_pioreg.h
at91_piovar.h
at91_pit.c ARM: Remove unused includes. 2016-10-09 10:25:47 +00:00
at91_pitreg.h
at91_pmc.c ARM: Remove unused includes. 2016-10-09 10:25:47 +00:00
at91_pmcreg.h
at91_pmcvar.h
at91_reset.S sys/arm: Minor spelling fixes. 2016-05-04 15:48:59 +00:00
at91_rst.c
at91_rstreg.h
at91_rtc.c
at91_rtcreg.h
at91_sdramc.c
at91_shdwc.c
at91_smc.c
at91_smc.h
at91_spi.c
at91_spireg.h
at91_ssc.c
at91_sscreg.h
at91_st.c ARM: Remove unused includes. 2016-10-09 10:25:47 +00:00
at91_streg.h
at91_tcb.c
at91_twi.c
at91_twiio.h
at91_twireg.h
at91_usartreg.h
at91_wdt.c
at91_wdtreg.h
at91.c
at91board.h
at91reg.h sys/arm: Minor spelling fixes. 2016-05-04 15:48:59 +00:00
at91rm92reg.h
at91rm9200_devices.c
at91rm9200.c
at91rm9200var.h
at91sam9g20.c
at91sam9g20reg.h
at91sam9g45.c
at91sam9g45reg.h
at91sam9x5.c
at91sam9x5reg.h
at91sam9260.c sys/arm: Minor spelling fixes. 2016-05-04 15:48:59 +00:00
at91sam9260reg.h
at91soc.c
at91soc.h
at91var.h
board_bwct.c
board_eb9200.c
board_ethernut5.c
board_hl200.c
board_hl201.c
board_kb920x.c
board_qila9g20.c
board_sam9g20ek.c
board_sam9x25ek.c
board_sam9260ek.c
board_sn9g45.c
board_tsc4370.c
files.at91
if_ate.c sys/arm: Minor spelling fixes. 2016-05-04 15:48:59 +00:00
if_atereg.h sys/arm: Minor spelling fixes. 2016-05-04 15:48:59 +00:00
if_macb.c
if_macbreg.h
if_macbvar.h
std.at91
std.at91sam9
std.at91sam9g45
std.atmel
std.bwct
std.eb9200
std.ethernut5
std.hl200
std.hl201
std.kb920x
std.qila9g20
std.sam9g20ek
std.sam9x25ek
std.sam9260ek
std.sn9g45
std.tsc4370
uart_bus_at91usart.c
uart_cpu_at91usart.c
uart_dev_at91usart.c