aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-05-30Merge remote-tracking branch 'regulator/fix/palmas' into regulator-linusMark Brown1-2/+2
2013-05-30Merge remote-tracking branch 'regulator/fix/doc' into regulator-linusMark Brown1-1/+4
2013-05-30Merge remote-tracking branch 'regulator/fix/dbx500' into regulator-linusMark Brown1-12/+12
2013-05-30Merge remote-tracking branch 'regulator/fix/core' into regulator-linusMark Brown1-1/+1
2013-05-30regulator: palmas: Fix "enable_reg" to point to the correct reg for SMPS10Kishon Vijay Abraham I1-1/+1
regulator_enable_regmap() uses enable_reg to enable the regulator. But enable_reg for smps10 points to SMPS10_STATUS which is a read-only register. Fixed the same by having enable_reg set to SMPS10_CTRL. Signed-off-by: Kishon Vijay Abraham I <[email protected]> Signed-off-by: Mark Brown <[email protected]> Cc: [email protected]
2013-05-30regulator: palmas: Fix incorrect conditionSachin Kamat1-1/+1
Since 'id' cannot take two values at the same time, the condition should probably be an OR (||) instead of AND (&&). Introduced by commit 28d1e8cd67 ("regulator: palma: add ramp delay support through regulator constraints"). Signed-off-by: Sachin Kamat <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2013-05-30Merge branch 'mn10300' (mn10300 fixes from David Howells)Linus Torvalds3-13/+9
Merge mn10300 fixes from David Howells. * emailed patches from David Howells <[email protected]>: MN10300: Need pci_iomap() and __pci_ioport_map() defining MN10300: ASB2305's PCI code needs the definition of XIRQ1 MN10300: Enable IRQs more in system call exit work path MN10300: Fix ret_from_kernel_thread
2013-05-30MN10300: Need pci_iomap() and __pci_ioport_map() definingDavid Howells1-0/+2
Include the generic definitions of pci_iomap() and __pci_ioport_map() otherwise we can get errors like: lib/pci_iomap.c: In function 'pci_iomap': lib/pci_iomap.c:37: error: implicit declaration of function '__pci_ioport_map' lib/pci_iomap.c:37: warning: return makes pointer from integer without a cast and: drivers/pci/quirks.c: In function 'disable_igfx_irq': drivers/pci/quirks.c:2893: error: implicit declaration of function 'pci_iomap' drivers/pci/quirks.c:2893: warning: initialization makes pointer from integer without a cast drivers/pci/quirks.c: In function 'reset_ivb_igd': drivers/pci/quirks.c:3133: warning: assignment makes pointer from integer without a cast Signed-off-by: David Howells <[email protected]> Acked-by: Ken Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-05-30MN10300: ASB2305's PCI code needs the definition of XIRQ1David Howells1-0/+1
The code for PCI in the ASB2305 needs the definition of XIRQ1 from proc/irq.h otherwise the following error appears: arch/mn10300/unit-asb2305/pci.c: In function 'unit_pci_init': arch/mn10300/unit-asb2305/pci.c:481: error: 'XIRQ1' undeclared (first use in this function) arch/mn10300/unit-asb2305/pci.c:481: error: (Each undeclared identifier is reported only once arch/mn10300/unit-asb2305/pci.c:481: error: for each function it appears in.) Signed-off-by: David Howells <[email protected]> Acked-by: Ken Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-05-30MN10300: Enable IRQs more in system call exit work pathDavid Howells1-13/+5
Enable IRQs when calling schedule() for TIF_NEED_RESCHED and do_notify_resume(). If interrupts are enabled during do_notify_resume(), a warning can be seen (see lower down). Whilst we're at it, resume_userspace can be made local to entry.S as it is not called outside of there and it can be merged with the part of work_resched that occurs after schedule() is called. WARNING: at kernel/softirq.c:160 local_bh_enable+0x42/0xa0() Call Trace: local_bh_enable+0x42/0xa0 unix_release_sock+0x86/0x23c unix_release+0x20/0x28 sock_release+0x17/0x88 sock_close+0x20/0x28 __fput+0xc9/0x1fc ____fput+0xb/0x10 task_work_run+0x64/0x78 do_notify_resume+0x53d/0x544 work_notifysig+0xa/0xc Signed-off-by: David Howells <[email protected]> Acked-by: Ken Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-05-30MN10300: Fix ret_from_kernel_threadDavid Howells1-0/+1
ret_from_kernel_thread needs to set A2 to the thread_info pointer before jumping to syscall_exit. Without this, we never correctly start userspace. This was caused by the rejuggling of the fork/exec paths in commit ddf23e87a804 ("mn10300: switch to saner kernel_execve() semantics") Reported-by: Ken Cox <[email protected]> Signed-off-by: David Howells <[email protected]> Acked-by: Ken Cox <[email protected]> Acked-by: Al Viro <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-05-29ib_srpt: Call target_sess_cmd_list_set_waiting during shutdown_sessionNicholas Bellinger2-8/+25
Given that srpt_release_channel_work() calls target_wait_for_sess_cmds() to allow outstanding se_cmd_t->cmd_kref a change to complete, the call to perform target_sess_cmd_list_set_waiting() needs to happen in srpt_shutdown_session() Also, this patch adds an explicit call to srpt_shutdown_session() within srpt_drain_channel() so that target_sess_cmd_list_set_waiting() will be called in the cases where TFO->shutdown_session() is not triggered directly by TCM. Cc: Joern Engel <[email protected]> Cc: Roland Dreier <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-05-29target: Re-instate sess_wait_list for target_wait_for_sess_cmdsNicholas Bellinger2-4/+15
Switch back to pre commit 1c7b13fe652 list splicing logic for active I/O shutdown with tcm_qla2xxx + ib_srpt fabrics. The original commit was done under the incorrect assumption that it's safe to walk se_sess->sess_cmd_list unprotected in target_wait_for_sess_cmds() after sess->sess_tearing_down = 1 has been set by target_sess_cmd_list_set_waiting() during session shutdown. So instead of adding sess->sess_cmd_lock protection around sess->sess_cmd_list during target_wait_for_sess_cmds(), switch back to sess->sess_wait_list to allow wait_for_completion() + TFO->release_cmd() to occur without having to walk ->sess_cmd_list after the list_splice. Also add a check to exit if target_sess_cmd_list_set_waiting() has already been called, and add a WARN_ON to check for any fabric bug where new se_cmds are added to sess->sess_cmd_list after sess->sess_tearing_down = 1 has already been set. Cc: Joern Engel <[email protected]> Cc: Roland Dreier <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-05-30Merge tag 'pinctrl-fixes-v3.10-3' of ↵Linus Torvalds9-11/+323
git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl Pull pin-control fixes from Linus Walleij: - Six patches fixing up the suspend/resume and wakeup handling of the Samsung and Exynos drivers. - Errorpath fixes for four different drivers. All on the probe() errorpath. - Make the debugfs code for pin config take the right mutex. * tag 'pinctrl-fixes-v3.10-3' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: pinctrl: pinconf: take the right mutex pinctrl: sunxi: fix error return code in sunxi_pinctrl_probe() pinctrl: exynos: Handle suspend/resume of GPIO EINT registers pinctrl: samsung: Allow per-bank SoC-specific private data pinctrl: samsung: Add support for SoC-specific suspend/resume callbacks pinctrl: Don't override the error code in probe error handling ARM: EXYNOS: Fix EINT wake-up mask configuration when pinctrl is used pinctrl: exynos: Add support for set_irq_wake of wake-up EINTs pinctrl: samsung: fix suspend/resume functionality
2013-05-30Merge branch 'drm-fixes-3.10' of git://people.freedesktop.org/~agd5f/linux ↵Dave Airlie5-36/+25
into drm-next just a few minor fixes for radeon. * 'drm-fixes-3.10' of git://people.freedesktop.org/~agd5f/linux: radeon: use max_bus_speed to activate gen2 speeds drm/radeon: narrow scope of Apple re-POST hack drm/radeon: don't check crtcs in card_posted() on cards without DCE drm/radeon: fix card_posted check for newer asics drm/radeon: fix typo in cu_per_sh on verde drm/radeon: UVD block on SUMO2 is the same as on SUMO
2013-05-29clk: vt8500: Fix unbalanced spinlock in vt8500_dclk_set_rate()Tony Prisk1-1/+1
With the addition of a DVO clock, a bug is now evident in the vt8500 clock code: [ 0.290000] WARNING: at init/main.c:698 do_one_initcall+0x158/0x18c() [ 0.300000] initcall wm8505fb_driver_init+0x0/0xc returned with disabled int This is caused by an unbalanced spinlock in vt8500_dclk_set_rate(). Replace the second call to spin_lock_irqsave() with spin_unlock_irqrestore(). Signed-off-by: Tony Prisk <[email protected]> Signed-off-by: Mike Turquette <[email protected]>
2013-05-30kconfig/menu.c: fix multiple references to expressions in menu_add_prop()Dirk Gouders1-1/+14
menu_add_prop() applies upper menus' visibilities to actual prompts by AND-ing the prompts visibilities with the upper menus ones. This creates a further reference to the menu's visibilities and when the expression reduction functions do their work, they may remove or modify expressions that have multiple references, thus causing unpredictable side-effects. The following example Kconfig constructs a case where this causes problems: a menu and a prompt which's visibilities depend on the same symbol. When invoking mconf with this Kconfig and pressing "Z" we see a problem caused by a free'd expression still referenced by the menu's visibility: ------------------------------------------------------------------------ mainmenu "Kconfig Testing Configuration" config VISIBLE def_bool n config Placeholder bool "Place holder" menu "Invisible" visible if VISIBLE config TEST_VAR bool "Test option" if VISIBLE endmenu ------------------------------------------------------------------------ This patch fixes this problem by creating copies of the menu's visibility expressions before AND-ing them with the prompt's one. Signed-off-by: Dirk Gouders <[email protected]> [[email protected]: move variable into its block-scope, keep lines <80 chars, typo] Tested-by: "Yann E. MORIN" <[email protected]> Reviewed-by: "Yann E. MORIN" <[email protected]> Signed-off-by: "Yann E. MORIN" <[email protected]>
2013-05-30mconf: handle keys in empty dialogsDirk Gouders2-9/+11
When entering an empty dialog, using the movement keys resulted in unexpected characters beeing displayed, other keys like "z" and "h" did not work as expected. This patch handles the movement keys as well as other keys, especially "z", "h" and "/". Signed-off-by: Dirk Gouders <[email protected]> [[email protected]: keep lines <80 chars, so reorder test] Tested-by: "Yann E. MORIN" <[email protected]> Reviewed-by: "Yann E. MORIN" <[email protected]> Signed-off-by: "Yann E. MORIN" <[email protected]>
2013-05-29clk: si5351: Set initial clkout rate when defined in platform data.Marek Belisko1-0/+10
clock-frequency property from platform data was read but never used. Apply defined rate when clock is registered. Signed-off-by: Marek Belisko <[email protected]> Acked-by: Sebastian Hesselbarth <[email protected]> Signed-off-by: Mike Turquette <[email protected]> [[email protected]: add missing changelog] Cc: [email protected] Signed-off-by: Mike Turquette <[email protected]>
2013-05-29clk: si5351: Fix clkout rate computation.Marek Belisko1-1/+1
Rate was incorrectly computed because we read from wrong divider register. Signed-off-by: Marek Belisko <[email protected]> Acked-by: Sebastian Hesselbarth <[email protected]> Signed-off-by: Mike Turquette <[email protected]> Cc: [email protected]
2013-05-29NFSv4: Fix a thinko in nfs4_try_open_cachedTrond Myklebust1-1/+1
We need to pass the full open mode flags to nfs_may_open() when doing a delegated open. Signed-off-by: Trond Myklebust <[email protected]> Cc: [email protected]
2013-05-29xenbus_client.c: correct exit path for xenbus_map_ring_valloc_hvmWei Liu1-2/+3
Apparently we should not free page that has not been allocated. This is b/c alloc_xenballooned_pages will take care of freeing the page on its own. Signed-off-by: Wei Liu <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
2013-05-29clk: samsung: Add CLK_IGNORE_UNUSED flag for the sysreg clocksSylwester Nawrocki1-2/+4
Currently no driver *) handles the sysreg clock, with an assumption that this clock is always left in its default state (enabled). Before commit 6e6aac7590f902d14d90bace3fd499 ARM: EXYNOS: Migrate clock support to common clock framework the sysreg clock was not even defined and hence wasn't handled explicitly in the kernel. To restore the previous behaviour disable masking the sysreg clock off in the clock core by default. *) Except the Exynos4x12 FIMC-IS driver, which will be modified to not touch the sysreg clock. Signed-off-by: Sylwester Nawrocki <[email protected]> Signed-off-by: Kyungmin Park <[email protected]> Signed-off-by: Mike Turquette <[email protected]>
2013-05-29clk: ux500: clk-sysctrl: handle clocks with no parentsFabio Baltieri1-1/+7
Fix clk_reg_sysctrl() to set main clock registers of new struct clk_sysctrl even if the registered clock has no parents. This fixes an issue where "ulpclk" was registered with all clk->reg_* fields uninitialized, causing a -EINVAL error from clk_prepare(). Signed-off-by: Fabio Baltieri <[email protected]> Acked-by: Ulf Hansson <[email protected]> Signed-off-by: Mike Turquette <[email protected]>
2013-05-29clk: ux500: Provide device enumeration number suffix for SMSC911xLee Jones1-1/+1
First Ethernet device has a ".0" appended onto the device name. It appears that we need this in order to obtain the correct clock. Without this fix Ethernet does not function on Ux500 devices, which is a regression. Cc: Ulf Hansson <[email protected]> Signed-off-by: Lee Jones <[email protected]> Signed-off-by: Mike Turquette <[email protected]> [[email protected]: improved changelog]
2013-05-29radeon: use max_bus_speed to activate gen2 speedsKleber Sacilotto de Souza3-21/+7
radeon currently uses a drm function to get the speed capabilities for the bus, drm_pcie_get_speed_cap_mask. However, this is a non-standard method of performing this detection and this patch changes it to use the max_bus_speed attribute. From: Lucas Kannebley Tavares <[email protected]> Signed-off-by: Kleber Sacilotto de Souza <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2013-05-29drm/radeon: narrow scope of Apple re-POST hackAlex Deucher1-1/+3
This narrows the scope of the apple re-POST hack added in: drm/radeon: re-POST the asic on Apple hardware when booted via EFI That patch prevents UVD from working on macs when booted in EFI mode. The original patch fixed macbook2,1 systems which were r5xx and hence have no UVD. Limit the hack to those systems to prevent UVD breakage on newer systems. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=63935 Cc: Matthew Garrett <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Acked-by: Matthew Garrett <[email protected]>
2013-05-29ipvs: ip_vs_sh: fix buildJan Beulich1-1/+1
kfree_rcu() requires offsetof(..., rcu_head) < 4096, which can get violated with a sufficiently high CONFIG_IP_VS_SH_TAB_BITS. Signed-off-by: Jan Beulich <[email protected]> Signed-off-by: Simon Horman <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]>
2013-05-29drm/radeon: don't check crtcs in card_posted() on cards without DCEAlex Deucher1-0/+4
Skip checking crtcs in hardware without them. Avoids checking non-existent hardware. Signed-off-by: Alex Deucher <[email protected]>
2013-05-29drm/radeon: fix card_posted check for newer asicsAlex Deucher1-10/+9
Newer asics have variable numbers of crtcs. Use that rather than the asic family to determine which crtcs to check. This avoids checking non-existent crtcs or missing crtcs on certain asics. Reviewed-by: Michel Dänzer <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
2013-05-29drm/radeon: fix typo in cu_per_sh on verdeAlex Deucher1-1/+1
Should be 5 rather than 2. Noticed by sroland and glisse on IRC. Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
2013-05-29drm/radeon: UVD block on SUMO2 is the same as on SUMOChristian König1-3/+1
The chip id for SUMO2 isn't used. fixes: https://bugs.freedesktop.org/show_bug.cgi?id=63935 Tested-By: Dave Witbrodt <[email protected]> Signed-off-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2013-05-29Merge branch 'master' of ↵John W. Linville27-235/+301
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless into for-davem
2013-05-29svcrpc: fix failures to handle -1 uid's and gid'sJ. Bruce Fields1-5/+7
As of f025adf191924e3a75ce80e130afcd2485b53bb8 "sunrpc: Properly decode kuids and kgids in RPC_AUTH_UNIX credentials" any rpc containing a -1 (0xffff) uid or gid would fail with a badcred error. Reported symptoms were xmbc clients failing on upgrade of the NFS server; examination of the network trace showed them sending -1 as the gid. Reported-by: Julian Sikorski <[email protected]> Tested-by: Julian Sikorski <[email protected]> Cc: "Eric W. Biederman" <[email protected]> Cc: [email protected] Signed-off-by: J. Bruce Fields <[email protected]>
2013-05-29xen-pciback: more uses of cached MSI-X capability offsetJan Beulich1-2/+2
Signed-off-by: Jan Beulich <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
2013-05-29xen: Clean up apic ipi interfaceStefan Bader2-7/+4
Commit f447d56d36af18c5104ff29dcb1327c0c0ac3634 introduced the implementation of the PV apic ipi interface. But there were some odd things (it seems none of which cause really any issue but maybe they should be cleaned up anyway): - xen_send_IPI_mask_allbutself (and by that xen_send_IPI_allbutself) ignore the passed in vector and only use the CALL_FUNCTION_SINGLE vector. While xen_send_IPI_all and xen_send_IPI_mask use the vector. - physflat_send_IPI_allbutself is declared unnecessarily. It is never used. This patch tries to clean up those things. Signed-off-by: Stefan Bader <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
2013-05-29xenbus: save xenstore local status for later useAurelien Chartier3-15/+20
Save the xenstore local status computed in xenbus_init. It can then be used later to check if xenstored is running in this domain. Signed-off-by: Aurelien Chartier <[email protected]> [Changes in v4: - Change variable name to xen_store_domain_type] Reviewed-by: David Vrabel <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
2013-05-29xenbus: delay xenbus frontend resume if xenstored is not runningAurelien Chartier2-1/+37
If the xenbus frontend is located in a domain running xenstored, the device resume is hanging because it is happening before the process resume. This patch adds extra logic to the resume code to check if we are the domain running xenstored and delay the resume if needed. Signed-off-by: Aurelien Chartier <[email protected]> [Changes in v2: - Instead of bypassing the resume, process it in a workqueue] [Changes in v3: - Add a struct work in xenbus_device to avoid dynamic allocation - Several small code fixes] [Changes in v4: - Use a dedicated workqueue] [Changes in v5: - Move create_workqueue error handling to xenbus_frontend_dev_resume] Acked-by: Jan Beulich <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
2013-05-29Merge tag 'asoc-v3.10-rc3' of ↵Takashi Iwai841-5717/+9100
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Updates for v3.10 A series of driver specific updates, none particularly critical, plus one fix to the compressed API code to handle capture streams properly which is very safe for mainline as there's no current users.
2013-05-29netfilter: xt_LOG: fix mark logging for IPv6 packetsMichal Kubeček1-1/+1
In dump_ipv6_packet(), the "recurse" parameter is zero only if dumping contents of a packet embedded into an ICMPv6 error message. Therefore we want to log packet mark if recurse is non-zero, not when it is zero. Signed-off-by: Michal Kubecek <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]>
2013-05-29Merge tag 'fixes-for-linus' of ↵Linus Torvalds7-17/+107
git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM Exynos fixes from Olof Johansson: "Here's a shorter set of fixes for 3.10, all for Samsung Exynos platforms. It also includes a defconfig update so that exynos_defconfig provides a meaningful set of drivers to boot an unmodified kernel on the Samsung ARM-based Chromebooks." * tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: ARM: exynos: defconfig update ARM: SAMSUNG: Add names to fimd0 IRQ resources ARM: EXYNOS: fix software reset logic for EXYNOS5440 SOC ARM: EXYNOS: Fix support of Exynos4210 rev0 SoC ARM: dts: Enabling samsung-usb2phy driver for exynos5250
2013-05-29Merge branch 'fbdev-3.10-fixes' of git://gitorious.org/linux-omap-dss2/linux ↵Jean-Christophe PLAGNIOL-VILLARD6-2/+30
into linux-fbdev/for-3.10-fixes Pull Tomi fixes for ps3fb and omap2 Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[email protected]>
2013-05-29usbfs: Increase arbitrary limit for USB 3 isopkt lengthFederico Manzan1-3/+7
Increase the current arbitrary limit for isocronous packet size to a value large enough to account for USB 3.0 super bandwidth streams, bMaxBurst (0~15 allowed, 1~16 packets) bmAttributes (bit 1:0, mult 0~2, 1~3 packets) so the size max for one USB 3 isocronous transfer is 1024 byte * 16 * 3 = 49152 byte Acked-by: Alan Stern <[email protected]> Signed-off-by: Federico Manzan <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-05-29tuntap: forbid changing mq flag for persistent deviceJason Wang1-0/+4
We currently allow changing the mq flag (IFF_MULTI_QUEUE) for a persistent device. This will result a mismatch between the number the queues in netdev and tuntap. This is because we only allocate a 1q netdevice when IFF_MULTI_QUEUE was not specified, so when we set the IFF_MULTI_QUEUE and try to attach more queues later, netif_set_real_num_tx_queues() may fail which result a single queue netdevice with multiple sockets attached. Solve this by disallowing changing the mq flag for persistent device. Bug was introduced by commit edfb6a148ce62e5e19354a1dcd9a34e00815c2a1 (tuntap: reduce memory using of queues). Reported-by: Sriram Narasimhan <[email protected]> Cc: Michael S. Tsirkin <[email protected]> Signed-off-by: Jason Wang <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-05-28net/core/sock.c: add missing VSOCK string in af_family_*_key_stringsFederico Vaga1-3/+3
The three arrays of strings: af_family_key_strings, af_family_slock_key_strings and af_family_clock_key_strings have not VSOCK's string Signed-off-by: Federico Vaga <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-05-28net: Block MSG_CMSG_COMPAT in send(m)msg and recv(m)msgAndy Lutomirski1-2/+31
To: [email protected] Cc: [email protected], [email protected], Andy Lutomirski <[email protected]>, [email protected], "David S. Miller" <[email protected]> Subject: [PATCH 5/5] net: Block MSG_CMSG_COMPAT in send(m)msg and recv(m)msg MSG_CMSG_COMPAT is (AFAIK) not intended to be part of the API -- it's a hack that steals a bit to indicate to other networking code that a compat entry was used. So don't allow it from a non-compat syscall. This prevents an oops when running this code: int main() { int s; struct sockaddr_in addr; struct msghdr *hdr; char *highpage = mmap((void*)(TASK_SIZE_MAX - 4096), 4096, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED, -1, 0); if (highpage == MAP_FAILED) err(1, "mmap"); s = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP); if (s == -1) err(1, "socket"); addr.sin_family = AF_INET; addr.sin_port = htons(1); addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); if (connect(s, (struct sockaddr*)&addr, sizeof(addr)) != 0) err(1, "connect"); void *evil = highpage + 4096 - COMPAT_MSGHDR_SIZE; printf("Evil address is %p\n", evil); if (syscall(__NR_sendmmsg, s, evil, 1, MSG_CMSG_COMPAT) < 0) err(1, "sendmmsg"); return 0; } Cc: David S. Miller <[email protected]> Signed-off-by: Andy Lutomirski <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-05-29USB: zte_ev: fix control-message timeoutsJohan Hovold1-14/+14
The control-message timeout is specified in milliseconds and should not depend on HZ. Cc: [email protected] Signed-off-by: Johan Hovold <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-05-29USB: mos7720: fix message timeoutsJohan Hovold1-3/+3
The control and bulk-message timeouts are specified in milliseconds and should not depend on HZ. Cc: [email protected] Signed-off-by: Johan Hovold <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-05-29USB: iuu_phoenix: fix bulk-message timeoutJohan Hovold1-2/+2
The bulk-message timeout is specified in milliseconds and should not depend on HZ. Cc: [email protected] Signed-off-by: Johan Hovold <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-05-29USB: ark3116: fix control-message timeoutJohan Hovold1-1/+1
The control-message timeout is specified in milliseconds and should not depend on HZ. Cc: [email protected] Signed-off-by: Johan Hovold <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>