Linux 4.8.15
Greg KH
maintainerI'm announcing the release of the 4.8.15 kernel.
All users of the 4.8 kernel series must upgrade.
The updated 4.8.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.8.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
------------
Makefile | 2 arch/arm/boot/dts/imx7s.dtsi | 5 - arch/arm/boot/dts/orion5x-linkstation-lsgl.dts | 4 + arch/m68k/include/asm/delay.h | 2 arch/parisc/include/asm/pgtable.h | 8 +- arch/parisc/kernel/cache.c | 11 ++++ arch/parisc/kernel/pacache.S | 22 -------- arch/powerpc/boot/Makefile | 3 - arch/powerpc/boot/opal.c | 2 arch/powerpc/kernel/eeh_driver.c | 4 + arch/powerpc/mm/hash64_4k.c | 2 arch/powerpc/mm/hash64_64k.c | 4 - arch/x86/events/core.c | 2 arch/x86/events/intel/core.c | 2 crypto/Makefile | 1 crypto/mcryptd.c | 19 ++++-- drivers/acpi/nfit/core.c | 49 +++++++++++++----- drivers/acpi/sleep.c | 29 ++-------- drivers/block/zram/zram_drv.c | 8 ++ drivers/crypto/caam/ctrl.c | 5 + drivers/crypto/marvell/hash.c | 11 +--- drivers/dax/dax.c | 2 drivers/net/can/usb/peak_usb/pcan_usb_core.c | 6 +- drivers/nvdimm/bus.c | 25 +++++++-- drivers/scsi/lpfc/lpfc_sli.c | 14 ++--- drivers/vhost/vsock.c | 2 fs/ceph/dir.c | 24 +++++--- fs/fuse/dir.c | 7 -- include/linux/cpu.h | 15 +---- include/linux/libnvdimm.h | 2 include/uapi/linux/can.h | 1 kernel/cpu.c | 2 kernel/locking/rtmutex.c | 68 ++++++++++++++++++++++++- kernel/locking/rtmutex_common.h | 5 + kernel/sched/auto_group.c | 4 + net/batman-adv/translation-table.c | 4 - net/can/raw.c | 3 + 37 files changed, 240 insertions(+), 139 deletions(-)
Andrew Donnellan (1):
powerpc/eeh: Fix deadlock when PE frozen state can't be cleared
Ben Hutchings (1):
powerpc/boot: Fix build failure in 32-bit boot wrapper
Benjamin Herrenschmidt (1):
powerpc/mm: Fix lazy icache flush on pre-POWER5
Boris Brezillon (1):
m68k: Fix ndelay() macro
Dan Williams (4):
device-dax: fix private mapping restriction, permit read-only acpi, nfit, libnvdimm: fix / harden ars_status output length handling acpi, nfit: validate ars_status output buffer size
acpi, nfit: fix bus vs dimm confusion in xlat_status
David Michael (1):
crypto: rsa - Add Makefile dependencies to fix parallel builds
Greg Kroah-Hartman (1):
Linux 4.8.15
Helge Deller (1):
parisc: Fix TLB related boot crash on SMP machines
Horia Geantă (1):
crypto: caam - fix pointer size for AArch64 boot loader, AArch32 kernel
Jeff Layton (1):
ceph: don't set req->r_locked_dir in ceph_d_revalidate
John David Anglin (2):
parisc: Purge TLB before setting PTE
parisc: Remove unnecessary TLB purges from flush_dcache_page_asm and flush_icache_page_asm
Marc Kleine-Budde (1):
can: raw: raw_setsockopt: limit number of can_filter that can be set
Mauricio Faria de Oliveira (1):
scsi: lpfc: fix oops/BUG in lpfc_sli_ringtxcmpl_put()
Michal Hocko (1):
hotplug: Make register and unregister notifier API symmetric
Mike Galbraith (1):
sched/autogroup: Fix 64-bit kernel nice level adjustment
Miklos Szeredi (1):
fuse: fix clearing suid, sgid for chown()
Peng Tao (1):
vhost-vsock: fix orphan connection reset
Peter Zijlstra (Intel) (1):
perf/x86: Fix full width counter, counter overflow
Rafael J. Wysocki (1):
Revert "ACPI: Execute _PTS before system reboot"
Roger Shimizu (1):
ARM: dts: orion5x: fix number of sata port for linkstation ls-gl
Romain Perier (2):
crypto: marvell - Don't copy hash operation twice into the SRAM
crypto: marvell - Don't corrupt state of an STD req for re-stepped ahash
Sergey Senozhatsky (1):
zram: restrict add/remove attributes to root only
Stefan Agner (1):
ARM: dts: imx7d: fix LCDIF clock assignment
Sven Eckelmann (1):
batman-adv: Check for alloc errors when preparing TT local data
Thomas Gleixner (2):
locking/rtmutex: Prevent dequeue vs. unlock race locking/rtmutex: Use READ_ONCE() in rt_mutex_owner()
Vishal Verma (1):
acpi, nfit: fix extended status translations for ACPI DSMs
tim (1):
crypto: mcryptd - Check mcryptd algorithm compatibility
추지호 (1):
can: peak: fix bad memory access and free sequence
Greg KH
maintainerMakefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 4 PATCHLEVEL = 8 -SUBLEVEL = 14 +SUBLEVEL = 15 EXTRAVERSION = NAME = Psychotic Stoned Sheep
arch/arm/boot/dts/imx7s.dtsi +2 -3
@@ -640,9 +640,8 @@ reg = <0x30730000 0x10000>; interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>; clocks = <&clks IMX7D_LCDIF_PIXEL_ROOT_CLK>, - <&clks IMX7D_CLK_DUMMY>, - <&clks IMX7D_CLK_DUMMY>; - clock-names = "pix", "axi", "disp_axi"; + <&clks IMX7D_LCDIF_PIXEL_ROOT_CLK>; + clock-names = "pix", "axi"; status = "disabled"; }; };
arch/arm/boot/dts/orion5x-linkstation-lsgl.dts +4 -0
@@ -82,6 +82,10 @@ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>; }; +&sata { + nr-ports = <2>; +}; + &ehci1 { status = "okay"; };
arch/m68k/include/asm/delay.h +1 -1
@@ -114,6 +114,6 @@ static inline void __udelay(unsigned long usecs)*/ #define HZSCALE (268435456 / (1000000 / HZ)) -#define ndelay (n) __delay(DIV_ROUND_UP((n) * ((((HZSCALE) >> 11) * (loops_per_jiffy >> 11)) >> 6), 1000)); +#define ndelay (n) __delay(DIV_ROUND_UP((n) * ((((HZSCALE) >> 11) * (loops_per_jiffy >> 11)) >> 6), 1000))#endif /* defined(_M68K_DELAY_H) */
arch/parisc/include/asm/pgtable.h +4 -4
@@ -65,9 +65,9 @@ static inline void purge_tlb_entries(struct mm_struct *mm, unsigned long addr)unsigned long flags; \spin_lock_irqsave (&pa_tlb_lock, flags); \ old_pte = *ptep; \ -set_pte (ptep, pteval); \if (pte_inserted (old_pte)) \purge_tlb_entries (mm, addr); \ +set_pte (ptep, pteval); \spin_unlock_irqrestore (&pa_tlb_lock, flags); \ }while (0 )
@@ -478,8 +478,8 @@ static inline int ptep_test_and_clear_young(struct vm_area_struct *vma, unsignedspin_unlock_irqrestore (&pa_tlb_lock, flags);return 0 ; } -set_pte (ptep,pte_mkold (pte));purge_tlb_entries (vma->vm_mm, addr); +set_pte (ptep,pte_mkold (pte));spin_unlock_irqrestore (&pa_tlb_lock, flags);return 1 ; }
@@ -492,9 +492,9 @@ static inline pte_t ptep_get_and_clear(struct mm_struct *mm, unsigned long addr,spin_lock_irqsave (&pa_tlb_lock, flags); old_pte = *ptep; -set_pte (ptep,__pte (0 ));if (pte_inserted (old_pte))purge_tlb_entries (mm, addr); +set_pte (ptep,__pte (0 ));spin_unlock_irqrestore (&pa_tlb_lock, flags);return old_pte;
@@ -504,8 +504,8 @@ static inline void ptep_set_wrprotect(struct mm_struct *mm, unsigned long addr, {unsigned long flags;spin_lock_irqsave (&pa_tlb_lock, flags); -set_pte (ptep,pte_wrprotect (*ptep));purge_tlb_entries (mm, addr); +set_pte (ptep,pte_wrprotect (*ptep));spin_unlock_irqrestore (&pa_tlb_lock, flags); }
arch/parisc/kernel/cache.c +11 -0
@@ -393,6 +393,15 @@ void __init parisc_setup_cache_timing(void)/* calculate TLB flush threshold */ +/* On SMP machines, skip the TLB measure of kernel text which +* has been mapped as huge pages. */ +if (num_online_cpus () >1 && !parisc_requires_coherency ()) { + threshold =max (cache_info.it_size, cache_info.dt_size); + threshold *=PAGE_SIZE ; + threshold /=num_online_cpus (); + goto set_tlb_threshold; + } + alltime =mfctl (16 );flush_tlb_all (); alltime =mfctl (16 ) - alltime;
@@ -411,6 +420,8 @@ void __init parisc_setup_cache_timing(void) alltime, size, rangetime); threshold =PAGE_ALIGN (num_online_cpus () * size * alltime / rangetime); + +set_tlb_threshold:if (threshold) parisc_tlb_flush_threshold = threshold; printk(KERN_INFO "TLB flush threshold set to %lu KiB\n",
arch/parisc/kernel/pacache.S +1 -21
@@ -886,19 +886,10 @@ ENTRY(flush_dcache_page_asm) fdc,m r31(%r28) fdc,m r31(%r28) fdc,m r31(%r28) - cmpb,COND(<<) %r28, %r25,1b + cmpb,COND(<<) %r28, %r25,1b fdc,m r31(%r28) sync - -#ifdef CONFIG_PA20 - pdtlb,l %r0(%r25) -#else - tlb_lock %r20,%r21,%r22 - pdtlb %r0(%r25) - tlb_unlock %r20,%r21,%r22 -#endif - bv %r0(%r2) nop .exit
@@ -973,17 +964,6 @@ ENTRY(flush_icache_page_asm) fic,m %r31(%sr4,%r28) sync - -#ifdef CONFIG_PA20 - pdtlb,l %r0(%r28) - pitlb,l %r0(%sr4,%r25) -#else - tlb_lock %r20,%r21,%r22 - pdtlb %r0(%r28) - pitlb %r0(%sr4,%r25) - tlb_unlock %r20,%r21,%r22 -#endif - bv %r0(%r2) nop .exit
arch/powerpc/boot/Makefile +2 -1
@@ -78,7 +78,8 @@ src-wlib-y := string.S crt0.S crtsavres.S stdio.c main.c \ ns16550.c serial.c simple_alloc.c div64.S util.S \ gunzip_util.c elf_util.c $(zlib) devtree.c stdlib.c \ oflib.c ofconsole.c cuboot.c mpsc.c cpm-serial.c \ - uartlite.c mpc52xx-psc.c opal.c opal-calls.S + uartlite.c mpc52xx-psc.c opal.c +src-wlib-$(CONFIG_PPC64_BOOT_WRAPPER) += opal-calls.S src-wlib-$(CONFIG_40x) += 4xx.c planetcore.c src-wlib-$(CONFIG_44x) += 4xx.c ebony.c bamboo.c src-wlib-$(CONFIG_8xx) += mpc8xx.c planetcore.c fsl-soc.c
arch/powerpc/boot/opal.c +1 -1
@@ -13,7 +13,7 @@#include <libfdt.h> #include "../include/asm/opal-api.h" -#ifdef __powerpc64__ +#ifdef CONFIG_PPC64_BOOT_WRAPPER /* Global OPAL struct used by opal-call.S */ struct opal {
arch/powerpc/kernel/eeh_driver.c +3 -1
@@ -671,8 +671,10 @@ static int eeh_reset_device(struct eeh_pe *pe, struct pci_bus *bus,/* Clear frozen state */ rc =eeh_clear_pe_frozen_state (pe, false); -if (rc) +if (rc) { +pci_unlock_rescan_remove ();return rc; + }/* Give the system 5 seconds to finish running the user-space * hotplug shutdown scripts, e.g. ifdown for ethernet. Yes,
arch/powerpc/mm/hash64_4k.c +1 -1
@@ -55,7 +55,7 @@ int __hash_page_4K(unsigned long ea, unsigned long access, unsigned long vsid,*/ rflags =htab_convert_pte_flags (new_pte); -if (!cpu_has_feature (CPU_FTR_NOEXECUTE ) && +if (cpu_has_feature (CPU_FTR_NOEXECUTE ) && !cpu_has_feature (CPU_FTR_COHERENT_ICACHE )) rflags =hash_page_do_lazy_icache (rflags,__pte (old_pte), trap);
arch/powerpc/mm/hash64_64k.c +2 -2
@@ -87,7 +87,7 @@ int __hash_page_4K(unsigned long ea, unsigned long access, unsigned long vsid, subpg_pte = new_pte & ~subpg_prot; rflags =htab_convert_pte_flags (subpg_pte); -if (!cpu_has_feature (CPU_FTR_NOEXECUTE ) && +if (cpu_has_feature (CPU_FTR_NOEXECUTE ) && !cpu_has_feature (CPU_FTR_COHERENT_ICACHE )) {/*
@@ -258,7 +258,7 @@ int __hash_page_64K(unsigned long ea, unsigned long access, rflags =htab_convert_pte_flags (new_pte); -if (!cpu_has_feature (CPU_FTR_NOEXECUTE ) && +if (cpu_has_feature (CPU_FTR_NOEXECUTE ) && !cpu_has_feature (CPU_FTR_COHERENT_ICACHE )) rflags =hash_page_do_lazy_icache (rflags,__pte (old_pte), trap);
arch/x86/events/core.c +1 -1
@@ -68,7 +68,7 @@ u64 x86_perf_event_update(struct perf_event *event)int shift =64 - x86_pmu.cntval_bits;u64 prev_raw_count, new_raw_count;int idx = hwc->idx; -s64 delta; +u64 delta;if (idx ==INTEL_PMC_IDX_FIXED_BTS )return 0 ;
arch/x86/events/intel/core.c +1 -1
@@ -4024,7 +4024,7 @@ __init int intel_pmu_init(void)/* Support full width counters using alternative MSR range */ if (x86_pmu.intel_cap.full_width_write) { - x86_pmu.max_period = x86_pmu.cntval_mask; + x86_pmu.max_period = x86_pmu.cntval_mask >>1 ; x86_pmu.perfctr =MSR_IA32_PMC0 ;pr_cont ("full-width counters, " ); }
crypto/Makefile +1 -0
@@ -40,6 +40,7 @@ obj-$(CONFIG_CRYPTO_ECDH) += ecdh_generic.o $(obj)/rsapubkey-asn1.o: $(obj)/rsapubkey-asn1.c $(obj)/rsapubkey-asn1.h $(obj)/rsaprivkey-asn1.o: $(obj)/rsaprivkey-asn1.c $(obj)/rsaprivkey-asn1.h +$(obj)/rsa_helper.o: $(obj)/rsapubkey-asn1.h $(obj)/rsaprivkey-asn1.h clean-files += rsapubkey-asn1.c rsapubkey-asn1.h clean-files += rsaprivkey-asn1.c rsaprivkey-asn1.h
crypto/mcryptd.c +12 -7
@@ -254,18 +254,22 @@ out_free_inst: goto out; } -static inline void mcryptd_check_internal (struct rtattr **tb,u32 *type, +static inline bool mcryptd_check_internal (struct rtattr **tb,u32 *type,u32 *mask) {struct crypto_attr_type *algt; algt =crypto_get_attr_type (tb);if (IS_ERR (algt)) -return ; -if ((algt->type &CRYPTO_ALG_INTERNAL )) - *type |=CRYPTO_ALG_INTERNAL ; -if ((algt->mask &CRYPTO_ALG_INTERNAL )) - *mask |=CRYPTO_ALG_INTERNAL ; +return false; + + *type |= algt->type &CRYPTO_ALG_INTERNAL ; + *mask |= algt->mask &CRYPTO_ALG_INTERNAL ; + +if (*type & *mask &CRYPTO_ALG_INTERNAL ) +return true; +else +return false; }static int mcryptd_hash_init_tfm (struct crypto_tfm *tfm)
@@ -492,7 +496,8 @@ static int mcryptd_create_hash(struct crypto_template *tmpl, struct rtattr **tb,u32 mask =0 ;int err; -mcryptd_check_internal (tb, &type, &mask); +if (!mcryptd_check_internal (tb, &type, &mask)) +return -EINVAL ; halg =ahash_attr_alg (tb[1 ], type, mask);if (IS_ERR (halg))
drivers/acpi/nfit/core.c +37 -12
133 lines not on this page · raw message
drivers/acpi/sleep.c +6 -23
@@ -47,32 +47,15 @@ static void acpi_sleep_tts_switch(u32 acpi_state) } } -static void acpi_sleep_pts_switch (u32 acpi_state) -{ -acpi_status status; - - status =acpi_execute_simple_method (NULL ,"\\_PTS" , acpi_state); -if (ACPI_FAILURE (status) && status !=AE_NOT_FOUND ) { -/* -* OS can't evaluate the _PTS object correctly. Some warning -* message will be printed. But it won't break anything. -*/ -printk (KERN_NOTICE "Failure in evaluating _PTS object\n" ); - } -} - -static int sleep_notify_reboot (struct notifier_block *this, +static int tts_notify_reboot (struct notifier_block *this,unsigned long code,void *x) {acpi_sleep_tts_switch (ACPI_STATE_S5 ); - -acpi_sleep_pts_switch (ACPI_STATE_S5 ); -return NOTIFY_DONE ; } -static struct notifier_block sleep_notifier = { - .notifier_call = sleep_notify_reboot, +static struct notifier_block tts_notifier = { + .notifier_call = tts_notify_reboot, .next =NULL , .priority =0 , };
@@ -916,9 +899,9 @@ int __init acpi_sleep_init(void)pr_info (PREFIX "(supports%s)\n" , supported);/* -* Register the sleep_notifier to reboot notifier list so that the _TTS -* and _PTS object can also be evaluated when the system enters S5. +* Register the tts_notifier to reboot notifier list so that the _TTS +* object can also be evaluated when the system enters S5. */ -register_reboot_notifier (&sleep_notifier); +register_reboot_notifier (&tts_notifier);return 0 ; }
drivers/block/zram/zram_drv.c +7 -1
@@ -1413,8 +1413,14 @@ static ssize_t hot_remove_store(struct class *class,return ret ? ret : count; } +/* +* NOTE: hot_add attribute is not the usual read-only sysfs attribute. In a +* sense that reading from this file does alter the state of your system -- it +* creates a new un-initialized zram device and returns back this device's +* device_id (or an error code if it fails to create a new device). +*/ static struct class_attribute zram_control_class_attrs[] = { -__ATTR_RO (hot_add), +__ATTR (hot_add,0400 , hot_add_show,NULL ),__ATTR_WO (hot_remove), __ATTR_NULL, };
drivers/crypto/caam/ctrl.c +3 -2
@@ -557,8 +557,9 @@ static int caam_probe(struct platform_device *pdev)* Enable DECO watchdogs and, if this is a PHYS_ADDR_T_64BIT kernel, * long pointers in master configuration register */ -clrsetbits_32 (&ctrl->mcr,MCFGR_AWCACHE_MASK ,MCFGR_AWCACHE_CACH | -MCFGR_AWCACHE_BUFF |MCFGR_WDENABLE |MCFGR_LARGE_BURST | +clrsetbits_32 (&ctrl->mcr,MCFGR_AWCACHE_MASK |MCFGR_LONG_PTR , +MCFGR_AWCACHE_CACH |MCFGR_AWCACHE_BUFF | +MCFGR_WDENABLE |MCFGR_LARGE_BURST | (sizeof (dma_addr_t) ==sizeof (u64) ?MCFGR_LONG_PTR :0 ));/*
drivers/crypto/marvell/hash.c +5 -6
@@ -168,12 +168,11 @@ static void mv_cesa_ahash_std_step(struct ahash_request *req)mv_cesa_adjust_op (engine, &creq->op_tmpl);memcpy_toio (engine->sram, &creq->op_tmpl,sizeof (creq->op_tmpl)); - digsize =crypto_ahash_digestsize (crypto_ahash_reqtfm (req)); -for (i =0 ; i < digsize /4 ; i++) -writel_relaxed (creq->state[i], engine->regs +CESA_IVDIG (i)); - -mv_cesa_adjust_op (engine, &creq->op_tmpl); -memcpy_toio (engine->sram, &creq->op_tmpl,sizeof (creq->op_tmpl)); +if (!sreq->offset) { + digsize =crypto_ahash_digestsize (crypto_ahash_reqtfm (req)); +for (i =0 ; i < digsize /4 ; i++) +writel_relaxed (creq->state[i], engine->regs +CESA_IVDIG (i)); + }if (creq->cache_ptr) memcpy_toio(engine->sram + CESA_SA_DATA_SRAM_OFFSET,
drivers/dax/dax.c +1 -1
@@ -324,7 +324,7 @@ static int check_vma(struct dax_dev *dax_dev, struct vm_area_struct *vma,return -ENXIO ;/* prevent private mappings from being established */ -if ((vma->vm_flags &VM_SHARED ) !=VM_SHARED ) { +if ((vma->vm_flags &VM_MAYSHARE ) !=VM_MAYSHARE ) {dev_info (dev,"%s: %s: fail, attempted private mapping\n" , current->comm, func);return -EINVAL ;
drivers/net/can/usb/peak_usb/pcan_usb_core.c +4 -2
@@ -872,23 +872,25 @@ lbl_free_candev:static void peak_usb_disconnect (struct usb_interface *intf) {struct peak_usb_device *dev; +struct peak_usb_device *dev_prev_siblings;/* unregister as many netdev devices as siblings */ -for (dev =usb_get_intfdata (intf); dev; dev = dev->prev_siblings) { +for (dev =usb_get_intfdata (intf); dev; dev = dev_prev_siblings) {struct net_device *netdev = dev->netdev;char name[IFNAMSIZ ]; + dev_prev_siblings = dev->prev_siblings; dev->state &= ~PCAN_USB_STATE_CONNECTED ;strncpy (name, netdev->name,IFNAMSIZ );unregister_netdev (netdev); -free_candev (netdev);kfree (dev->cmd_buf); dev->next_siblings =NULL ;if (dev->adapter->dev_free) dev->adapter->dev_free (dev); +free_candev (netdev);dev_info (&intf->dev,"%s removed\n" , name); }
drivers/nvdimm/bus.c +20 -5
@@ -715,7 +715,7 @@ EXPORT_SYMBOL_GPL(nd_cmd_in_size);u32 nd_cmd_out_size (struct nvdimm *nvdimm,int cmd,const struct nd_cmd_desc *desc,int idx,const u32 *in_field, -const u32 *out_field) +const u32 *out_field,unsigned long remainder) {if (idx >= desc->out_num)return UINT_MAX ;
@@ -727,9 +727,24 @@ u32 nd_cmd_out_size(struct nvdimm *nvdimm, int cmd,return in_field[1 ]; else if (nvdimm && cmd == ND_CMD_VENDOR && idx == 2) return out_field[1 ]; - else if (!nvdimm && cmd == ND_CMD_ARS_STATUS && idx == 2) -return out_field[1 ] -8 ; - else if (cmd == ND_CMD_CALL) { + else if (!nvdimm && cmd == ND_CMD_ARS_STATUS && idx == 2) { +/* +* Per table 9-276 ARS Data in ACPI 6.1, out_field[1] is +* "Size of Output Buffer in bytes, including this +* field." +*/ +if (out_field[1 ] <4 ) +return 0 ; +/* +* ACPI 6.1 is ambiguous if 'status' is included in the +* output size. If we encounter an output size that +* overshoots the remainder by 4 bytes, assume it was +* including 'status'. +*/ +if (out_field[1 ] -8 == remainder) +return remainder; +return out_field[1 ] -4 ; + } else if (cmd == ND_CMD_CALL) {struct nd_cmd_pkg *pkg = (struct nd_cmd_pkg *) in_field;return pkg->nd_size_out;
@@ -876,7 +891,7 @@ static int __nd_ioctl(struct nvdimm_bus *nvdimm_bus, struct nvdimm *nvdimm,/* process an output envelope */ for (i =0 ; i < desc->out_num; i++) {u32 out_size =nd_cmd_out_size (nvdimm, cmd, desc, i, - (u32 *) in_env, (u32 *) out_env); + (u32 *) in_env, (u32 *) out_env,0 );u32 copy;if (out_size ==UINT_MAX ) {
drivers/scsi/lpfc/lpfc_sli.c +8 -6
@@ -1323,18 +1323,20 @@ lpfc_sli_ringtxcmpl_put(struct lpfc_hba *phba, struct lpfc_sli_ring *pring, {lockdep_assert_held (&phba->hbalock); -BUG_ON (!piocb || !piocb->vport); +BUG_ON (!piocb);list_add_tail (&piocb->list, &pring->txcmplq); piocb->iocb_flag |=LPFC_IO_ON_TXCMPLQ ;if ((unlikely (pring->ringno ==LPFC_ELS_RING )) && (piocb->iocb.ulpCommand !=CMD_ABORT_XRI_CN ) && - (piocb->iocb.ulpCommand !=CMD_CLOSE_XRI_CN ) && - (!(piocb->vport->load_flag &FC_UNLOADING ))) -mod_timer (&piocb->vport->els_tmofunc, - jiffies + -msecs_to_jiffies (1000 * (phba->fc_ratov <<1 ))); + (piocb->iocb.ulpCommand !=CMD_CLOSE_XRI_CN )) { +BUG_ON (!piocb->vport); +if (!(piocb->vport->load_flag &FC_UNLOADING )) +mod_timer (&piocb->vport->els_tmofunc, + jiffies + +msecs_to_jiffies (1000 * (phba->fc_ratov <<1 ))); + }return 0 ; }
drivers/vhost/vsock.c +1 -1
@@ -506,7 +506,7 @@ static void vhost_vsock_reset_orphans(struct sock *sk)* executing. */ -if (!vhost_vsock_get (vsk->local_addr.svm_cid)) { +if (!vhost_vsock_get (vsk->remote_addr.svm_cid)) {sock_set_flag (sk,SOCK_DONE ); vsk->peer_shutdown =SHUTDOWN_MASK ; sk->sk_state =SS_UNCONNECTED ;
fs/ceph/dir.c +14 -10
@@ -1257,26 +1257,30 @@ static int ceph_d_revalidate(struct dentry *dentry, unsigned int flags)return -ECHILD ; op =ceph_snap (dir) ==CEPH_SNAPDIR ? -CEPH_MDS_OP_LOOKUPSNAP :CEPH_MDS_OP_LOOKUP ; +CEPH_MDS_OP_LOOKUPSNAP :CEPH_MDS_OP_GETATTR ; req =ceph_mdsc_create_request (mdsc, op,USE_ANY_MDS );if (!IS_ERR (req)) { req->r_dentry =dget (dentry); - req->r_num_caps =2 ; + req->r_num_caps = op ==CEPH_MDS_OP_GETATTR ?1 :2 ; mask =CEPH_STAT_CAP_INODE |CEPH_CAP_AUTH_SHARED ;if (ceph_security_xattr_wanted (dir)) mask |=CEPH_CAP_XATTR_SHARED ; req->r_args.getattr.mask = mask; - req->r_locked_dir = dir; err =ceph_mdsc_do_request (mdsc,NULL , req); -if (err ==0 || err == -ENOENT ) { -if (dentry == req->r_dentry) { - valid = !d_unhashed (dentry); - }else { -d_invalidate (req->r_dentry); - err = -EAGAIN ; - } +switch (err) { +case 0 : +if (d_really_is_positive (dentry) && +d_inode (dentry) == req->r_target_inode) + valid =1 ; +break ; +case -ENOENT : +if (d_really_is_negative (dentry)) + valid =1 ; +/* Fallthrough */ +default : +break ; }ceph_mdsc_put_request (req); dout("d_revalidate %p lookup result=%d\n",
fs/fuse/dir.c +2 -5
@@ -1709,8 +1709,6 @@ static int fuse_setattr(struct dentry *entry, struct iattr *attr)return -EACCES ;if (attr->ia_valid & (ATTR_KILL_SUID |ATTR_KILL_SGID )) { -int kill; - attr->ia_valid &= ~(ATTR_KILL_SUID |ATTR_KILL_SGID |ATTR_MODE );/*
@@ -1722,12 +1720,11 @@ static int fuse_setattr(struct dentry *entry, struct iattr *attr)return ret; attr->ia_mode = inode->i_mode; - kill =should_remove_suid (entry); -if (kill &ATTR_KILL_SUID ) { +if (inode->i_mode &S_ISUID ) { attr->ia_valid |=ATTR_MODE ; attr->ia_mode &= ~S_ISUID ; } -if (kill &ATTR_KILL_SGID ) { +if ((inode->i_mode & (S_ISGID |S_IXGRP )) == (S_ISGID |S_IXGRP )) { attr->ia_valid |=ATTR_MODE ; attr->ia_mode &= ~S_ISGID ; }
include/linux/cpu.h +4 -11
@@ -105,22 +105,16 @@ extern bool cpuhp_tasks_frozen; { .notifier_call = fn, .priority = pri }; \ __register_cpu_notifier(&fn##_nb); \ } -#else /* #if defined(CONFIG_HOTPLUG_CPU) || !defined(MODULE) */ -#define cpu_notifier (fn, pri) do { (void)(fn); } while (0) -#define __cpu_notifier (fn, pri) do { (void)(fn); } while (0) -#endif /* #else #if defined(CONFIG_HOTPLUG_CPU) || !defined(MODULE) */ -#ifdef CONFIG_HOTPLUG_CPUextern int register_cpu_notifier (struct notifier_block *nb);extern int __register_cpu_notifier (struct notifier_block *nb);extern void unregister_cpu_notifier (struct notifier_block *nb);extern void __unregister_cpu_notifier (struct notifier_block *nb); -#else -#ifndef MODULE -extern int register_cpu_notifier(struct notifier_block *nb); -extern int __register_cpu_notifier(struct notifier_block *nb); -#else +#else /* #if defined(CONFIG_HOTPLUG_CPU) || !defined(MODULE) */ +#define cpu_notifier (fn, pri) do { (void)(fn); } while (0) +#define __cpu_notifier (fn, pri) do { (void)(fn); } while (0) +static inline int register_cpu_notifier (struct notifier_block *nb) {return 0 ;
@@ -130,7 +124,6 @@ static inline int __register_cpu_notifier(struct notifier_block *nb) {return 0 ; } -#endif static inline void unregister_cpu_notifier (struct notifier_block *nb) {
include/linux/libnvdimm.h +1 -1
@@ -153,7 +153,7 @@ u32 nd_cmd_in_size(struct nvdimm *nvdimm, int cmd, const struct nd_cmd_desc *desc, int idx, void *buf);u32 nd_cmd_out_size (struct nvdimm *nvdimm,int cmd,const struct nd_cmd_desc *desc,int idx,const u32 *in_field, -const u32 *out_field); +const u32 *out_field,unsigned long remainder);int nvdimm_bus_check_dimm_count (struct nvdimm_bus *nvdimm_bus,int dimm_count);struct nd_region *nvdimm_pmem_region_create (struct nvdimm_bus *nvdimm_bus,struct nd_region_desc *ndr_desc);
include/uapi/linux/can.h +1 -0
@@ -196,5 +196,6 @@ struct can_filter { };#define CAN_INV_FILTER 0x20000000U/* to be set in can_filter.can_id */ +#define CAN_RAW_FILTER_MAX 512/* maximum number of can_filter set via setsockopt() */ #endif /* !_UAPI_CAN_H */
kernel/cpu.c +1 -1
@@ -578,7 +578,6 @@ void __init cpuhp_threads_init(void)kthread_unpark (this_cpu_read (cpuhp_state.thread)); } -#ifdef CONFIG_HOTPLUG_CPU EXPORT_SYMBOL (register_cpu_notifier);EXPORT_SYMBOL (__register_cpu_notifier);void unregister_cpu_notifier (struct notifier_block *nb)
@@ -595,6 +594,7 @@ void __unregister_cpu_notifier(struct notifier_block *nb) }EXPORT_SYMBOL (__unregister_cpu_notifier); +#ifdef CONFIG_HOTPLUG_CPU /** * clear_tasks_mm_cpumask - Safely clear tasks' mm_cpumask for a CPU * @cpu: a CPU id
kernel/locking/rtmutex.c +66 -2
74 lines not on this page · raw message
kernel/locking/rtmutex_common.h +3 -2
@@ -75,8 +75,9 @@ task_top_pi_waiter(struct task_struct *p)static inline struct task_struct *rt_mutex_owner (struct rt_mutex *lock) { -return (struct task_struct *) - ((unsigned long )lock->owner & ~RT_MUTEX_OWNER_MASKALL ); +unsigned long owner = (unsigned long )READ_ONCE (lock->owner); + +return (struct task_struct *) (owner & ~RT_MUTEX_OWNER_MASKALL ); }/*
kernel/sched/auto_group.c +3 -1
@@ -192,6 +192,7 @@ int proc_sched_autogroup_set_nice(struct task_struct *p, int nice) {static unsigned long next =INITIAL_JIFFIES ;struct autogroup *ag; +unsigned long shares;int err;if (nice <MIN_NICE || nice >MAX_NICE )
@@ -210,9 +211,10 @@ int proc_sched_autogroup_set_nice(struct task_struct *p, int nice) next =HZ /10 + jiffies; ag =autogroup_task_get (p); + shares =scale_load (sched_prio_to_weight[nice +20 ]);down_write (&ag->lock); - err =sched_group_set_shares (ag->tg, sched_prio_to_weight[nice +20 ]); + err =sched_group_set_shares (ag->tg, shares);if (!err) ag->nice = nice;up_write (&ag->lock);
net/batman-adv/translation-table.c +2 -2
@@ -2849,7 +2849,7 @@ static bool batadv_send_my_tt_response(struct batadv_priv *bat_priv, &tvlv_tt_data, &tt_change, &tt_len); -if (!tt_len) +if (!tt_len || !tvlv_len) goto unlock;/* Copy the last orig_node's OGM buffer */
@@ -2867,7 +2867,7 @@ static bool batadv_send_my_tt_response(struct batadv_priv *bat_priv, &tvlv_tt_data, &tt_change, &tt_len); -if (!tt_len) +if (!tt_len || !tvlv_len) goto out;/* fill the rest of the tvlv with the real TT entries */
net/can/raw.c +3 -0
@@ -499,6 +499,9 @@ static int raw_setsockopt(struct socket *sock, int level, int optname,if (optlen %sizeof (struct can_filter ) !=0 )return -EINVAL ; +if (optlen >CAN_RAW_FILTER_MAX *sizeof (struct can_filter )) +return -EINVAL ; + count = optlen /sizeof (struct can_filter );if (count >1 ) {