android_kernel_xiaomi_sm8350/drivers/video
Geert Uytterhoeven a684e7d330 fbdev: fix fb_compat_ioctl() deadlocks
commit 3e680aae4e ("fb: convert
lock/unlock_kernel() into local fb mutex") introduced several deadlocks
in the fb_compat_ioctl() path, as mutex_lock() doesn't allow recursion,
unlike lock_kernel().  This broke frame buffer applications on 64-bit
systems with a 32-bit userland.

commit 120a37470c ("framebuffer compat_ioctl
deadlock") fixed one of the deadlocks.

This patch fixes the remaining deadlocks:
  - Revert commit 120a37470c,
  - Extract the core logic of fb_ioctl() into a new function do_fb_ioctl(),
  - Change all callsites of fb_ioctl() where info->lock is already held to
    call do_fb_ioctl() instead,
  - Add sparse annotations to all routines that take info->lock.

Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Cc: Mikulas Patocka <mpatocka@redhat.com>
Cc: Krzysztof Helt <krzysztof.h1@wp.pl>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-11-06 15:41:19 -08:00
..
aty radeonfb: accelerate imageblit and other improvements 2008-10-16 11:21:44 -07:00
backlight [ARM] corgi_lcd: fix simultaneous compilation with corgi_bl 2008-10-29 11:45:37 +08:00
console fbcon: don't inline updatescrollmode 2008-10-30 11:38:46 -07:00
display device create: video: convert device_create_drvdata to device_create 2008-10-16 09:24:45 -07:00
geode
i810
intelfb intelfb: support 945GME (as used in ASUS Eee 901) 2008-10-16 11:21:42 -07:00
kyro
logo
matrox matroxfb: support G200eV chip 2008-10-16 11:21:45 -07:00
mb862xx fbdev: add new framebuffer driver for Fujitsu MB862xx GDCs 2008-11-06 15:41:18 -08:00
mbx
nvidia
omap Merge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm 2008-10-16 11:25:32 -07:00
pnx4008 [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
riva
savage
sis
vermilion removed unused #include <linux/version.h>'s 2008-08-23 12:14:12 -07:00
via viafb: removed duplicated #include's 2008-10-30 11:38:45 -07:00
68328fb.c
acornfb.c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
acornfb.h
amba-clcd.c
amifb.c
arcfb.c
arkfb.c removed unused #include <linux/version.h>'s 2008-08-23 12:14:12 -07:00
asiliantfb.c
atafb_iplan2p2.c
atafb_iplan2p4.c
atafb_iplan2p8.c
atafb_mfb.c
atafb_utils.h
atafb.c
atafb.h
atmel_lcdfb.c atmel_lcdfb: disallow setting larger resolution than the framebuffer memory can handle 2008-10-16 11:21:44 -07:00
au1100fb.c
au1100fb.h
au1200fb.c
au1200fb.h
bf54x-lq043fb.c Blackfin arch: move include/asm-blackfin header files to arch/blackfin 2008-08-27 10:51:02 +08:00
bfin-t350mcqb-fb.c
bt431.h
bt455.h
bw2.c sparc: Annotate of_device_id arrays with const or __initdata. 2008-08-31 01:23:17 -07:00
c2p.c
c2p.h
carminefb_regs.h
carminefb.c framebuffer: fix carminefb section mismatch 2008-10-16 11:21:45 -07:00
carminefb.h
cfbcopyarea.c
cfbfillrect.c
cfbimgblt.c
cg3.c sparc: Annotate of_device_id arrays with const or __initdata. 2008-08-31 01:23:17 -07:00
cg6.c cg6: disable cursor when leaving graphics mode 2008-10-10 12:12:41 -07:00
cg14.c sparc: Annotate of_device_id arrays with const or __initdata. 2008-08-31 01:23:17 -07:00
chipsfb.c
cirrusfb.c section fixes for cirrusfb 2008-11-01 12:40:38 -07:00
clps711xfb.c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
cobalt_lcdfb.c
controlfb.c
controlfb.h
cyber2000fb.c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
cyber2000fb.h
cyblafb.c
dnfb.c
edid.h
efifb.c efifb/imacfb consolidation + hardware support 2008-10-16 11:21:44 -07:00
epson1355fb.c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
fb_ddc.c
fb_defio.c fbdefio: add set_page_dirty handler to deferred IO FB 2008-08-20 15:40:32 -07:00
fb_draw.h
fb_notify.c
fb_sys_fops.c
fbcmap.c
fbcvt.c
fbmem.c fbdev: fix fb_compat_ioctl() deadlocks 2008-11-06 15:41:19 -08:00
fbmon.c fbmon: fix EDID parser to detect interlace modes 2008-10-16 11:21:44 -07:00
fbsysfs.c
ffb.c sparc: Annotate of_device_id arrays with const or __initdata. 2008-08-31 01:23:17 -07:00
fm2fb.c
fsl-diu-fb.c freescale DIU: bug fix: add sanity check for AOI position 2008-08-15 08:35:43 -07:00
fsl-diu-fb.h
g364fb.c
gbefb.c
gxt4500.c
hecubafb.c
hgafb.c
hitfb.c
hpfb.c
igafb.c
imsttfb.c
imxfb.c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
imxfb.h
Kconfig fbdev: add new framebuffer driver for Fujitsu MB862xx GDCs 2008-11-06 15:41:18 -08:00
leo.c leo: disable cursor when leaving graphics mode 2008-10-10 12:13:22 -07:00
macfb.c
macmodes.c
macmodes.h
Makefile fbdev: add new framebuffer driver for Fujitsu MB862xx GDCs 2008-11-06 15:41:18 -08:00
maxinefb.c
metronomefb.c metronomefb: Fix warning when building 64bit 2008-10-15 10:19:51 -07:00
modedb.c
n411.c
neofb.c neofb: remove open_lock mutex 2008-10-16 11:21:42 -07:00
offb.c
output.c
p9100.c sparc: Annotate of_device_id arrays with const or __initdata. 2008-08-31 01:23:17 -07:00
platinumfb.c
platinumfb.h
pm2fb.c pm2fb: free cmap memory on module remove 2008-08-20 15:40:31 -07:00
pm3fb.c
pmag-aa-fb.c
pmag-ba-fb.c
pmagb-b-fb.c
ps3fb.c
pvr2fb.c
pxafb.c [ARM] pxafb: fix the warning of incorrect lccr when lcd_conn is specified 2008-08-16 16:39:16 +01:00
pxafb.h
q40fb.c
s1d13xxxfb.c fbdev: allow more chip revisions in Epson s1d13... video driver 2008-10-16 11:21:45 -07:00
s3c2410fb.c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
s3c2410fb.h
s3fb.c removed unused #include <linux/version.h>'s 2008-08-23 12:14:12 -07:00
sa1100fb.c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach 2008-08-07 09:55:48 +01:00
sa1100fb.h
sbuslib.c
sbuslib.h
sgivwfb.c
sh7760fb.c
sh_mobile_lcdcfb.c video: add sh_mobile_lcdc platform flags 2008-10-20 11:38:50 +09:00
skeletonfb.c
sm501fb.c
sstfb.c
sticore.h
stifb.c
sunxvr500.c
sunxvr2500.c
svgalib.c
syscopyarea.c
sysfillrect.c
sysimgblt.c
tcx.c sparc: Annotate of_device_id arrays with const or __initdata. 2008-08-31 01:23:17 -07:00
tdfxfb.c tdfxfb: do not make changes to default tdfx_fix 2008-10-16 11:21:42 -07:00
tgafb.c
tmiofb.c fbdev: add new TMIO framebuffer driver 2008-10-16 11:21:45 -07:00
tridentfb.c
uvesafb.c uvesafb: don't treat mode info retrieval failures as errors 2008-10-16 11:21:44 -07:00
valkyriefb.c
valkyriefb.h
vesafb.c
vfb.c
vga16fb.c vga16fb: remove open_lock mutex 2008-10-16 11:21:42 -07:00
vgastate.c
vt8623fb.c removed unused #include <linux/version.h>'s 2008-08-23 12:14:12 -07:00
w100fb.c
w100fb.h
xen-fbfront.c xen: clean up domain mode predicates 2008-08-20 12:40:07 +02:00
xilinxfb.c removed unused #include <linux/version.h>'s 2008-08-23 12:14:12 -07:00