/* * Copyright 1998-2008 VIA Technologies, Inc. All Rights Reserved. * Copyright 2001-2008 S3 Graphics, Inc. All Rights Reserved. * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public * License as published by the Free Software Foundation; * either version 2, or (at your option) any later version. * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTIES OR REPRESENTATIONS; without even * the implied warranty of MERCHANTABILITY or FITNESS FOR * A PARTICULAR PURPOSE.See the GNU General Public License * for more details. * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #ifndef __GLOBAL_H__ #define __GLOBAL_H__ #include #include #include #include #include #include #include #include #include #include #include "debug.h" #include "viafbdev.h" #include "chip.h" #include "accel.h" #include "share.h" #include "dvi.h" #include "viamode.h" #include "hw.h" #include "lcd.h" #include "ioctl.h" #include "via_utility.h" #include "vt1636.h" #include "tblDPASetting.h" /* External struct*/ extern int viafb_platform_epia_dvi; extern int viafb_device_lcd_dualedge; extern int viafb_bus_width; extern int viafb_display_hardware_layout; extern struct offset offset_reg; extern struct viafb_par *viaparinfo; extern struct viafb_par *viaparinfo1; extern struct fb_info *viafbinfo; extern struct fb_info *viafbinfo1; extern int viafb_DeviceStatus; extern int viafb_refresh; extern int viafb_refresh1; extern int viafb_lcd_dsp_method; extern int viafb_lcd_mode; extern int viafb_CRT_ON; extern unsigned int viafb_second_xres; extern unsigned int viafb_second_yres; extern int viafb_hotplug_Xres; extern int viafb_hotplug_Yres; extern int viafb_hotplug_bpp; extern int viafb_hotplug_refresh; extern int viafb_primary_dev; extern int viafb_lcd_panel_id; #endif /* __GLOBAL_H__ */ 5f2'>diff
path: root/sound/i2c
diff options
context:
space:
mode:
authorNicolai Stange <nicstange@gmail.com>2016-12-07 22:21:33 +0100
committerTejun Heo <tj@kernel.org>2016-12-07 16:29:09 -0500
commite185934ff94466b4a449165e5f1c164a44d005f2 (patch)
treec773d05d4c72292e3babd4ce1a8bd56d965ebb4c /sound/i2c
parent5c3ef39738f74a3759918cc1a1ad099504f9d1b7 (diff)
libata-scsi: disable SCT Write Same for the moment
SCT Write Same support had been introduced with commit 7b2030942859 ("libata: Add support for SCT Write Same") Some problems, namely excessive userspace segfaults, had been reported at http://lkml.kernel.org/r/20160908192736.GA4356@gmail.com This lead to commit 0ce1b18c42a5 ("libata: Some drives failing on SCT Write Same") which strived to disable SCT Write Same on !ZAC devices. Due to the way this was done and to the logic in sd_config_write_same(), this didn't work for those devices that have ->max_ws_blocks > SD_MAX_WS10_BLOCKS: for these, ->no_write_same and ->max_write_same_sectors would still be non-zero, but ->ws10 == ->ws16 == 0. This would cause sd_setup_write_same_cmnd() to demultiplex REQ_OP_WRITE_SAME requests to WRITE_SAME, and these in turn aren't supported by libata-scsi: EXT4-fs (dm-1): Delayed block allocation failed for inode 2625094 at logical offset 2032 with max blocks 2 with error 121 EXT4-fs (dm-1): This should not happen!! Data will be lost 121 == EREMOTEIO is what scsi_io_completion() asserts in case of invalid opcodes. Back to the original problem of userspace segfaults: this can be tracked down to ata_format_sct_write_same() overwriting the input page. Sometimes, this page is ZERO_PAGE(0) which ceases to be filled with zeros from that point on. Since ZERO_PAGE(0) is used for userspace .bss mappings, code of the following is doomed: static char *a = NULL; /* .bss */ ... if (a) *a = 'a'; This problem is not solved by disabling SCT Write Same for !ZAC devices only. It can certainly be fixed, but the final release is quite close -- so disable SCT Write Same for all ATA devices rather than introducing some SCT key buffer allocation schemes at this point. Fixes: 7b2030942859 ("libata: Add support for SCT Write Same") Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'sound/i2c')