Linux 3.10.47
Greg KH
maintainerI'm announcing the release of the 3.10.47 kernel.
All users of the 3.10 kernel series must upgrade.
The updated 3.10.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-3.10.y
and can be browsed at the normal kernel.org git web browser:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/SubmittingPatches | 22 ++++ Makefile | 2 arch/mips/kernel/irq-msc01.c | 2 arch/mips/kvm/kvm_mips.c | 13 -- arch/powerpc/include/asm/systbl.h | 2 arch/powerpc/include/uapi/asm/cputable.h | 1 arch/powerpc/kernel/cputable.c | 3 arch/powerpc/kernel/time.c | 2 arch/powerpc/lib/sstep.c | 2 arch/powerpc/platforms/pseries/eeh_pseries.c | 1 arch/x86/include/asm/ptrace.h | 16 +++ drivers/block/mtip32xx/mtip32xx.c | 123 +++++++++++++++++++-------- drivers/extcon/extcon-max77693.c | 4 drivers/infiniband/core/user_mad.c | 75 +++++++++------- drivers/infiniband/hw/ipath/ipath_diag.c | 4 drivers/infiniband/hw/qib/qib_mad.c | 2 drivers/infiniband/ulp/srp/ib_srp.c | 6 + drivers/input/mouse/elantech.c | 27 ++++- drivers/misc/mei/hw-me.c | 28 ++++-- drivers/pci/pci.c | 2 drivers/pci/quirks.c | 1 drivers/target/iscsi/iscsi_target.c | 2 drivers/target/iscsi/iscsi_target_util.c | 2 drivers/target/target_core_device.c | 1 drivers/watchdog/ath79_wdt.c | 10 ++ drivers/watchdog/sp805_wdt.c | 4 fs/nfs/inode.c | 26 +++-- fs/nfs/nfs4filelayout.c | 2 fs/nfsd/nfs4state.c | 2 fs/nfsd/nfs4xdr.c | 4 fs/nfsd/nfscache.c | 53 ++--------- fs/reiserfs/inode.c | 8 + fs/ubifs/file.c | 3 fs/ubifs/shrinker.c | 1 include/linux/ptrace.h | 3 include/trace/syscall.h | 15 +++ kernel/fork.c | 2 kernel/trace/trace.c | 13 +- net/ipv4/netfilter/ipt_ULOG.c | 7 - net/netfilter/ipvs/ip_vs_core.c | 15 ++- net/sunrpc/svc_xprt.c | 2 scripts/recordmcount.h | 4 42 files changed, 338 insertions(+), 179 deletions(-)
Alex Smith (1):
recordmcount/MIPS: Fix possible incorrect mcount_loc table entries in modules
Anton Blanchard (1):
powerpc: 64bit sendfile is capped at 2GB
Asai Thambi S P (3):
mtip32xx: Fix ERO and NoSnoop values in PCIe upstream on AMD systems
mtip32xx: Increase timeout for STANDBY IMMEDIATE command
mtip32xx: Remove dfs_parent after pci unregister
Bart Van Assche (3):
IB/srp: Fix a sporadic crash triggered by cable pulling IB/umad: Fix error handling
IB/umad: Fix use-after-free on close
Benjamin Herrenschmidt (1):
powerpc: Add AT_HWCAP2 to indicate V.CRYPTO category support
Bjorn Helgaas (1):
PCI: Fix incorrect vgaarb conditional in WARN_ON()
Christoph Hellwig (1):
nfsd: getattr for FATTR4_WORD0_FILES_AVAIL needs the statfs buffer
Deng-Cheng Zhu (1):
MIPS: KVM: Fix memory leak on VCPU
Dennis Dalessandro (1):
IB/ipath: Translate legacy diagpkt into newer extended diagpkt
Gabor Juhos (1):
watchdog: ath79_wdt: avoid spurious restarts on AR934x
Gavin Shan (1):
powerpc/pseries: Fix overwritten PE state
Greg Kroah-Hartman (1):
Linux 3.10.47
Hans de Goede (2):
Input: elantech - deal with clickpads reporting right button events
Input: elantech - don't set bit 1 of reg_10 when the no_hw_res quirk is set
J. Bruce Fields (1):
nfsd4: fix FREE_STATEID lockowner leak
Jacob Keller (1):
Documentation/SubmittingPatches: describe the Fixes: tag
James Hogan (1):
MIPS: KVM: Remove redundant NULL checks before kfree()
Jeff Layton (2):
nfsd: don't try to reuse an expired DRC entry off the list
nfsd: don't halt scanning the DRC LRU list when there's an RC_INPROG entry
Jeff Mahoney (1):
reiserfs: call truncate_setsize under tailpack mutex
Krzysztof Kozlowski (1):
extcon: max77693: Fix two NULL pointer exceptions on missing pdata
Markos Chandras (1):
MIPS: MSC: Prevent out-of-bounds writes to MIPS SC ioremap'd region
Mathias Krause (1):
netfilter: ipt_ULOG: fix info leaks
Mike Marciniszyn (1):
IB/qib: Fix port in pkey change event
Nicholas Bellinger (3):
target: Fix left-over se_lun->lun_sep pointer OOPs
iscsi-target: Avoid rejecting incorrect ITT for Data-Out
iscsi-target: Explicily clear login response PDU in exception path
Oleg Nesterov (1):
tracing: Fix syscall_*regfunc() vs copy_process() race
Paul Bolle (2):
powerpc: fix typo 'CONFIG_PMAC'
powerpc: fix typo 'CONFIG_PPC_CPU'
Peter Christensen (1):
ipvs: Fix panic due to non-linear skb
Steven Rostedt (Red Hat) (1):
tracing: Try again for saved cmdline if failed due to locking
Tejun Heo (1):
ptrace,x86: force IRET path after a ptrace_stop()
Thomas Jarosch (1):
PCI: Add new ID for Intel GPU "spurious interrupt" quirk
Tomas Winkler (2):
mei: me: read H_CSR after asserting reset
mei: me: fix hw ready reset flow
Trond Myklebust (3):
SUNRPC: Fix a module reference leak in svc_handle_xprt
pNFS: Handle allocation errors correctly in filelayout_alloc_layout_hdr()
NFS: Don't declare inode uptodate unless all attributes were checked
Viresh Kumar (1):
watchdog: sp805: Set watchdog_device->timeout from ->set_timeout()
hujianyang (2):
UBIFS: fix an mmap and fsync race condition
UBIFS: Remove incorrect assertion in shrink_tnc()
Greg KH
maintainerDocumentation/SubmittingPatches +21 -1
@@ -131,6 +131,20 @@ If you cannot condense your patch set into a smaller set of patches, then only post say 15 or so at a time and wait for review and integration. +If your patch fixes a bug in a specific commit, e.g. you found an issue using +git-bisect, please use the 'Fixes:' tag with the first 12 characters of the +SHA-1 ID, and the one line summary. +Example: + + Fixes: e21d2170f366 ("video: remove unnecessary platform_set_drvdata()") + +The following git-config settings can be used to add a pretty format for +outputting the above style in the git log or git show commands + + [core] + abbrev = 12 + [pretty] + fixes = Fixes: %h (\"%s\") 4) Style check your changes.
@@ -420,7 +434,7 @@ person it names. This tag documents that potentially interested parties have been included in the discussion -14) Using Reported-by:, Tested-by:, Reviewed-by: and Suggested-by: +14) Using Reported-by:, Tested-by:, Reviewed-by:, Suggested-by: and Fixes: If this patch fixes a problem reported by somebody else, consider adding a Reported-by: tag to credit the reporter for their contribution. Please
@@ -475,6 +489,12 @@ idea was not posted in a public forum. That said, if we diligently credit our idea reporters, they will, hopefully, be inspired to help us again in the future. +A Fixes: tag indicates that the patch fixes an issue in a previous commit. It +is used to make it easy to determine where a bug originated, which can help +review a bug fix. This tag also assists the stable kernel team in determining +which stable kernel versions should receive your fix. This is the preferred +method for indicating a bug fixed by the patch. See #2 above for more details. + 15) The canonical patch format
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 3 PATCHLEVEL = 10 -SUBLEVEL = 46 +SUBLEVEL = 47 EXTRAVERSION = NAME = TOSSUG Baby Fish
arch/mips/kernel/irq-msc01.c +1 -1
@@ -131,7 +131,7 @@ void __init init_msc_irqs(unsigned long icubase, unsigned int irqbase, msc_irqma board_bind_eic_interrupt = &msc_bind_eic_interrupt; -for (; nirq >=0 ; nirq--, imp++) { +for (; nirq >0 ; nirq--, imp++) {int n = imp->im_irq;switch (imp->im_type) {
arch/mips/kvm/kvm_mips.c +4 -9
@@ -149,9 +149,7 @@ void kvm_mips_free_vcpus(struct kvm *kvm)if (kvm->arch.guest_pmap[i] !=KVM_INVALID_PAGE )kvm_mips_release_pfn_clean (kvm->arch.guest_pmap[i]); } - -if (kvm->arch.guest_pmap) -kfree (kvm->arch.guest_pmap); +kfree (kvm->arch.guest_pmap);kvm_for_each_vcpu (i, vcpu, kvm) {kvm_arch_vcpu_free (vcpu);
@@ -384,12 +382,9 @@ void kvm_arch_vcpu_free(struct kvm_vcpu *vcpu)kvm_mips_dump_stats (vcpu); -if (vcpu->arch.guest_ebase) -kfree (vcpu->arch.guest_ebase); - -if (vcpu->arch.kseg0_commpage) -kfree (vcpu->arch.kseg0_commpage); - +kfree (vcpu->arch.guest_ebase); +kfree (vcpu->arch.kseg0_commpage); +kfree (vcpu); }void kvm_arch_vcpu_destroy (struct kvm_vcpu *vcpu)
arch/powerpc/include/asm/systbl.h +1 -1
@@ -190,7 +190,7 @@ SYSCALL_SPU(getcwd) SYSCALL_SPU(capget) SYSCALL_SPU(capset) COMPAT_SYS(sigaltstack) -COMPAT_SYS_SPU(sendfile) +SYSX_SPU(sys_sendfile64,compat_sys_sendfile,sys_sendfile) SYSCALL(ni_syscall) SYSCALL(ni_syscall) PPC_SYS(vfork)
arch/powerpc/include/uapi/asm/cputable.h +1 -0
@@ -41,5 +41,6 @@#define PPC_FEATURE2_EBB 0x10000000#define PPC_FEATURE2_ISEL 0x08000000#define PPC_FEATURE2_TAR 0x04000000 +#define PPC_FEATURE2_VEC_CRYPTO 0x02000000#endif /* _UAPI__ASM_POWERPC_CPUTABLE_H */
arch/powerpc/kernel/cputable.c +2 -1
@@ -105,7 +105,8 @@ extern void __restore_cpu_e6500(void); PPC_FEATURE_PSERIES_PERFMON_COMPAT)#define COMMON_USER2_POWER8 (PPC_FEATURE2_ARCH_2_07 | \ PPC_FEATURE2_HTM_COMP | PPC_FEATURE2_DSCR | \ - PPC_FEATURE2_ISEL | PPC_FEATURE2_TAR) + PPC_FEATURE2_ISEL | PPC_FEATURE2_TAR | \ + PPC_FEATURE2_VEC_CRYPTO)#define COMMON_USER_PA6T (COMMON_USER_PPC64 | PPC_FEATURE_PA6T |\ PPC_FEATURE_TRUE_LE | \ PPC_FEATURE_HAS_ALTIVEC_COMP)
arch/powerpc/kernel/time.c +1 -1
@@ -512,7 +512,7 @@ void timer_interrupt(struct pt_regs * regs)__get_cpu_var (irq_stat).timer_irqs++; -#if defined(CONFIG_PPC32 ) && defined(CONFIG_PMAC ) +#if defined(CONFIG_PPC32 ) && defined(CONFIG_PPC_PMAC )if (atomic_read (&ppc_n_lost_interrupts) !=0 )do_IRQ (regs);#endif
arch/powerpc/lib/sstep.c +1 -1
@@ -1395,7 +1395,7 @@ int __kprobes emulate_step(struct pt_regs *regs, unsigned int instr) regs->gpr[rd] =byterev_4 (val); goto ldst_done; -#ifdef CONFIG_PPC_CPU +#ifdef CONFIG_PPC_FPU case 535 :/* lfsx */ case 567 :/* lfsux */ if (!(regs->msr &MSR_FP ))
arch/powerpc/platforms/pseries/eeh_pseries.c +1 -0
@@ -400,6 +400,7 @@ static int pseries_eeh_get_state(struct eeh_pe *pe, int *state) }else { result =EEH_STATE_NOT_SUPPORT ; } +break ;default : result =EEH_STATE_NOT_SUPPORT ; }
arch/x86/include/asm/ptrace.h +16 -0
@@ -232,6 +232,22 @@ static inline unsigned long regs_get_kernel_stack_nth(struct pt_regs *regs,#define ARCH_HAS_USER_SINGLE_STEP_INFO +/* +* When hitting ptrace_stop(), we cannot return using SYSRET because +* that does not restore the full CPU state, only a minimal set. The +* ptracer can change arbitrary register values, which is usually okay +* because the usual ptrace stops run off the signal delivery path which +* forces IRET; however, ptrace_event() stops happen in arbitrary places +* in the kernel and don't force IRET path. +* +* So force IRET path after a ptrace stop. +*/ +#define arch_ptrace_stop_needed (code, info) \ +({ \ + set_thread_flag(TIF_NOTIFY_RESUME); \ + false; \ +}) +struct user_desc ;extern int do_get_thread_area (struct task_struct *p,int idx,struct user_desc __user *info);
drivers/block/mtip32xx/mtip32xx.c +90 -33
176 lines not on this page · raw message
drivers/extcon/extcon-max77693.c +2 -2
@@ -1180,7 +1180,7 @@ static int max77693_muic_probe(struct platform_device *pdev)/* Initialize MUIC register by using platform data or default data */ -if (pdata->muic_data) { +if (pdata && pdata->muic_data) { init_data = pdata->muic_data->init_data; num_init_data = pdata->muic_data->num_init_data; }else {
@@ -1213,7 +1213,7 @@ static int max77693_muic_probe(struct platform_device *pdev) = init_data[i].data; } -if (pdata->muic_data) { +if (pdata && pdata->muic_data) {struct max77693_muic_platform_data *muic_pdata = pdata->muic_data;/*
drivers/infiniband/core/user_mad.c +44 -31
185 lines not on this page · raw message
drivers/infiniband/hw/ipath/ipath_diag.c +4 -0
@@ -346,6 +346,10 @@ static ssize_t ipath_diagpkt_write(struct file *fp, ret = -EFAULT ; goto bail; } + dp.len = odp.len; + dp.unit = odp.unit; + dp.data = odp.data; + dp.pbc_wd =0 ; }else { ret = -EINVAL ; goto bail;
drivers/infiniband/hw/qib/qib_mad.c +1 -1
@@ -1028,7 +1028,7 @@ static int set_pkeys(struct qib_devdata *dd, u8 port, u16 *pkeys) event.event =IB_EVENT_PKEY_CHANGE ; event.device = &dd->verbs_dev.ibdev; - event.element.port_num =1 ; + event.element.port_num = port;ib_dispatch_event (&event); }return 0 ;
drivers/infiniband/ulp/srp/ib_srp.c +6 -0
@@ -1409,6 +1409,12 @@ err_unmap: err_iu:srp_put_tx_iu (target, iu,SRP_IU_CMD ); +/* +* Avoid that the loops that iterate over the request ring can +* encounter a dangling SCSI command pointer. +*/ + req->scmnd =NULL ; +spin_lock_irqsave (&target->lock, flags);list_add (&req->list, &target->free_reqs);
drivers/input/mouse/elantech.c +21 -6
@@ -473,8 +473,15 @@ static void elantech_report_absolute_v3(struct psmouse *psmouse,input_report_key (dev,BTN_TOOL_FINGER , fingers ==1 );input_report_key (dev,BTN_TOOL_DOUBLETAP , fingers ==2 );input_report_key (dev,BTN_TOOL_TRIPLETAP , fingers ==3 ); -input_report_key (dev,BTN_LEFT , packet[0 ] &0x01 ); -input_report_key (dev,BTN_RIGHT , packet[0 ] &0x02 ); + +/* For clickpads map both buttons to BTN_LEFT */ +if (etd->fw_version &0x001000 ) { +input_report_key (dev,BTN_LEFT , packet[0 ] &0x03 ); + }else { +input_report_key (dev,BTN_LEFT , packet[0 ] &0x01 ); +input_report_key (dev,BTN_RIGHT , packet[0 ] &0x02 ); + } +input_report_abs (dev,ABS_PRESSURE , pres);input_report_abs (dev,ABS_TOOL_WIDTH , width);
@@ -484,10 +491,17 @@ static void elantech_report_absolute_v3(struct psmouse *psmouse,static void elantech_input_sync_v4 (struct psmouse *psmouse) {struct input_dev *dev = psmouse->dev; +struct elantech_data *etd = psmouse->private;unsigned char *packet = psmouse->packet; -input_report_key (dev,BTN_LEFT , packet[0 ] &0x01 ); -input_report_key (dev,BTN_RIGHT , packet[0 ] &0x02 ); +/* For clickpads map both buttons to BTN_LEFT */ +if (etd->fw_version &0x001000 ) { +input_report_key (dev,BTN_LEFT , packet[0 ] &0x03 ); + }else { +input_report_key (dev,BTN_LEFT , packet[0 ] &0x01 ); +input_report_key (dev,BTN_RIGHT , packet[0 ] &0x02 ); + } +input_mt_report_pointer_emulation (dev, true);input_sync (dev); }
@@ -805,7 +819,7 @@ static int elantech_set_absolute_mode(struct psmouse *psmouse)if (etd->set_hw_resolution) etd->reg_10 =0x0b ;else - etd->reg_10 =0x03 ; + etd->reg_10 =0x01 ;if (elantech_write_reg (psmouse,0x10 , etd->reg_10)) rc =-1 ;
@@ -1306,7 +1320,8 @@ static int elantech_reconnect(struct psmouse *psmouse) }/* -* Some hw_version 3 models go into error state when we try to set bit 3 of r10 +* Some hw_version 3 models go into error state when we try to set +* bit 3 and/or bit 1 of r10. */ static const struct dmi_system_id no_hw_res_dmi_table[] = { #if defined(CONFIG_DMI) && defined(CONFIG_X86)
drivers/misc/mei/hw-me.c +20 -8
@@ -164,6 +164,9 @@ static void mei_me_hw_reset_release(struct mei_device *dev) hcsr |=H_IG ; hcsr &= ~H_RST ;mei_hcsr_set (hw, hcsr); + +/* complete this write before we set host ready on another CPU */ +mmiowb (); }/** * mei_me_hw_reset - resets fw via mei csr register.
@@ -186,7 +189,19 @@ static void mei_me_hw_reset(struct mei_device *dev, bool intr_enable) dev->recvd_hw_ready = false;mei_me_reg_write (hw,H_CSR , hcsr); -if (dev->dev_state ==MEI_DEV_POWER_DOWN ) +/* +* Host reads the H_CSR once to ensure that the +* posted write to H_CSR completes. +*/ + hcsr =mei_hcsr_read (hw); + +if ((hcsr &H_RST ) ==0 ) +dev_warn (&dev->pdev->dev,"H_RST is not set = 0x%08X" , hcsr); + +if ((hcsr &H_RDY ) ==H_RDY ) +dev_warn (&dev->pdev->dev,"H_RDY is not cleared 0x%08X" , hcsr); + +if (intr_enable == false)mei_me_hw_reset_release (dev);dev_dbg (&dev->pdev->dev,"current HCSR = 0x%08x.\n" ,mei_hcsr_read (hw));
@@ -202,6 +217,7 @@ static void mei_me_hw_reset(struct mei_device *dev, bool intr_enable)static void mei_me_host_set_ready (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); + hw->host_hw_state =mei_hcsr_read (hw); hw->host_hw_state |=H_IE |H_IG |H_RDY ;mei_hcsr_set (hw, hw->host_hw_state); }
@@ -494,19 +510,15 @@ irqreturn_t mei_me_irq_thread_handler(int irq, void *dev_id)/* check if we need to start the dev */ if (!mei_host_is_ready (dev)) {if (mei_hw_is_ready (dev)) { +mei_me_hw_reset_release (dev);dev_dbg (&dev->pdev->dev,"we need to start the dev.\n" ); dev->recvd_hw_ready = true;wake_up_interruptible (&dev->wait_hw_ready); - -mutex_unlock (&dev->device_lock); -return IRQ_HANDLED ; }else { -dev_dbg (&dev->pdev->dev,"Reset Completed.\n" ); -mei_me_hw_reset_release (dev); -mutex_unlock (&dev->device_lock); -return IRQ_HANDLED ; +dev_dbg (&dev->pdev->dev,"Spurious Interrupt\n" ); } + goto end; }/* check slots available for reading */ slots =mei_count_full_read_slots (dev);
drivers/pci/pci.c +1 -1
@@ -3659,7 +3659,7 @@ int pci_set_vga_state(struct pci_dev *dev, bool decode,u16 cmd;int rc; -WARN_ON ((flags &PCI_VGA_STATE_CHANGE_DECODES ) & (command_bits & ~(PCI_COMMAND_IO |PCI_COMMAND_MEMORY ))); +WARN_ON ((flags &PCI_VGA_STATE_CHANGE_DECODES ) && (command_bits & ~(PCI_COMMAND_IO |PCI_COMMAND_MEMORY )));/* ARCH specific VGA enables */ rc =pci_set_vga_state_arch (dev, decode, command_bits, flags);
drivers/pci/quirks.c +1 -0
@@ -2930,6 +2930,7 @@ static void disable_igfx_irq(struct pci_dev *dev) }DECLARE_PCI_FIXUP_FINAL (PCI_VENDOR_ID_INTEL ,0x0102 , disable_igfx_irq);DECLARE_PCI_FIXUP_FINAL (PCI_VENDOR_ID_INTEL ,0x010a , disable_igfx_irq); +DECLARE_PCI_FIXUP_FINAL (PCI_VENDOR_ID_INTEL ,0x0152 , disable_igfx_irq);/* * Some devices may pass our check in pci_intx_mask_supported if
drivers/target/iscsi/iscsi_target.c +1 -1
@@ -1313,7 +1313,7 @@ iscsit_check_dataout_hdr(struct iscsi_conn *conn, unsigned char *buf,if (cmd->data_direction !=DMA_TO_DEVICE ) {pr_err ("Command ITT: 0x%08x received DataOUT for a" " NON-WRITE command.\n" , cmd->init_task_tag); -return iscsit_reject_cmd (cmd,ISCSI_REASON_PROTOCOL_ERROR , buf); +return iscsit_dump_data_payload (conn, payload_length,1 ); } se_cmd = &cmd->se_cmd;iscsit_mod_dataout_timer (cmd);
drivers/target/iscsi/iscsi_target_util.c +2 -0
@@ -1288,6 +1288,8 @@ int iscsit_tx_login_rsp(struct iscsi_conn *conn, u8 status_class, u8 status_deta login->login_failed =1 ;iscsit_collect_login_stats (conn, status_class, status_detail); +memset (&login->rsp[0 ],0 ,ISCSI_HDR_LEN ); + hdr = (struct iscsi_login_rsp *)&login->rsp[0 ]; hdr->opcode =ISCSI_OP_LOGIN_RSP ; hdr->status_class = status_class;
drivers/target/target_core_device.c +1 -0
@@ -614,6 +614,7 @@ void core_dev_unexport( dev->export_count--;spin_unlock (&hba->device_lock); + lun->lun_sep =NULL ; lun->lun_se_dev =NULL ; }
drivers/watchdog/ath79_wdt.c +10 -0
@@ -20,6 +20,7 @@#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt#include <linux/bitops.h> +#include <linux/delay.h> #include <linux/errno.h> #include <linux/fs.h> #include <linux/init.h>
@@ -91,6 +92,15 @@ static inline void ath79_wdt_keepalive(void)static inline void ath79_wdt_enable (void ) {ath79_wdt_keepalive (); + +/* +* Updating the TIMER register requires a few microseconds +* on the AR934x SoCs at least. Use a small delay to ensure +* that the TIMER register is updated within the hardware +* before enabling the watchdog. +*/ +udelay (2 ); +ath79_wdt_wr (WDOG_REG_CTRL ,WDOG_CTRL_ACTION_FCR );/* flush write */ ath79_wdt_rr (WDOG_REG_CTRL );
drivers/watchdog/sp805_wdt.c +1 -3
@@ -60,7 +60,6 @@* @adev: amba device structure of wdt * @status: current status of wdt * @load_val: load value to be set for current timeout -* @timeout: current programmed timeout */ struct sp805_wdt {struct watchdog_device wdd;
@@ -69,7 +68,6 @@ struct sp805_wdt {struct clk *clk;struct amba_device *adev;unsigned int load_val; -unsigned int timeout; };static bool nowayout =WATCHDOG_NOWAYOUT ;
@@ -99,7 +97,7 @@ static int wdt_setload(struct watchdog_device *wdd, unsigned int timeout)spin_lock (&wdt->lock); wdt->load_val = load;/* roundup timeout to closest positive integer value */ - wdt->timeout =div_u64 ((load +1 ) *2 + (rate /2 ), rate); + wdd->timeout =div_u64 ((load +1 ) *2 + (rate /2 ), rate);spin_unlock (&wdt->lock);return 0 ;
fs/nfs/inode.c +17 -9
@@ -1382,18 +1382,20 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr) inode->i_version = fattr->change_attr; } }else if (server->caps &NFS_CAP_CHANGE_ATTR ) - invalid |= save_cache_validity; + nfsi->cache_validity |= save_cache_validity;if (fattr->valid &NFS_ATTR_FATTR_MTIME ) {memcpy (&inode->i_mtime, &fattr->mtime,sizeof (inode->i_mtime)); }else if (server->caps &NFS_CAP_MTIME ) - invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATTR |NFS_INO_REVAL_FORCED );if (fattr->valid &NFS_ATTR_FATTR_CTIME ) {memcpy (&inode->i_ctime, &fattr->ctime,sizeof (inode->i_ctime)); }else if (server->caps &NFS_CAP_CTIME ) - invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATTR |NFS_INO_REVAL_FORCED );/* Check if our cached file size is stale */
@@ -1416,7 +1418,8 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr) (long long)new_isize); } }else - invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATTR |NFS_INO_REVAL_PAGECACHE |NFS_INO_REVAL_FORCED );
@@ -1424,7 +1427,8 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr)if (fattr->valid &NFS_ATTR_FATTR_ATIME )memcpy (&inode->i_atime, &fattr->atime,sizeof (inode->i_atime));else if (server->caps &NFS_CAP_ATIME ) - invalid |= save_cache_validity & (NFS_INO_INVALID_ATIME + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATIME |NFS_INO_REVAL_FORCED );if (fattr->valid &NFS_ATTR_FATTR_MODE ) {
@@ -1435,7 +1439,8 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr) invalid |=NFS_INO_INVALID_ATTR |NFS_INO_INVALID_ACCESS |NFS_INO_INVALID_ACL ; } }else if (server->caps &NFS_CAP_MODE ) - invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATTR |NFS_INO_INVALID_ACCESS |NFS_INO_INVALID_ACL |NFS_INO_REVAL_FORCED );
@@ -1446,7 +1451,8 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr) inode->i_uid = fattr->uid; } }else if (server->caps &NFS_CAP_OWNER ) - invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATTR |NFS_INO_INVALID_ACCESS |NFS_INO_INVALID_ACL |NFS_INO_REVAL_FORCED );
@@ -1457,7 +1463,8 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr) inode->i_gid = fattr->gid; } }else if (server->caps &NFS_CAP_OWNER_GROUP ) - invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATTR |NFS_INO_INVALID_ACCESS |NFS_INO_INVALID_ACL |NFS_INO_REVAL_FORCED );
@@ -1470,7 +1477,8 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr)set_nlink (inode, fattr->nlink); } }else if (server->caps &NFS_CAP_NLINK ) - invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR + nfsi->cache_validity |= save_cache_validity & + (NFS_INO_INVALID_ATTR |NFS_INO_REVAL_FORCED );if (fattr->valid &NFS_ATTR_FATTR_SPACE_USED ) {
fs/nfs/nfs4filelayout.c +1 -1
@@ -1300,7 +1300,7 @@ filelayout_alloc_layout_hdr(struct inode *inode, gfp_t gfp_flags)struct nfs4_filelayout *flo; flo =kzalloc (sizeof (*flo), gfp_flags); -return &flo->generic_hdr; +return flo !=NULL ? &flo->generic_hdr :NULL ; } static void
fs/nfsd/nfs4state.c +1 -1
@@ -3608,7 +3608,7 @@ nfsd4_free_lock_stateid(struct nfs4_ol_stateid *stp)* correspondance, and we have to delete the lockowner when we * delete the lock stateid: */ -unhash_lockowner (lo); +release_lockowner (lo);return nfs_ok; }
fs/nfsd/nfs4xdr.c +2 -2
@@ -2035,8 +2035,8 @@ nfsd4_encode_fattr(struct svc_fh *fhp, struct svc_export *exp, err =vfs_getattr (&path, &stat);if (err) goto out_nfserr; -if ((bmval0 & (FATTR4_WORD0_FILES_FREE |FATTR4_WORD0_FILES_TOTAL | -FATTR4_WORD0_MAXNAME )) || +if ((bmval0 & (FATTR4_WORD0_FILES_AVAIL |FATTR4_WORD0_FILES_FREE | +FATTR4_WORD0_FILES_TOTAL |FATTR4_WORD0_MAXNAME )) || (bmval1 & (FATTR4_WORD1_SPACE_AVAIL |FATTR4_WORD1_SPACE_FREE |FATTR4_WORD1_SPACE_TOTAL ))) { err =vfs_statfs (&path, &statfs);
fs/nfsd/nfscache.c +12 -41
90 lines not on this page · raw message
fs/reiserfs/inode.c +7 -1
@@ -3211,8 +3211,14 @@ int reiserfs_setattr(struct dentry *dentry, struct iattr *attr) attr->ia_size != i_size_read(inode)) { error =inode_newsize_ok (inode, attr->ia_size);if (!error) { +/* +* Could race against reiserfs_file_release +* if called from NFS, so take tailpack mutex. +*/ +mutex_lock (&REISERFS_I (inode)->tailpack);truncate_setsize (inode, attr->ia_size); -reiserfs_vfs_truncate_file (inode); +reiserfs_truncate_file (inode,1 ); +mutex_unlock (&REISERFS_I (inode)->tailpack); } }
fs/ubifs/file.c +1 -2
@@ -1524,8 +1524,7 @@ static int ubifs_vm_page_mkwrite(struct vm_area_struct *vma, }wait_for_stable_page (page); -unlock_page (page); -return 0 ; +return VM_FAULT_LOCKED ; out_unlock:unlock_page (page);
fs/ubifs/shrinker.c +0 -1
@@ -128,7 +128,6 @@ static int shrink_tnc(struct ubifs_info *c, int nr, int age, int *contention) freed =ubifs_destroy_tnc_subtree (znode);atomic_long_sub (freed, &ubifs_clean_zn_cnt);atomic_long_sub (freed, &c->clean_zn_cnt); -ubifs_assert (atomic_long_read (&c->clean_zn_cnt) >=0 ); total_freed += freed; znode = zprev; }
include/linux/ptrace.h +3 -0
@@ -337,6 +337,9 @@ static inline void user_single_step_siginfo(struct task_struct *tsk,* calling arch_ptrace_stop() when it would be superfluous. For example, * if the thread has not been back to user mode since the last stop, the * thread state might indicate that nothing needs to be done. +* +* This is guaranteed to be invoked once before a task stops for ptrace and +* may include arch-specific operations necessary prior to a ptrace stop. */ #define arch_ptrace_stop_needed (code, info) (0)#endif
include/trace/syscall.h +15 -0
@@ -4,6 +4,7 @@#include <linux/tracepoint.h> #include <linux/unistd.h> #include <linux/ftrace_event.h> +#include <linux/thread_info.h> #include <asm/ptrace.h>
@@ -31,4 +32,18 @@ struct syscall_metadata { struct ftrace_event_call *exit_event; }; +#if defined(CONFIG_TRACEPOINTS ) && defined(CONFIG_HAVE_SYSCALL_TRACEPOINTS ) +static inline void syscall_tracepoint_update (struct task_struct *p) +{ +if (test_thread_flag (TIF_SYSCALL_TRACEPOINT )) +set_tsk_thread_flag (p,TIF_SYSCALL_TRACEPOINT ); +else +clear_tsk_thread_flag (p,TIF_SYSCALL_TRACEPOINT ); +} +#else +static inline void syscall_tracepoint_update (struct task_struct *p) +{ +} +#endif +#endif /* _TRACE_SYSCALL_H */
kernel/fork.c +2 -0
@@ -1479,7 +1479,9 @@ static struct task_struct *copy_process(unsigned long clone_flags, total_forks++;spin_unlock (¤t->sighand->siglock); +syscall_tracepoint_update (p);write_unlock_irq (&tasklist_lock); +proc_fork_connector (p);cgroup_post_fork (p);if (clone_flags &CLONE_THREAD )
kernel/trace/trace.c +7 -6
@@ -1400,12 +1400,12 @@ static void tracing_stop_tr(struct trace_array *tr)void trace_stop_cmdline_recording (void ); -static void trace_save_cmdline (struct task_struct *tsk) +static int trace_save_cmdline (struct task_struct *tsk) {unsigned pid, idx;if (!tsk->pid ||unlikely (tsk->pid >PID_MAX_DEFAULT )) -return ; +return 0 ;/* * It's not the end of the world if we don't get
@@ -1414,7 +1414,7 @@ static void trace_save_cmdline(struct task_struct *tsk)* so if we miss here, then better luck next time. */ if (!arch_spin_trylock (&trace_cmdline_lock)) -return ; +return 0 ; idx = map_pid_to_cmdline[tsk->pid];if (idx ==NO_CMDLINE_MAP ) {
@@ -1439,6 +1439,8 @@ static void trace_save_cmdline(struct task_struct *tsk)memcpy (&saved_cmdlines[idx], tsk->comm,TASK_COMM_LEN );arch_spin_unlock (&trace_cmdline_lock); + +return 1 ; }void trace_find_cmdline (int pid,char comm[])
@@ -1480,9 +1482,8 @@ void tracing_record_cmdline(struct task_struct *tsk)if (!__this_cpu_read (trace_cmdline_save))return ; -__this_cpu_write (trace_cmdline_save, false); - -trace_save_cmdline (tsk); +if (trace_save_cmdline (tsk)) +__this_cpu_write (trace_cmdline_save, false); }void
net/ipv4/netfilter/ipt_ULOG.c +1 -6
@@ -220,6 +220,7 @@ static void ipt_ulog_packet(struct net *net, ub->qlen++; pm =nlmsg_data (nlh); +memset (pm,0 ,sizeof (*pm));/* We might not have a timestamp, get one */ if (skb->tstamp.tv64 ==0 )
@@ -238,8 +239,6 @@ static void ipt_ulog_packet(struct net *net, }else if (loginfo->prefix[0 ] !='\0' )strncpy (pm->prefix, loginfo->prefix,sizeof (pm->prefix)); -else - *(pm->prefix) ='\0' ; if (in && in->hard_header_len > 0 && skb->mac_header != skb->network_header &&
@@ -251,13 +250,9 @@ static void ipt_ulog_packet(struct net *net,if (in)strncpy (pm->indev_name, in->name,sizeof (pm->indev_name)); -else - pm->indev_name[0 ] ='\0' ;if (out)strncpy (pm->outdev_name, out->name,sizeof (pm->outdev_name)); -else - pm->outdev_name[0 ] ='\0' ;/* copy_len <= skb->len, so can't fail. */ if (skb_copy_bits (skb,0 , pm->payload, copy_len) <0 )
net/netfilter/ipvs/ip_vs_core.c +10 -5
@@ -1384,15 +1384,19 @@ ip_vs_in_icmp(struct sk_buff *skb, int *related, unsigned int hooknum)if (ipip) {__be32 info = ic->un.gateway; +__u8 type = ic->type; +__u8 code = ic->code;/* Update the MTU */ if (ic->type ==ICMP_DEST_UNREACH && ic->code ==ICMP_FRAG_NEEDED ) {struct ip_vs_dest *dest = cp->dest;u32 mtu =ntohs (ic->un.frag.mtu); +__be16 frag_off = cih->frag_off;/* Strip outer IP and ICMP, go to IPIP header */ -__skb_pull (skb, ihl +sizeof (_icmph)); +if (pskb_pull (skb, ihl +sizeof (_icmph)) ==NULL ) + goto ignore_ipip; offset2 -= ihl +sizeof (_icmph);skb_reset_network_header (skb); IP_VS_DBG(12, "ICMP for IPIP %pI4->%pI4: mtu=%u\n",
@@ -1400,7 +1404,7 @@ ip_vs_in_icmp(struct sk_buff *skb, int *related, unsigned int hooknum)ipv4_update_pmtu (skb,dev_net (skb->dev), mtu,0 ,0 ,0 ,0 );/* Client uses PMTUD? */ -if (!(cih->frag_off &htons (IP_DF ))) +if (!(frag_off &htons (IP_DF ))) goto ignore_ipip;/* Prefer the resulting PMTU */ if (dest) {
@@ -1419,12 +1423,13 @@ ip_vs_in_icmp(struct sk_buff *skb, int *related, unsigned int hooknum)/* Strip outer IP, ICMP and IPIP, go to IP header of * original request. */ -__skb_pull (skb, offset2); +if (pskb_pull (skb, offset2) ==NULL ) + goto ignore_ipip;skb_reset_network_header (skb);IP_VS_DBG (12 ,"Sending ICMP for %pI4->%pI4: t=%u, c=%u, i=%u\n" , &ip_hdr (skb)->saddr, &ip_hdr (skb)->daddr, - ic->type, ic->code,ntohl (info)); -icmp_send (skb, ic->type, ic->code, info); + type, code,ntohl (info)); +icmp_send (skb, type, code, info);/* ICMP can be shorter but anyways, account it */ ip_vs_out_stats (cp, skb);
net/sunrpc/svc_xprt.c +2 -0
@@ -730,6 +730,8 @@ static int svc_handle_xprt(struct svc_rqst *rqstp, struct svc_xprt *xprt) newxpt = xprt->xpt_ops->xpo_accept (xprt);if (newxpt)svc_add_new_temp_xprt (serv, newxpt); +else +module_put (xprt->xpt_class->xcl_owner); }else if (xprt->xpt_ops->xpo_has_wspace (xprt)) {/* XPT_DATA|XPT_DEFERRED case: */ dprintk("svc: server %p, pool %u, transport %p, inuse=%d\n",
scripts/recordmcount.h +2 -2
@@ -163,11 +163,11 @@ static int mcount_adjust = 0;static int MIPS_is_fake_mcount (Elf_Rel const *rp) { -static Elf_Addr old_r_offset; +static Elf_Addr old_r_offset = ~(Elf_Addr )0 ;Elf_Addr current_r_offset =_w (rp->r_offset);int is_fake; - is_fake = old_r_offset && + is_fake = (old_r_offset != ~(Elf_Addr )0 ) && (current_r_offset - old_r_offset ==MIPS_FAKEMCOUNT_OFFSET ); old_r_offset = current_r_offset;