Linux 5.10.5
Greg Kroah-Hartman
maintainerI'm announcing the release of the 5.10.5 kernel.
All users of the 5.10 kernel series must upgrade.
The updated 5.10.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-5.10.y
and can be browsed at the normal kernel.org git web browser:
https://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/gpu/todo.rst | 18 + Makefile | 2 arch/ia64/mm/init.c | 4 arch/powerpc/kernel/irq.c | 53 --- arch/powerpc/kernel/time.c | 9 arch/powerpc/platforms/powernv/opal.c | 2 arch/powerpc/sysdev/mpic_msgr.c | 2 arch/s390/kernel/entry.S | 12 arch/um/drivers/random.c | 101 +------ arch/um/drivers/ubd_kern.c | 191 ++++++++------ block/blk-pm.c | 15 - drivers/bluetooth/hci_h5.c | 8 drivers/char/hw_random/Kconfig | 16 - drivers/dax/bus.c | 44 +-- drivers/gpu/drm/amd/display/dc/clk_mgr/dcn21/rn_clk_mgr.c | 12 drivers/gpu/drm/amd/display/dc/dce/dce_link_encoder.c | 44 +++ drivers/gpu/drm/amd/display/dc/dce/dce_link_encoder.h | 2 drivers/i3c/master.c | 5 drivers/md/dm-verity-target.c | 12 drivers/md/raid10.c | 3 drivers/media/usb/dvb-usb/gp8psk.c | 2 drivers/misc/vmw_vmci/vmci_context.c | 2 drivers/opp/core.c | 9 drivers/rtc/rtc-pl031.c | 6 drivers/rtc/rtc-sun6i.c | 8 drivers/scsi/cxgbi/cxgb4i/Kconfig | 1 drivers/spi/Kconfig | 3 drivers/video/fbdev/core/fbcon.c | 45 --- drivers/watchdog/rti_wdt.c | 4 fs/bfs/inode.c | 2 fs/ceph/inode.c | 2 fs/ext4/mballoc.c | 9 fs/ext4/super.c | 40 +- fs/f2fs/checkpoint.c | 2 fs/f2fs/compress.c | 2 fs/f2fs/data.c | 58 +++- fs/f2fs/debug.c | 11 fs/f2fs/f2fs.h | 11 fs/f2fs/node.c | 29 +- fs/f2fs/node.h | 4 fs/f2fs/shrinker.c | 4 fs/f2fs/super.c | 9 fs/fcntl.c | 10 fs/io_uring.c | 91 ++++-- fs/jffs2/jffs2_fs_sb.h | 1 fs/jffs2/super.c | 17 - fs/namespace.c | 9 fs/nfs/nfs42xdr.c | 36 +- fs/nfs/nfs4super.c | 2 fs/nfs/pnfs.c | 33 ++ fs/nfs/pnfs.h | 5 fs/pnode.h | 2 fs/quota/quota_tree.c | 8 fs/reiserfs/stree.c | 6 include/linux/mm.h | 5 include/uapi/linux/const.h | 5 include/uapi/linux/ethtool.h | 2 include/uapi/linux/kernel.h | 9 include/uapi/linux/lightnvm.h | 2 include/uapi/linux/mroute6.h | 2 include/uapi/linux/netfilter/x_tables.h | 2 include/uapi/linux/netlink.h | 2 include/uapi/linux/sysctl.h | 2 kernel/cgroup/cgroup-v1.c | 2 kernel/module.c | 6 kernel/time/tick-sched.c | 7 lib/zlib_dfltcc/Makefile | 2 lib/zlib_dfltcc/dfltcc.c | 6 lib/zlib_dfltcc/dfltcc_deflate.c | 3 lib/zlib_dfltcc/dfltcc_inflate.c | 4 lib/zlib_dfltcc/dfltcc_syms.c | 17 - mm/hugetlb.c | 22 + mm/memory_hotplug.c | 2 mm/page_alloc.c | 8 net/ethtool/channels.c | 6 net/ethtool/strset.c | 2 net/mptcp/protocol.c | 2 net/sched/sch_taprio.c | 17 + sound/core/pcm_native.c | 9 sound/core/rawmidi.c | 49 ++- sound/core/seq/seq_queue.h | 8 tools/include/uapi/linux/const.h | 5 82 files changed, 710 insertions(+), 536 deletions(-)
Anant Thazhemadam (2):
Bluetooth: hci_h5: close serdev device and free hu in h5_close
misc: vmw_vmci: fix kernel info-leak by initializing dbells in vmci_ctx_get_chkpt_doorbells()
Arnaldo Carvalho de Melo (1):
tools headers UAPI: Sync linux/const.h with the kernel headers
Baoquan He (1):
mm: memmap defer init doesn't work as expected
Bart Van Assche (1):
scsi: block: Fix a race in the runtime power management code
Boqun Feng (1):
fcntl: Fix potential deadlock in send_sig{io, urg}()
Chao Yu (1):
f2fs: fix shift-out-of-bounds in sanity_check_raw_super()
Christopher Obbard (1):
um: random: Register random as hwrng-core device
Chunguang Xu (1):
ext4: avoid s_mb_prefetch to be zero in individual scenarios
Daeho Jeong (1):
f2fs: fix race of pending_pages in decompression
Dan Williams (1):
device-dax: Fix range release
Daniel Vetter (1):
fbcon: Disable accelerated scrolling
Davide Caratti (1):
net/sched: sch_taprio: reset child qdiscs before freeing them
Dinghao Liu (1):
rtc: sun6i: Fix memleak in sun6i_rtc_clk_init
Eric Biggers (1):
fs/namespace.c: WARN if mnt_count has become negative
Gabriel Krisman Bertazi (1):
um: ubd: Submit all data segments atomically
Greg Kroah-Hartman (1):
Linux 5.10.5
Heiko Carstens (1):
s390: always clear kernel stack backchain before calling functions
Hyeongseok Kim (1):
dm verity: skip verity work if I/O error when system is shutting down
Ilya Leoshkevich (1):
lib/zlib: fix inflating zlib streams on s390
Ivan Vecera (1):
ethtool: fix error paths in ethnl_set_channels()
Jaegeuk Kim (1):
f2fs: avoid race condition for shrinker count
Jake Wang (1):
drm/amd/display: updated wm table for Renoir
Jamie Iles (1):
jffs2: Fix NULL pointer dereference in rp_size fs option parsing
Jan Kara (1):
quota: Don't overflow quota file offsets
Jeff Layton (1):
ceph: fix inode refcount leak when ceph_fill_inode on non-I_NEW inode fails
Jens Axboe (2):
io_uring: don't assume mm is constant across submits
io_uring: use bottom half safe lock for fixed file data
Jessica Yu (1):
module: delay kobject uevent until after module init call
Kevin Vigor (1):
md/raid10: initialize r10_bio->read_slot before use.
Mauro Carvalho Chehab (1):
media: gp8psk: initialize stats at power control logic
Michal Kubecek (1):
ethtool: fix string set id check
Mike Kravetz (1):
mm/hugetlb: fix deadlock in hugetlb_cow error path
Miroslav Benes (1):
module: set MODULE_STATE_GOING state when a module fails to load
Nicholas Piggin (1):
powerpc/64: irq replay remove decrementer overflow check
Paolo Abeni (1):
mptcp: fix security context on server socket
Pavel Begunkov (4):
io_uring: close a small race gap for files cancel
io_uring: add a helper for setting a ref node
io_uring: fix io_sqe_files_unregister() hangs
io_uring: remove racy overflow list fast checks
Petr Vorel (1):
uapi: move constants from <linux/kernel.h> to <linux/const.h>
Qinglang Miao (3):
cgroup: Fix memory leak when parsing multiple source parameters
powerpc: sysdev: add missing iounmap() on error in mpic_msgr_probe() i3c master: fix missing destroy_workqueue() on error in i3c_master_register
Quanyang Wang (1):
opp: fix memory leak in _allocate_opp_table
Randy Dunlap (3):
zlib: move EXPORT_SYMBOL() and MODULE_LICENSE() out of dfltcc_syms.c
scsi: cxgb4i: Fix TLS dependency
bfs: don't use WARNING: string when it's just info.
Rodrigo Siqueira (1):
drm/amd/display: Add get_dig_frontend implementation for DCEx
Rustam Kovhaev (1):
reiserfs: add check for an invalid ih_entry_count
Serge Semin (1):
spi: dw-bt1: Fix undefined devm_mux_control_get symbol
Takashi Iwai (3):
ALSA: seq: Use bool for snd_seq_queue internal flags
ALSA: rawmidi: Access runtime->avail always in spinlock
ALSA: pcm: Clear the full allocated memory at hw_params
Theodore Ts'o (1):
ext4: check for invalid block size early when mounting a file system
Thomas Gleixner (1):
tick/sched: Remove bogus boot "safety" check
Trond Myklebust (2):
NFSv4: Fix a pNFS layout related use-after-free race when freeing the inode NFSv4.2: Don't error when exiting early on a READ_PLUS buffer overflow
Viresh Kumar (1):
opp: Call the missing clk_put() on error
Xiaoguang Wang (1):
io_uring: check kthread stopped flag when sq thread is unparked
Zhang Qilong (1):
watchdog: rti-wdt: fix reference leak in rti_wdt_probe
Zheng Liang (1):
rtc: pl031: fix resource leak in pl031_probe
lizhe (1):
jffs2: Allow setting rp_size to zero during remounting
Greg Kroah-Hartman
maintainerDocumentation/gpu/todo.rst +18 -0
@@ -273,6 +273,24 @@ Contact: Daniel Vetter, Noralf Tronnes Level: Advanced +Garbage collect fbdev scrolling acceleration +-------------------------------------------- + +Scroll acceleration is disabled in fbcon by hard-wiring p->scrollmode = +SCROLL_REDRAW. There's a ton of code this will allow us to remove: +- lots of code in fbcon.c +- a bunch of the hooks in fbcon_ops, maybe the remaining hooks could be called + directly instead of the function table (with a switch on p->rotate) +- fb_copyarea is unused after this, and can be deleted from all drivers + +Note that not all acceleration code can be deleted, since clearing and cursor +support is still accelerated, which might be good candidates for further +deletion projects. + +Contact: Daniel Vetter + +Level: Intermediate + idr_init_base() ---------------
Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 5 PATCHLEVEL = 10 -SUBLEVEL = 4 +SUBLEVEL = 5 EXTRAVERSION = NAME = Kleptomaniac Octopus
arch/ia64/mm/init.c +2 -2
@@ -536,7 +536,7 @@ virtual_memmap_init(u64 start, u64 end, void *arg)if (map_start < map_end)memmap_init_zone ((unsigned long )(map_end - map_start), - args->nid, args->zone,page_to_pfn (map_start), + args->nid, args->zone,page_to_pfn (map_start),page_to_pfn (map_end),MEMINIT_EARLY ,NULL ,MIGRATE_MOVABLE );return 0 ; }
@@ -546,7 +546,7 @@ memmap_init (unsigned long size, int nid, unsigned long zone, unsigned long start_pfn) {if (!vmem_map) { -memmap_init_zone (size, nid, zone, start_pfn, +memmap_init_zone (size, nid, zone, start_pfn, start_pfn + size,MEMINIT_EARLY ,NULL ,MIGRATE_MOVABLE ); }else {struct page *start;
arch/powerpc/kernel/irq.c +4 -49
83 lines not on this page · raw message
arch/powerpc/kernel/time.c +3 -6
@@ -552,14 +552,11 @@ void timer_interrupt(struct pt_regs *regs)struct pt_regs *old_regs;u64 now; -/* Some implementations of hotplug will get timer interrupts while -* offline, just ignore these and we also need to set -* decrementers_next_tb as MAX to make sure __check_irq_replay -* don't replay timer interrupt when return, otherwise we'll trap -* here infinitely :( +/* +* Some implementations of hotplug will get timer interrupts while +* offline, just ignore these. */ if (unlikely (!cpu_online (smp_processor_id ()))) { - *next_tb = ~(u64 )0 ;set_dec (decrementer_max);return ; }
arch/powerpc/platforms/powernv/opal.c +1 -1
@@ -731,7 +731,7 @@ int opal_hmi_exception_early2(struct pt_regs *regs)return 1 ; } -/* HMI exception handler called in virtual mode during check_irq_replay. */ +/* HMI exception handler called in virtual mode when irqs are next enabled. */ int opal_handle_hmi_exception (struct pt_regs *regs) {/*
arch/powerpc/sysdev/mpic_msgr.c +1 -1
@@ -191,7 +191,7 @@ static int mpic_msgr_probe(struct platform_device *dev)/* IO map the message register block. */ of_address_to_resource (np,0 , &rsrc); - msgr_block_addr =ioremap (rsrc.start,resource_size (&rsrc)); + msgr_block_addr =devm_ioremap (&dev->dev, rsrc.start,resource_size (&rsrc));if (!msgr_block_addr) {dev_err (&dev->dev,"Failed to iomap MPIC message registers" );return -EFAULT ;
arch/s390/kernel/entry.S +6 -6
@@ -406,6 +406,7 @@ ENTRY(system_call) mvc __PT_PSW(16,%r11),__LC_SVC_OLD_PSW mvc __PT_INT_CODE(4,%r11),__LC_SVC_ILC stg %r14,__PT_FLAGS(%r11) + xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) ENABLE_INTS .Lsysc_do_svc: # clear user controlled register to prevent speculative use
@@ -422,7 +423,6 @@ ENTRY(system_call) jnl .Lsysc_nr_ok slag %r8,%r1,3 .Lsysc_nr_ok: - xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) stg %r2,__PT_ORIG_GPR2(%r11) stg %r7,STACK_FRAME_OVERHEAD(%r15) lg %r9,0(%r8,%r10) # get system call add.
@@ -712,8 +712,8 @@ ENTRY(pgm_check_handler) mvc __THREAD_per_address(8,%r14),__LC_PER_ADDRESS mvc __THREAD_per_cause(2,%r14),__LC_PER_CODE mvc __THREAD_per_paid(1,%r14),__LC_PER_ACCESS_ID -6: RESTORE_SM_CLEAR_PER - xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) +6: xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) + RESTORE_SM_CLEAR_PER larl %r1,pgm_check_table llgh %r10,__PT_INT_CODE+2(%r11) nill %r10,0x007f
@@ -734,8 +734,8 @@ ENTRY(pgm_check_handler) # PER event in supervisor state, must be kprobes # .Lpgm_kprobe: - RESTORE_SM_CLEAR_PER xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) + RESTORE_SM_CLEAR_PER lgr %r2,%r11 # pass pointer to pt_regs brasl %r14,do_per_trap j .Lpgm_return
@@ -777,10 +777,10 @@ ENTRY(io_int_handler) stmg %r8,%r9,__PT_PSW(%r11) mvc __PT_INT_CODE(12,%r11),__LC_SUBCHANNEL_ID xc __PT_FLAGS(8,%r11),__PT_FLAGS(%r11) + xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) TSTMSK __LC_CPU_FLAGS,_CIF_IGNORE_IRQ jo .Lio_restore TRACE_IRQS_OFF - xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) .Lio_loop: lgr %r2,%r11 # pass pointer to pt_regs lghi %r3,IO_INTERRUPT
@@ -980,10 +980,10 @@ ENTRY(ext_int_handler) mvc __PT_INT_PARM(4,%r11),__LC_EXT_PARAMS mvc __PT_INT_PARM_LONG(8,%r11),0(%r1) xc __PT_FLAGS(8,%r11),__PT_FLAGS(%r11) + xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) TSTMSK __LC_CPU_FLAGS,_CIF_IGNORE_IRQ jo .Lio_restore TRACE_IRQS_OFF - xc __SF_BACKCHAIN(8,%r15),__SF_BACKCHAIN(%r15) lgr %r2,%r11 # pass pointer to pt_regs lghi %r3,EXT_INTERRUPT brasl %r14,do_IRQ
arch/um/drivers/random.c +25 -76
154 lines not on this page · raw message
arch/um/drivers/ubd_kern.c +115 -76
311 lines not on this page · raw message
block/blk-pm.c +9 -6
@@ -67,6 +67,10 @@ int blk_pre_runtime_suspend(struct request_queue *q)WARN_ON_ONCE (q->rpm_status !=RPM_ACTIVE ); +spin_lock_irq (&q->queue_lock); + q->rpm_status =RPM_SUSPENDING ; +spin_unlock_irq (&q->queue_lock); +/* * Increase the pm_only counter before checking whether any * non-PM blk_queue_enter() calls are in progress to avoid that any
@@ -89,15 +93,14 @@ int blk_pre_runtime_suspend(struct request_queue *q)/* Switch q_usage_counter back to per-cpu mode. */ blk_mq_unfreeze_queue (q); -spin_lock_irq (&q->queue_lock); -if (ret <0 ) +if (ret <0 ) { +spin_lock_irq (&q->queue_lock); + q->rpm_status =RPM_ACTIVE ;pm_runtime_mark_last_busy (q->dev); -else - q->rpm_status =RPM_SUSPENDING ; -spin_unlock_irq (&q->queue_lock); +spin_unlock_irq (&q->queue_lock); -if (ret)blk_clear_pm_only (q); + }return ret; }
drivers/bluetooth/hci_h5.c +6 -2
@@ -251,8 +251,12 @@ static int h5_close(struct hci_uart *hu)if (h5->vnd && h5->vnd->close) h5->vnd->close (h5); -if (!hu->serdev) -kfree (h5); +if (hu->serdev) +serdev_device_close (hu->serdev); + +kfree_skb (h5->rx_skb); +kfree (h5); + h5 =NULL ;return 0 ; }
drivers/char/hw_random/Kconfig +8 -8
@@ -540,15 +540,15 @@ endif # HW_RANDOM config UML_RANDOM depends on UML - tristate "Hardware random number generator" + select HW_RANDOM + tristate "UML Random Number Generator support" help This option enables UML's "hardware" random number generator. It attaches itself to the host's /dev/random, supplying as much entropy as the host has, rather than the small amount the UML gets from its - own drivers. It registers itself as a standard hardware random number - generator, major 10, minor 183, and the canonical device name is - /dev/hwrng. - The way to make use of this is to install the rng-tools package - (check your distro, or download from - http://sourceforge.net/projects/gkernel/). rngd periodically reads - /dev/hwrng and injects the entropy into /dev/random. + own drivers. It registers itself as a rng-core driver thus providing + a device which is usually called /dev/hwrng. This hardware random + number generator does feed into the kernel's random number generator + entropy pool. + + If unsure, say Y.
drivers/dax/bus.c +21 -23
74 lines not on this page · raw message
drivers/gpu/drm/amd/display/dc/clk_mgr/dcn21/rn_clk_mgr.c +6 -6
@@ -704,24 +704,24 @@ static struct wm_table ddr4_wm_table_rn = { .wm_inst = WM_B, .wm_type = WM_TYPE_PSTATE_CHG, .pstate_latency_us = 11.72, - .sr_exit_time_us = 10.12, - .sr_enter_plus_exit_time_us = 11.48, + .sr_exit_time_us = 11.12, + .sr_enter_plus_exit_time_us = 12.48, .valid = true, }, { .wm_inst = WM_C, .wm_type = WM_TYPE_PSTATE_CHG, .pstate_latency_us = 11.72, - .sr_exit_time_us = 10.12, - .sr_enter_plus_exit_time_us = 11.48, + .sr_exit_time_us = 11.12, + .sr_enter_plus_exit_time_us = 12.48, .valid = true, }, { .wm_inst = WM_D, .wm_type = WM_TYPE_PSTATE_CHG, .pstate_latency_us = 11.72, - .sr_exit_time_us = 10.12, - .sr_enter_plus_exit_time_us = 11.48, + .sr_exit_time_us = 11.12, + .sr_enter_plus_exit_time_us = 12.48, .valid = true, }, }
drivers/gpu/drm/amd/display/dc/dce/dce_link_encoder.c +42 -2
62 lines not on this page · raw message
drivers/gpu/drm/amd/display/dc/dce/dce_link_encoder.h +2 -0
@@ -295,6 +295,8 @@ void dce110_link_encoder_connect_dig_be_to_fe(enum engine_id engine, bool connect); +unsigned int dce110_get_dig_frontend (struct link_encoder *enc); +void dce110_link_encoder_set_dp_phy_pattern_training_pattern (struct link_encoder *enc,uint32_t index);
drivers/i3c/master.c +4 -1
@@ -2537,7 +2537,7 @@ int i3c_master_register(struct i3c_master_controller *master, ret =i3c_master_bus_init (master);if (ret) - goto err_put_dev; + goto err_destroy_wq; ret =device_add (&master->dev);if (ret)
@@ -2568,6 +2568,9 @@ int i3c_master_register(struct i3c_master_controller *master, err_cleanup_bus:i3c_master_bus_cleanup (master); +err_destroy_wq: +destroy_workqueue (master->wq); + err_put_dev:put_device (&master->dev);
drivers/md/dm-verity-target.c +11 -1
@@ -537,6 +537,15 @@ static int verity_verify_io(struct dm_verity_io *io)return 0 ; } +/* +* Skip verity work in response to I/O error when system is shutting down. +*/ +static inline bool verity_is_system_shutting_down (void ) +{ +return system_state ==SYSTEM_HALT || system_state ==SYSTEM_POWER_OFF + || system_state ==SYSTEM_RESTART ; +} +/* * End one "io" structure with a given error. */
@@ -564,7 +573,8 @@ static void verity_end_io(struct bio *bio) {struct dm_verity_io *io = bio->bi_private; -if (bio->bi_status && !verity_fec_is_enabled (io->v)) { +if (bio->bi_status && + (!verity_fec_is_enabled (io->v) ||verity_is_system_shutting_down ())) {verity_finish_io (io, bio->bi_status);return ; }
drivers/md/raid10.c +2 -1
@@ -1128,7 +1128,7 @@ static void raid10_read_request(struct mddev *mddev, struct bio *bio,struct md_rdev *err_rdev =NULL ;gfp_t gfp =GFP_NOIO ; -if (r10_bio->devs[slot].rdev) { +if (slot >=0 && r10_bio->devs[slot].rdev) {/* * This is an error retry, but we cannot * safely dereference the rdev in the r10_bio,
@@ -1493,6 +1493,7 @@ static void __make_request(struct mddev *mddev, struct bio *bio, int sectors) r10_bio->mddev = mddev; r10_bio->sector = bio->bi_iter.bi_sector; r10_bio->state =0 ; + r10_bio->read_slot =-1 ;memset (r10_bio->devs,0 ,sizeof (r10_bio->devs[0 ]) * conf->copies);if (bio_data_dir (bio) ==READ )
drivers/media/usb/dvb-usb/gp8psk.c +1 -1
@@ -182,7 +182,7 @@ static int gp8psk_load_bcm4500fw(struct dvb_usb_device *d)static int gp8psk_power_ctrl (struct dvb_usb_device *d,int onoff) { -u8 status, buf; +u8 status =0 , buf;int gp_product_id =le16_to_cpu (d->udev->descriptor.idProduct);if (onoff) {
drivers/misc/vmw_vmci/vmci_context.c +1 -1
@@ -743,7 +743,7 @@ static int vmci_ctx_get_chkpt_doorbells(struct vmci_ctx *context,return VMCI_ERROR_MORE_DATA ; } - dbells =kmalloc (data_size,GFP_ATOMIC ); + dbells =kzalloc (data_size,GFP_ATOMIC );if (!dbells)return VMCI_ERROR_NO_MEM ;
drivers/opp/core.c +7 -2
@@ -1102,7 +1102,7 @@ static struct opp_table *_allocate_opp_table(struct device *dev, int index)if (IS_ERR (opp_table->clk)) { ret =PTR_ERR (opp_table->clk);if (ret == -EPROBE_DEFER ) - goto err; + goto remove_opp_dev;dev_dbg (dev,"%s: Couldn't find clock: %d\n" , __func__, ret); }
@@ -1111,7 +1111,7 @@ static struct opp_table *_allocate_opp_table(struct device *dev, int index) ret =dev_pm_opp_of_find_icc_paths (dev, opp_table);if (ret) {if (ret == -EPROBE_DEFER ) - goto err; + goto put_clk;dev_warn (dev,"%s: Error finding interconnect paths: %d\n" , __func__, ret);
@@ -1125,6 +1125,11 @@ static struct opp_table *_allocate_opp_table(struct device *dev, int index)list_add (&opp_table->node, &opp_tables);return opp_table; +put_clk: +if (!IS_ERR (opp_table->clk)) +clk_put (opp_table->clk); +remove_opp_dev: +_remove_opp_dev (opp_dev, opp_table); err:kfree (opp_table);return ERR_PTR (ret);
drivers/rtc/rtc-pl031.c +4 -2
@@ -361,8 +361,10 @@ static int pl031_probe(struct amba_device *adev, const struct amba_id *id)device_init_wakeup (&adev->dev, true); ldata->rtc =devm_rtc_allocate_device (&adev->dev); -if (IS_ERR (ldata->rtc)) -return PTR_ERR (ldata->rtc); +if (IS_ERR (ldata->rtc)) { + ret =PTR_ERR (ldata->rtc); + goto out; + } ldata->rtc->ops = ops; ldata->rtc->range_min = vendor->range_min;
drivers/rtc/rtc-sun6i.c +5 -3
@@ -272,7 +272,7 @@ static void __init sun6i_rtc_clk_init(struct device_node *node, 300000000);if (IS_ERR (rtc->int_osc)) {pr_crit ("Couldn't register the internal oscillator\n" ); -return ; + goto err; } parents[0 ] =clk_hw_get_name (rtc->int_osc);
@@ -290,7 +290,7 @@ static void __init sun6i_rtc_clk_init(struct device_node *node, rtc->losc =clk_register (NULL , &rtc->hw);if (IS_ERR (rtc->losc)) {pr_crit ("Couldn't register the LOSC clock\n" ); -return ; + goto err_register; } of_property_read_string_index(node, "clock-output-names", 1,
@@ -301,7 +301,7 @@ static void __init sun6i_rtc_clk_init(struct device_node *node, &rtc->lock);if (IS_ERR (rtc->ext_losc)) {pr_crit ("Couldn't register the LOSC external gate\n" ); -return ; + goto err_register; } clk_data->num =2 ;
@@ -314,6 +314,8 @@ static void __init sun6i_rtc_clk_init(struct device_node *node,of_clk_add_hw_provider (node, of_clk_hw_onecell_get, clk_data);return ; +err_register: +clk_hw_unregister_fixed_rate (rtc->int_osc); err:kfree (clk_data); }
drivers/scsi/cxgbi/cxgb4i/Kconfig +1 -0
@@ -4,6 +4,7 @@ config SCSI_CXGB4_ISCSI depends on PCI && INET && (IPV6 || IPV6=n) depends on THERMAL || !THERMAL depends on ETHERNET + depends on TLS || TLS=n select NET_VENDOR_CHELSIO select CHELSIO_T4 select CHELSIO_LIB
drivers/spi/Kconfig +1 -2
@@ -256,6 +256,7 @@ config SPI_DW_BT1 tristate "Baikal-T1 SPI driver for DW SPI core" depends on MIPS_BAIKAL_T1 || COMPILE_TEST select MULTIPLEXER + select MUX_MMIO help Baikal-T1 SoC is equipped with three DW APB SSI-based MMIO SPI controllers. Two of them are pretty much normal: with IRQ, DMA,
@@ -269,8 +270,6 @@ config SPI_DW_BT1 config SPI_DW_BT1_DIRMAP bool "Directly mapped Baikal-T1 Boot SPI flash support" depends on SPI_DW_BT1 - select MULTIPLEXER - select MUX_MMIO help Directly mapped SPI flash memory is an interface specific to the Baikal-T1 System Boot Controller. It is a 16MB MMIO region, which
drivers/video/fbdev/core/fbcon.c +8 -37
78 lines not on this page · raw message
drivers/watchdog/rti_wdt.c +3 -1
@@ -227,8 +227,10 @@ static int rti_wdt_probe(struct platform_device *pdev)pm_runtime_enable (dev); ret =pm_runtime_get_sync (dev); -if (ret) +if (ret) { +pm_runtime_put_noidle (dev);return dev_err_probe (dev, ret,"runtime pm failed\n" ); + }platform_set_drvdata (pdev, wdt);
fs/bfs/inode.c +1 -1
@@ -350,7 +350,7 @@ static int bfs_fill_super(struct super_block *s, void *data, int silent) info->si_lasti = (le32_to_cpu (bfs_sb->s_start) -BFS_BSIZE ) /sizeof (struct bfs_inode ) +BFS_ROOT_INO -1 ;if (info->si_lasti ==BFS_MAX_LASTI ) -printf ("WARNING: filesystem %s was created with 512 inodes, the real maximum is 511, mounting anyway\n" , s->s_id); +printf ("NOTE: filesystem %s was created with 512 inodes, the real maximum is 511, mounting anyway\n" , s->s_id);else if (info->si_lasti >BFS_MAX_LASTI ) {printf ("Impossible last inode number %lu > %d on %s\n" , info->si_lasti,BFS_MAX_LASTI , s->s_id); goto out1;
fs/ceph/inode.c +2 -0
@@ -1335,6 +1335,8 @@ int ceph_fill_trace(struct super_block *sb, struct ceph_mds_request *req) in, ceph_vinop(in));if (in->i_state &I_NEW )discard_new_inode (in); +else +iput (in); goto done; } req->r_target_inode = in;
fs/ext4/mballoc.c +5 -4
@@ -2395,9 +2395,9 @@ ext4_mb_regular_allocator(struct ext4_allocation_context *ac) nr = sbi->s_mb_prefetch;if (ext4_has_feature_flex_bg (sb)) { - nr = (group / sbi->s_mb_prefetch) * - sbi->s_mb_prefetch; - nr = nr + sbi->s_mb_prefetch - group; + nr =1 << sbi->s_log_groups_per_flex; + nr -= group & (nr -1 ); + nr =min (nr, sbi->s_mb_prefetch); } prefetch_grp =ext4_mb_prefetch (sb, group, nr, &prefetch_ios);
@@ -2733,7 +2733,8 @@ static int ext4_mb_init_backend(struct super_block *sb)if (ext4_has_feature_flex_bg (sb)) {/* a single flex group is supposed to be read by a single IO */ - sbi->s_mb_prefetch =1 << sbi->s_es->s_log_groups_per_flex; + sbi->s_mb_prefetch =min (1 << sbi->s_es->s_log_groups_per_flex, +BLK_MAX_SEGMENT_SIZE >> (sb->s_blocksize_bits -9 )); sbi->s_mb_prefetch *=8 ;/* 8 prefetch IOs in flight at most */ }else { sbi->s_mb_prefetch =32 ;
fs/ext4/super.c +16 -24
@@ -4186,18 +4186,25 @@ static int ext4_fill_super(struct super_block *sb, void *data, int silent)*/ sbi->s_li_wait_mult =EXT4_DEF_LI_WAIT_MULT ; - blocksize =BLOCK_SIZE <<le32_to_cpu (es->s_log_block_size); - -if (blocksize ==PAGE_SIZE ) -set_opt (sb,DIOREAD_NOLOCK ); - -if (blocksize <EXT4_MIN_BLOCK_SIZE || - blocksize >EXT4_MAX_BLOCK_SIZE ) { +if (le32_to_cpu (es->s_log_block_size) > + (EXT4_MAX_BLOCK_LOG_SIZE -EXT4_MIN_BLOCK_LOG_SIZE )) {ext4_msg (sb,KERN_ERR , -"Unsupported filesystem blocksize %d (%d log_block_size)" , - blocksize,le32_to_cpu (es->s_log_block_size)); +"Invalid log block size: %u" , +le32_to_cpu (es->s_log_block_size)); goto failed_mount; } +if (le32_to_cpu (es->s_log_cluster_size) > + (EXT4_MAX_CLUSTER_LOG_SIZE -EXT4_MIN_BLOCK_LOG_SIZE )) { +ext4_msg (sb,KERN_ERR , +"Invalid log cluster size: %u" , +le32_to_cpu (es->s_log_cluster_size)); + goto failed_mount; + } + + blocksize =EXT4_MIN_BLOCK_SIZE <<le32_to_cpu (es->s_log_block_size); + +if (blocksize ==PAGE_SIZE ) +set_opt (sb,DIOREAD_NOLOCK );if (le32_to_cpu (es->s_rev_level) ==EXT4_GOOD_OLD_REV ) { sbi->s_inode_size =EXT4_GOOD_OLD_INODE_SIZE ;
@@ -4416,21 +4423,6 @@ static int ext4_fill_super(struct super_block *sb, void *data, int silent)if (!ext4_feature_set_ok (sb, (sb_rdonly (sb)))) goto failed_mount; -if (le32_to_cpu (es->s_log_block_size) > - (EXT4_MAX_BLOCK_LOG_SIZE -EXT4_MIN_BLOCK_LOG_SIZE )) { -ext4_msg (sb,KERN_ERR , -"Invalid log block size: %u" , -le32_to_cpu (es->s_log_block_size)); - goto failed_mount; - } -if (le32_to_cpu (es->s_log_cluster_size) > - (EXT4_MAX_CLUSTER_LOG_SIZE -EXT4_MIN_BLOCK_LOG_SIZE )) { -ext4_msg (sb,KERN_ERR , -"Invalid log cluster size: %u" , -le32_to_cpu (es->s_log_cluster_size)); - goto failed_mount; - } -if (le16_to_cpu (sbi->s_es->s_reserved_gdt_blocks) > (blocksize /4 )) { ext4_msg(sb, KERN_ERR, "Number of reserved GDT blocks insanely large: %d",
fs/f2fs/checkpoint.c +1 -1
@@ -1600,7 +1600,7 @@ int f2fs_write_checkpoint(struct f2fs_sb_info *sbi, struct cp_control *cpc) goto out; } -if (NM_I (sbi)->dirty_nat_cnt ==0 && +if (NM_I (sbi)->nat_cnt[DIRTY_NAT ] ==0 &&SIT_I (sbi)->dirty_sentries ==0 &&prefree_segments (sbi) ==0 ) {f2fs_flush_sit_entries (sbi, cpc);
fs/f2fs/compress.c +0 -2
@@ -798,8 +798,6 @@ void f2fs_decompress_pages(struct bio *bio, struct page *page, bool verity)if (cops->destroy_decompress_ctx) cops->destroy_decompress_ctx (dic); out_free_dic: -if (verity) -atomic_set (&dic->pending_pages, dic->nr_cpages);if (!verity)f2fs_decompress_end_io (dic->rpages, dic->cluster_size, ret, false);
fs/f2fs/data.c +47 -11
115 lines not on this page · raw message
fs/f2fs/debug.c +6 -5
@@ -145,8 +145,8 @@ static void update_general_status(struct f2fs_sb_info *sbi) si->node_pages =NODE_MAPPING (sbi)->nrpages;if (sbi->meta_inode) si->meta_pages =META_MAPPING (sbi)->nrpages; - si->nats =NM_I (sbi)->nat_cnt; - si->dirty_nats =NM_I (sbi)->dirty_nat_cnt; + si->nats =NM_I (sbi)->nat_cnt[TOTAL_NAT ]; + si->dirty_nats =NM_I (sbi)->nat_cnt[DIRTY_NAT ]; si->sits =MAIN_SEGS (sbi); si->dirty_sits =SIT_I (sbi)->dirty_sentries; si->free_nids =NM_I (sbi)->nid_cnt[FREE_NID ];
@@ -278,9 +278,10 @@ static void update_mem_info(struct f2fs_sb_info *sbi) si->cache_mem += (NM_I (sbi)->nid_cnt[FREE_NID ] +NM_I (sbi)->nid_cnt[PREALLOC_NID ]) *sizeof (struct free_nid ); - si->cache_mem +=NM_I (sbi)->nat_cnt *sizeof (struct nat_entry ); - si->cache_mem +=NM_I (sbi)->dirty_nat_cnt * -sizeof (struct nat_entry_set ); + si->cache_mem +=NM_I (sbi)->nat_cnt[TOTAL_NAT ] * +sizeof (struct nat_entry ); + si->cache_mem +=NM_I (sbi)->nat_cnt[DIRTY_NAT ] * +sizeof (struct nat_entry_set ); si->cache_mem += si->inmem_pages *sizeof (struct inmem_pages );for (i =0 ; i <MAX_INO_ENTRY ; i++) si->cache_mem += sbi->im[i].ino_num *sizeof (struct ino_entry );
fs/f2fs/f2fs.h +9 -2
@@ -894,6 +894,13 @@ enum nid_state { MAX_NID_STATE, }; +enum nat_state { +TOTAL_NAT , +DIRTY_NAT , +RECLAIMABLE_NAT , +MAX_NAT_STATE , +}; +struct f2fs_nm_info {block_t nat_blkaddr;/* base disk address of NAT */ nid_t max_nid;/* maximum possible node ids */
@@ -909,8 +916,7 @@ struct f2fs_nm_info {struct rw_semaphore nat_tree_lock;/* protect nat_tree_lock */ struct list_head nat_entries;/* cached nat entry list (clean) */ spinlock_t nat_list_lock;/* protect clean nat entry list */ -unsigned int nat_cnt;/* the # of cached nat entries */ -unsigned int dirty_nat_cnt;/* total num of nat entries in set */ +unsigned int nat_cnt[MAX_NAT_STATE ];/* the # of cached nat entries */ unsigned int nat_blocks;/* # of nat blocks */ /* free node ids management */
@@ -1404,6 +1410,7 @@ struct decompress_io_ctx {size_t rlen;/* valid data length in rbuf */ size_t clen;/* valid data length in cbuf */ atomic_t pending_pages;/* in-flight compressed page count */ +atomic_t verity_pages;/* in-flight page count for verity */ bool failed;/* indicate IO error during decompression */ void *private;/* payload buffer for specified decompression algorithm */ void *private2;/* extra payload buffer */
fs/f2fs/node.c +18 -11
@@ -62,8 +62,8 @@ bool f2fs_available_free_memory(struct f2fs_sb_info *sbi, int type) sizeof(struct free_nid)) >> PAGE_SHIFT; res = mem_size < ((avail_ram * nm_i->ram_thresh /100 ) >>2 ); }else if (type ==NAT_ENTRIES ) { - mem_size = (nm_i->nat_cnt *sizeof (struct nat_entry )) >> -PAGE_SHIFT ; + mem_size = (nm_i->nat_cnt[TOTAL_NAT ] * +sizeof (struct nat_entry )) >>PAGE_SHIFT ; res = mem_size < ((avail_ram * nm_i->ram_thresh /100 ) >>2 );if (excess_cached_nats (sbi)) res = false;
@@ -177,7 +177,8 @@ static struct nat_entry *__init_nat_entry(struct f2fs_nm_info *nm_i,list_add_tail (&ne->list, &nm_i->nat_entries);spin_unlock (&nm_i->nat_list_lock); - nm_i->nat_cnt++; + nm_i->nat_cnt[TOTAL_NAT ]++; + nm_i->nat_cnt[RECLAIMABLE_NAT ]++;return ne; }
@@ -207,7 +208,8 @@ static unsigned int __gang_lookup_nat_cache(struct f2fs_nm_info *nm_i,static void __del_from_nat_cache (struct f2fs_nm_info *nm_i,struct nat_entry *e) {radix_tree_delete (&nm_i->nat_root,nat_get_nid (e)); - nm_i->nat_cnt--; + nm_i->nat_cnt[TOTAL_NAT ]--; + nm_i->nat_cnt[RECLAIMABLE_NAT ]--;__free_nat_entry (e); }
@@ -253,7 +255,8 @@ static void __set_nat_cache_dirty(struct f2fs_nm_info *nm_i,if (get_nat_flag (ne,IS_DIRTY )) goto refresh_list; - nm_i->dirty_nat_cnt++; + nm_i->nat_cnt[DIRTY_NAT ]++; + nm_i->nat_cnt[RECLAIMABLE_NAT ]--;set_nat_flag (ne,IS_DIRTY , true); refresh_list:spin_lock (&nm_i->nat_list_lock);
@@ -273,7 +276,8 @@ static void __clear_nat_cache_dirty(struct f2fs_nm_info *nm_i,set_nat_flag (ne,IS_DIRTY , false); set->entry_cnt--; - nm_i->dirty_nat_cnt--; + nm_i->nat_cnt[DIRTY_NAT ]--; + nm_i->nat_cnt[RECLAIMABLE_NAT ]++; } static unsigned int __gang_lookup_nat_set(struct f2fs_nm_info *nm_i,
@@ -2944,14 +2948,17 @@ int f2fs_flush_nat_entries(struct f2fs_sb_info *sbi, struct cp_control *cpc)LIST_HEAD (sets);int err =0 ; -/* during unmount, let's flush nat_bits before checking dirty_nat_cnt */ +/* +* during unmount, let's flush nat_bits before checking +* nat_cnt[DIRTY_NAT]. +*/ if (enabled_nat_bits (sbi, cpc)) {down_write (&nm_i->nat_tree_lock);remove_nats_in_journal (sbi);up_write (&nm_i->nat_tree_lock); } -if (!nm_i->dirty_nat_cnt) +if (!nm_i->nat_cnt[DIRTY_NAT ])return 0 ;down_write (&nm_i->nat_tree_lock);
@@ -2962,7 +2969,8 @@ int f2fs_flush_nat_entries(struct f2fs_sb_info *sbi, struct cp_control *cpc)* into nat entry set. */ if (enabled_nat_bits (sbi, cpc) || - !__has_cursum_space (journal, nm_i->dirty_nat_cnt,NAT_JOURNAL )) + !__has_cursum_space (journal, + nm_i->nat_cnt[DIRTY_NAT ],NAT_JOURNAL ))remove_nats_in_journal (sbi); while ((found = __gang_lookup_nat_set(nm_i,
@@ -3086,7 +3094,6 @@ static int init_node_manager(struct f2fs_sb_info *sbi)F2FS_RESERVED_NODE_NUM ; nm_i->nid_cnt[FREE_NID ] =0 ; nm_i->nid_cnt[PREALLOC_NID ] =0 ; - nm_i->nat_cnt =0 ; nm_i->ram_thresh =DEF_RAM_THRESHOLD ; nm_i->ra_nid_pages =DEF_RA_NID_PAGES ; nm_i->dirty_nats_ratio =DEF_DIRTY_NAT_RATIO_THRESHOLD ;
@@ -3220,7 +3227,7 @@ void f2fs_destroy_node_manager(struct f2fs_sb_info *sbi)__del_from_nat_cache (nm_i, natvec[idx]); } } -f2fs_bug_on (sbi, nm_i->nat_cnt); +f2fs_bug_on (sbi, nm_i->nat_cnt[TOTAL_NAT ]);/* destroy nat set cache */ nid =0 ;
fs/f2fs/node.h +2 -2
@@ -126,13 +126,13 @@ static inline void raw_nat_from_node_info(struct f2fs_nat_entry *raw_ne,static inline bool excess_dirty_nats (struct f2fs_sb_info *sbi) { -return NM_I (sbi)->dirty_nat_cnt >=NM_I (sbi)->max_nid * +return NM_I (sbi)->nat_cnt[DIRTY_NAT ] >=NM_I (sbi)->max_nid *NM_I (sbi)->dirty_nats_ratio /100 ; }static inline bool excess_cached_nats (struct f2fs_sb_info *sbi) { -return NM_I (sbi)->nat_cnt >=DEF_NAT_CACHE_THRESHOLD ; +return NM_I (sbi)->nat_cnt[TOTAL_NAT ] >=DEF_NAT_CACHE_THRESHOLD ; }static inline bool excess_dirty_nodes (struct f2fs_sb_info *sbi)
fs/f2fs/shrinker.c +1 -3
@@ -18,9 +18,7 @@ static unsigned int shrinker_run_no;static unsigned long __count_nat_entries (struct f2fs_sb_info *sbi) { -long count =NM_I (sbi)->nat_cnt -NM_I (sbi)->dirty_nat_cnt; - -return count >0 ? count :0 ; +return NM_I (sbi)->nat_cnt[RECLAIMABLE_NAT ]; }static unsigned long __count_free_nids (struct f2fs_sb_info *sbi)
fs/f2fs/super.c +4 -5
@@ -2744,7 +2744,6 @@ static int sanity_check_raw_super(struct f2fs_sb_info *sbi,block_t total_sections, blocks_per_seg;struct f2fs_super_block *raw_super = (struct f2fs_super_block *) (bh->b_data +F2FS_SUPER_OFFSET ); -unsigned int blocksize;size_t crc_offset =0 ;__u32 crc =0 ;
@@ -2778,10 +2777,10 @@ static int sanity_check_raw_super(struct f2fs_sb_info *sbi, }/* Currently, support only 4KB block size */ - blocksize =1 <<le32_to_cpu (raw_super->log_blocksize); -if (blocksize !=F2FS_BLKSIZE ) { -f2fs_info (sbi,"Invalid blocksize (%u), supports only 4KB" , - blocksize); +if (le32_to_cpu (raw_super->log_blocksize) !=F2FS_BLKSIZE_BITS ) { +f2fs_info (sbi,"Invalid log_blocksize (%u), supports only %u" , +le32_to_cpu (raw_super->log_blocksize), +F2FS_BLKSIZE_BITS );return -EFSCORRUPTED ; }
fs/fcntl.c +6 -4
@@ -781,9 +781,10 @@ void send_sigio(struct fown_struct *fown, int fd, int band) {struct task_struct *p;enum pid_type type; +unsigned long flags;struct pid *pid; -read_lock (&fown->lock); +read_lock_irqsave (&fown->lock, flags); type = fown->pid_type; pid = fown->pid;
@@ -804,7 +805,7 @@ void send_sigio(struct fown_struct *fown, int fd, int band)read_unlock (&tasklist_lock); } out_unlock_fown: -read_unlock (&fown->lock); +read_unlock_irqrestore (&fown->lock, flags); } static void send_sigurg_to_task(struct task_struct *p,
@@ -819,9 +820,10 @@ int send_sigurg(struct fown_struct *fown)struct task_struct *p;enum pid_type type;struct pid *pid; +unsigned long flags;int ret =0 ; -read_lock (&fown->lock); +read_lock_irqsave (&fown->lock, flags); type = fown->pid_type; pid = fown->pid;
@@ -844,7 +846,7 @@ int send_sigurg(struct fown_struct *fown)read_unlock (&tasklist_lock); } out_unlock_fown: -read_unlock (&fown->lock); +read_unlock_irqrestore (&fown->lock, flags);return ret; }
fs/io_uring.c +59 -32
190 lines not on this page · raw message
fs/jffs2/jffs2_fs_sb.h +1 -0
@@ -38,6 +38,7 @@ struct jffs2_mount_opts {* users. This is implemented simply by means of not allowing the * latter users to write to the file system if the amount if the * available space is less then 'rp_size'. */ +bool set_rp_size;unsigned int rp_size; };
fs/jffs2/super.c +10 -7
@@ -88,7 +88,7 @@ static int jffs2_show_options(struct seq_file *s, struct dentry *root)if (opts->override_compr)seq_printf (s,",compr=%s" ,jffs2_compr_name (opts->compr)); -if (opts->rp_size) +if (opts->set_rp_size)seq_printf (s,",rp_size=%u" , opts->rp_size /1024 );return 0 ;
@@ -202,11 +202,8 @@ static int jffs2_parse_param(struct fs_context *fc, struct fs_parameter *param)case Opt_rp_size:if (result.uint_32 >UINT_MAX /1024 )return invalf (fc,"jffs2: rp_size unrepresentable" ); - opt = result.uint_32 *1024 ; -if (opt > c->mtd->size) -return invalf (fc,"jffs2: Too large reserve pool specified, max is %llu KB" , - c->mtd->size /1024 ); - c->mount_opts.rp_size = opt; + c->mount_opts.rp_size = result.uint_32 *1024 ; + c->mount_opts.set_rp_size = true;break ;default :return -EINVAL ;
@@ -225,8 +222,10 @@ static inline void jffs2_update_mount_opts(struct fs_context *fc) c->mount_opts.override_compr = new_c->mount_opts.override_compr; c->mount_opts.compr = new_c->mount_opts.compr; } -if (new_c->mount_opts.rp_size) +if (new_c->mount_opts.set_rp_size) { + c->mount_opts.set_rp_size = new_c->mount_opts.set_rp_size; c->mount_opts.rp_size = new_c->mount_opts.rp_size; + }mutex_unlock (&c->alloc_sem); }
@@ -266,6 +265,10 @@ static int jffs2_fill_super(struct super_block *sb, struct fs_context *fc) c->mtd = sb->s_mtd; c->os_priv = sb; +if (c->mount_opts.rp_size > c->mtd->size) +return invalf (fc,"jffs2: Too large reserve pool specified, max is %llu KB" , + c->mtd->size /1024 ); +/* Initialize JFFS2 superblock locks, the further initialization will * be done later */ mutex_init (&c->alloc_sem);
fs/namespace.c +6 -3
@@ -156,10 +156,10 @@ static inline void mnt_add_count(struct mount *mnt, int n)/* * vfsmount lock must be held for write */ -unsigned int mnt_get_count (struct mount *mnt) +int mnt_get_count (struct mount *mnt) {#ifdef CONFIG_SMP -unsigned int count =0 ; +int count =0 ;int cpu;for_each_possible_cpu (cpu) {
@@ -1139,6 +1139,7 @@ static DECLARE_DELAYED_WORK(delayed_mntput_work, delayed_mntput);static void mntput_no_expire (struct mount *mnt) {LIST_HEAD (list); +int count;rcu_read_lock ();if (likely (READ_ONCE (mnt->mnt_ns))) {
@@ -1162,7 +1163,9 @@ static void mntput_no_expire(struct mount *mnt)*/ smp_mb ();mnt_add_count (mnt,-1 ); -if (mnt_get_count (mnt)) { + count =mnt_get_count (mnt); +if (count !=0 ) { +WARN_ON (count <0 );rcu_read_unlock ();unlock_mount_hash ();return ;
fs/nfs/nfs42xdr.c +17 -19
@@ -1019,29 +1019,24 @@ static int decode_deallocate(struct xdr_stream *xdr, struct nfs42_falloc_res *rereturn decode_op_hdr (xdr,OP_DEALLOCATE ); } -static int decode_read_plus_data (struct xdr_stream *xdr,struct nfs_pgio_res *res, -uint32_t *eof) +static int decode_read_plus_data (struct xdr_stream *xdr, +struct nfs_pgio_res *res) {uint32_t count, recvd;uint64_t offset;__be32 *p; p =xdr_inline_decode (xdr,8 +4 ); -if (unlikely (!p)) -return -EIO ; +if (!p) +return 1 ; p =xdr_decode_hyper (p, &offset); count =be32_to_cpup (p); recvd =xdr_align_data (xdr, res->count, count); res->count += recvd; -if (count > recvd) { -dprintk ("NFS: server cheating in read reply: " -"count %u > recvd %u\n" , count, recvd); - *eof =0 ; +if (count > recvd)return 1 ; - } -return 0 ; }
@@ -1052,18 +1047,16 @@ static int decode_read_plus_hole(struct xdr_stream *xdr, struct nfs_pgio_res *re__be32 *p; p =xdr_inline_decode (xdr,8 +8 ); -if (unlikely (!p)) -return -EIO ; +if (!p) +return 1 ; p =xdr_decode_hyper (p, &offset); p =xdr_decode_hyper (p, &length); recvd =xdr_expand_hole (xdr, res->count, length); res->count += recvd; -if (recvd < length) { - *eof =0 ; +if (recvd < length)return 1 ; - }return 0 ; }
@@ -1088,12 +1081,12 @@ static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res)for (i =0 ; i < segments; i++) { p =xdr_inline_decode (xdr,4 ); -if (unlikely (!p)) -return -EIO ; +if (!p) + goto early_out; type =be32_to_cpup (p++);if (type ==NFS4_CONTENT_DATA ) - status =decode_read_plus_data (xdr, res, &eof); + status =decode_read_plus_data (xdr, res);else if (type ==NFS4_CONTENT_HOLE ) status =decode_read_plus_hole (xdr, res, &eof);else
@@ -1102,12 +1095,17 @@ static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res)if (status <0 )return status;if (status >0 ) -break ; + goto early_out; } out: res->eof = eof;return 0 ; +early_out: +if (unlikely (!i)) +return -EIO ; + res->eof =0 ; +return 0 ; }static int decode_seek (struct xdr_stream *xdr,struct nfs42_seek_res *res)
fs/nfs/nfs4super.c +1 -1
@@ -67,7 +67,7 @@ static void nfs4_evict_inode(struct inode *inode)nfs_inode_evict_delegation (inode);/* Note that above delegreturn would trigger pnfs return-on-close */ pnfs_return_layout (inode); -pnfs_destroy_layout (NFS_I (inode)); +pnfs_destroy_layout_final (NFS_I (inode));/* First call standard NFS clear_inode() code */ nfs_clear_inode (inode);nfs4_xattr_cache_zap (inode);
fs/nfs/pnfs.c +31 -2
@@ -294,6 +294,7 @@ void pnfs_put_layout_hdr(struct pnfs_layout_hdr *lo) {struct inode *inode; +unsigned long i_state;if (!lo)return ;
@@ -304,8 +305,12 @@ pnfs_put_layout_hdr(struct pnfs_layout_hdr *lo)if (!list_empty (&lo->plh_segs))WARN_ONCE (1 ,"NFS: BUG unfreed layout segments.\n" );pnfs_detach_layout_hdr (lo); + i_state = inode->i_state;spin_unlock (&inode->i_lock);pnfs_free_layout_hdr (lo); +/* Notify pnfs_destroy_layout_final() that we're done */ +if (i_state & (I_FREEING |I_CLEAR )) +wake_up_var (lo); } }
@@ -734,8 +739,7 @@ pnfs_free_lseg_list(struct list_head *free_me) } } -void -pnfs_destroy_layout (struct nfs_inode *nfsi) +static struct pnfs_layout_hdr *__pnfs_destroy_layout (struct nfs_inode *nfsi) {struct pnfs_layout_hdr *lo;LIST_HEAD (tmp_list);
@@ -753,9 +757,34 @@ pnfs_destroy_layout(struct nfs_inode *nfsi)pnfs_put_layout_hdr (lo); }else spin_unlock (&nfsi->vfs_inode.i_lock); +return lo; +} + +void pnfs_destroy_layout (struct nfs_inode *nfsi) +{ +__pnfs_destroy_layout (nfsi); }EXPORT_SYMBOL_GPL (pnfs_destroy_layout); +static bool pnfs_layout_removed (struct nfs_inode *nfsi, +struct pnfs_layout_hdr *lo) +{ +bool ret; + +spin_lock (&nfsi->vfs_inode.i_lock); + ret = nfsi->layout != lo; +spin_unlock (&nfsi->vfs_inode.i_lock); +return ret; +} + +void pnfs_destroy_layout_final (struct nfs_inode *nfsi) +{ +struct pnfs_layout_hdr *lo =__pnfs_destroy_layout (nfsi); + +if (lo) +wait_var_event (lo,pnfs_layout_removed (nfsi, lo)); +} +static bool pnfs_layout_add_bulk_destroy_list (struct inode *inode,struct list_head *layout_list)
fs/nfs/pnfs.h +5 -0
@@ -266,6 +266,7 @@ struct pnfs_layout_segment *pnfs_layout_process(struct nfs4_layoutget *lgp);void pnfs_layoutget_free (struct nfs4_layoutget *lgp);void pnfs_free_lseg_list (struct list_head *tmp_list);void pnfs_destroy_layout (struct nfs_inode *); +void pnfs_destroy_layout_final (struct nfs_inode *);void pnfs_destroy_all_layouts (struct nfs_client *); int pnfs_destroy_layouts_byfsid(struct nfs_client *clp, struct nfs_fsid *fsid,
@@ -710,6 +711,10 @@ static inline void pnfs_destroy_layout(struct nfs_inode *nfsi) { } +static inline void pnfs_destroy_layout_final (struct nfs_inode *nfsi) +{ +} +static inline struct pnfs_layout_segment *pnfs_get_lseg (struct pnfs_layout_segment *lseg) {
fs/pnode.h +1 -1
@@ -44,7 +44,7 @@ int propagate_mount_busy(struct mount *, int);void propagate_mount_unlock (struct mount *);void mnt_release_group_id (struct mount *);int get_dominating_id (struct mount *mnt,const struct path *root); -unsigned int mnt_get_count (struct mount *mnt); +int mnt_get_count (struct mount *mnt);void mnt_set_mountpoint (struct mount *,struct mountpoint *,struct mount *); void mnt_change_mountpoint(struct mount *parent, struct mountpoint *mp,
fs/quota/quota_tree.c +4 -4
@@ -62,7 +62,7 @@ static ssize_t read_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf)memset (buf,0 , info->dqi_usable_bs);return sb->s_op->quota_read (sb, info->dqi_type, buf, - info->dqi_usable_bs, blk << info->dqi_blocksize_bits); + info->dqi_usable_bs, (loff_t )blk << info->dqi_blocksize_bits); }static ssize_t write_blk (struct qtree_mem_dqinfo *info,uint blk,char *buf)
@@ -71,7 +71,7 @@ static ssize_t write_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf)ssize_t ret; ret = sb->s_op->quota_write (sb, info->dqi_type, buf, - info->dqi_usable_bs, blk << info->dqi_blocksize_bits); + info->dqi_usable_bs, (loff_t )blk << info->dqi_blocksize_bits);if (ret != info->dqi_usable_bs) {quota_error (sb,"dquota write failed" );if (ret >=0 )
@@ -284,7 +284,7 @@ static uint find_free_dqentry(struct qtree_mem_dqinfo *info, blk); goto out_buf; } - dquot->dq_off = (blk << info->dqi_blocksize_bits) + + dquot->dq_off = ((loff_t )blk << info->dqi_blocksize_bits) +sizeof (struct qt_disk_dqdbheader ) + i * info->dqi_entry_size;kfree (buf);
@@ -559,7 +559,7 @@ static loff_t find_block_dqentry(struct qtree_mem_dqinfo *info, ret = -EIO ; goto out_buf; }else { - ret = (blk << info->dqi_blocksize_bits) +sizeof (struct + ret = ((loff_t )blk << info->dqi_blocksize_bits) +sizeof (struct qt_disk_dqdbheader ) + i * info->dqi_entry_size; } out_buf:
fs/reiserfs/stree.c +6 -0
@@ -454,6 +454,12 @@ static int is_leaf(char *buf, int blocksize, struct buffer_head *bh) "(second one): %h", ih);return 0 ; } +if (is_direntry_le_ih (ih) && (ih_item_len (ih) < (ih_entry_count (ih) *IH_SIZE ))) { +reiserfs_warning (NULL ,"reiserfs-5093" , +"item entry count seems wrong %h" , + ih); +return 0 ; + } prev_location =ih_location (ih); }
include/linux/mm.h +3 -2
@@ -2439,8 +2439,9 @@ extern int __meminit __early_pfn_to_nid(unsigned long pfn,#endif extern void set_dma_reserve (unsigned long new_dma_reserve); -extern void memmap_init_zone (unsigned long ,int ,unsigned long ,unsigned long , -enum meminit_context ,struct vmem_altmap *,int migratetype); +extern void memmap_init_zone (unsigned long ,int ,unsigned long , +unsigned long ,unsigned long ,enum meminit_context , +struct vmem_altmap *,int migratetype);extern void setup_per_zone_wmarks (void );extern int __meminit init_per_zone_wmark_min (void );extern void mem_init (void );
include/uapi/linux/const.h +5 -0
@@ -28,4 +28,9 @@#define _BITUL (x) (_UL(1) << (x))#define _BITULL (x) (_ULL(1) << (x)) +#define __ALIGN_KERNEL (x, a) __ALIGN_KERNEL_MASK(x, (typeof(x))(a) - 1) +#define __ALIGN_KERNEL_MASK (x, mask) (((x) + (mask)) & ~(mask)) + +#define __KERNEL_DIV_ROUND_UP (n, d) (((n) + (d) - 1) / (d)) +#endif /* _UAPI_LINUX_CONST_H */
include/uapi/linux/ethtool.h +1 -1
@@ -14,7 +14,7 @@#ifndef _UAPI_LINUX_ETHTOOL_H#define _UAPI_LINUX_ETHTOOL_H -#include <linux/kernel.h> +#include <linux/const.h> #include <linux/types.h> #include <linux/if_ether.h>
include/uapi/linux/kernel.h +1 -8
@@ -3,13 +3,6 @@#define _UAPI_LINUX_KERNEL_H#include <linux/sysinfo.h> - -/* -* 'kernel.h' contains some often-used function prototypes etc -*/ -#define __ALIGN_KERNEL (x, a) __ALIGN_KERNEL_MASK(x, (typeof(x))(a) - 1) -#define __ALIGN_KERNEL_MASK (x, mask) (((x) + (mask)) & ~(mask)) - -#define __KERNEL_DIV_ROUND_UP (n, d) (((n) + (d) - 1) / (d)) +#include <linux/const.h> #endif /* _UAPI_LINUX_KERNEL_H */
include/uapi/linux/lightnvm.h +1 -1
@@ -21,7 +21,7 @@#define _UAPI_LINUX_LIGHTNVM_H#ifdef __KERNEL__ -#include <linux/kernel.h> +#include <linux/const.h> #include <linux/ioctl.h> #else /* __KERNEL__ */ #include <stdio.h>
include/uapi/linux/mroute6.h +1 -1
@@ -2,7 +2,7 @@#ifndef _UAPI__LINUX_MROUTE6_H#define _UAPI__LINUX_MROUTE6_H -#include <linux/kernel.h> +#include <linux/const.h> #include <linux/types.h> #include <linux/sockios.h> #include <linux/in6.h> /* For struct sockaddr_in6. */
include/uapi/linux/netfilter/x_tables.h +1 -1
@@ -1,7 +1,7 @@/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef _UAPI_X_TABLES_H#define _UAPI_X_TABLES_H -#include <linux/kernel.h> +#include <linux/const.h> #include <linux/types.h> #define XT_FUNCTION_MAXNAMELEN 30
include/uapi/linux/netlink.h +1 -1
@@ -2,7 +2,7 @@#ifndef _UAPI__LINUX_NETLINK_H#define _UAPI__LINUX_NETLINK_H -#include <linux/kernel.h> +#include <linux/const.h> #include <linux/socket.h> /* for __kernel_sa_family_t */ #include <linux/types.h>
include/uapi/linux/sysctl.h +1 -1
@@ -23,7 +23,7 @@#ifndef _UAPI_LINUX_SYSCTL_H#define _UAPI_LINUX_SYSCTL_H -#include <linux/kernel.h> +#include <linux/const.h> #include <linux/types.h> #include <linux/compiler.h>
kernel/cgroup/cgroup-v1.c +2 -0
@@ -908,6 +908,8 @@ int cgroup1_parse_param(struct fs_context *fc, struct fs_parameter *param) opt =fs_parse (fc, cgroup1_fs_parameters, param, &result);if (opt == -ENOPARAM ) {if (strcmp (param->key,"source" ) ==0 ) { +if (fc->source) +return invalf (fc,"Multiple sources not supported" ); fc->source = param->string; param->string =NULL ;return 0 ;
kernel/module.c +4 -2
@@ -1895,7 +1895,6 @@ static int mod_sysfs_init(struct module *mod)if (err)mod_kobject_put (mod); -/* delay uevent until full sysfs population */ out:return err; }
@@ -1932,7 +1931,6 @@ static int mod_sysfs_setup(struct module *mod,add_sect_attrs (mod, info);add_notes_attrs (mod, info); -kobject_uevent (&mod->mkobj.kobj,KOBJ_ADD );return 0 ; out_unreg_modinfo_attrs:
@@ -3639,6 +3637,9 @@ static noinline int do_init_module(struct module *mod)blocking_notifier_call_chain (&module_notify_list,MODULE_STATE_LIVE , mod); +/* Delay uevent until module has finished its init routine */ +kobject_uevent (&mod->mkobj.kobj,KOBJ_ADD ); +/* * We need to finish all async code before the module init sequence * is done. This has potential to deadlock. For example, a newly
@@ -3991,6 +3992,7 @@ static int load_module(struct load_info *info, const char __user *uargs, MODULE_STATE_GOING, mod);klp_module_going (mod); bug_cleanup: + mod->state =MODULE_STATE_GOING ;/* module_bug_cleanup needs module_mutex protection */ mutex_lock (&module_mutex);module_bug_cleanup (mod);
kernel/time/tick-sched.c +0 -7
@@ -941,13 +941,6 @@ static bool can_stop_idle_tick(int cpu, struct tick_sched *ts)*/ if (tick_do_timer_cpu == cpu)return false; -/* -* Boot safety: make sure the timekeeping duty has been -* assigned before entering dyntick-idle mode, -* tick_do_timer_cpu is TICK_DO_TIMER_BOOT -*/ -if (unlikely (tick_do_timer_cpu ==TICK_DO_TIMER_BOOT )) -return false;/* Should not happen for nohz-full */ if (WARN_ON_ONCE (tick_do_timer_cpu ==TICK_DO_TIMER_NONE ))
lib/zlib_dfltcc/Makefile +1 -1
@@ -8,4 +8,4 @@ obj-$(CONFIG_ZLIB_DFLTCC) += zlib_dfltcc.o -zlib_dfltcc-objs := dfltcc.o dfltcc_deflate.o dfltcc_inflate.o dfltcc_syms.o +zlib_dfltcc-objs := dfltcc.o dfltcc_deflate.o dfltcc_inflate.o
lib/zlib_dfltcc/dfltcc.c +5 -1
@@ -1,7 +1,8 @@// SPDX-License-Identifier: Zlib /* dfltcc.c - SystemZ DEFLATE CONVERSION CALL support. */ -#include <linux/zutil.h> +#include <linux/export.h> +#include <linux/module.h> #include "dfltcc_util.h" #include "dfltcc.h"
@@ -53,3 +54,6 @@ void dfltcc_reset( dfltcc_state->dht_threshold =DFLTCC_DHT_MIN_SAMPLE_SIZE ; dfltcc_state->param.ribm =DFLTCC_RIBM ; } +EXPORT_SYMBOL (dfltcc_reset); + +MODULE_LICENSE ("GPL" );
lib/zlib_dfltcc/dfltcc_deflate.c +3 -0
@@ -4,6 +4,7 @@#include "dfltcc_util.h" #include "dfltcc.h" #include <asm/setup.h> +#include <linux/export.h> #include <linux/zutil.h> /*
@@ -34,6 +35,7 @@ int dfltcc_can_deflate(return 1 ; } +EXPORT_SYMBOL (dfltcc_can_deflate);static void dfltcc_gdht ( z_streamp strm
@@ -277,3 +279,4 @@ int dfltcc_deflate( goto again;/* deflate() must use all input or all output */ return 1 ; } +EXPORT_SYMBOL (dfltcc_deflate);
lib/zlib_dfltcc/dfltcc_inflate.c +2 -2
@@ -125,7 +125,7 @@ dfltcc_inflate_action dfltcc_inflate( param->ho = (state->write - state->whave) & ((1 <<HB_BITS ) -1 );if (param->hl) param->nt =0 ;/* Honor history for the first block */ - param->cv = state->flags ?REVERSE (state->check) : state->check; + param->cv = state->check;/* Inflate */ do {
@@ -138,7 +138,7 @@ dfltcc_inflate_action dfltcc_inflate( state->bits = param->sbb; state->whave = param->hl; state->write = (param->ho + param->hl) & ((1 <<HB_BITS ) -1 ); - state->check = state->flags ?REVERSE (param->cv) : param->cv; + state->check = param->cv;if (cc ==DFLTCC_CC_OP2_CORRUPT && param->oesc !=0 ) {/* Report an error if stream is corrupted */ state->mode =BAD ;
lib/zlib_dfltcc/dfltcc_syms.c deleted +0 -17
@@ -1,17 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0-only -/* -* linux/lib/zlib_dfltcc/dfltcc_syms.c -* -* Exported symbols for the s390 zlib dfltcc support. -* -*/ - -#include <linux/init.h> -#include <linux/module.h> -#include <linux/zlib.h> -#include "dfltcc.h" - -EXPORT_SYMBOL (dfltcc_can_deflate); -EXPORT_SYMBOL (dfltcc_deflate); -EXPORT_SYMBOL (dfltcc_reset); -MODULE_LICENSE ("GPL" );
mm/hugetlb.c +21 -1
@@ -4106,10 +4106,30 @@ static vm_fault_t hugetlb_cow(struct mm_struct *mm, struct vm_area_struct *vma,* may get SIGKILLed if it later faults. */ if (outside_reserve) { +struct address_space *mapping = vma->vm_file->f_mapping; +pgoff_t idx; +u32 hash; +put_page (old_page);BUG_ON (huge_pte_none (pte)); +/* +* Drop hugetlb_fault_mutex and i_mmap_rwsem before +* unmapping. unmapping needs to hold i_mmap_rwsem +* in write mode. Dropping i_mmap_rwsem in read mode +* here is OK as COW mappings do not interact with +* PMD sharing. +* +* Reacquire both after unmap operation. +*/ + idx =vma_hugecache_offset (h, vma, haddr); + hash =hugetlb_fault_mutex_hash (mapping, idx); +mutex_unlock (&hugetlb_fault_mutex_table[hash]); +i_mmap_unlock_read (mapping); +unmap_ref_private (mm, vma, old_page, haddr); -BUG_ON (huge_pte_none (pte)); + +i_mmap_lock_read (mapping); +mutex_lock (&hugetlb_fault_mutex_table[hash]);spin_lock (ptl); ptep =huge_pte_offset (mm, haddr,huge_page_size (h)); if (likely(ptep &&
mm/memory_hotplug.c +1 -1
@@ -714,7 +714,7 @@ void __ref move_pfn_range_to_zone(struct zone *zone, unsigned long start_pfn,* expects the zone spans the pfn range. All the pages in the range * are reserved so nobody should be touching them so we should be safe */ -memmap_init_zone (nr_pages, nid,zone_idx (zone), start_pfn, +memmap_init_zone (nr_pages, nid,zone_idx (zone), start_pfn,0 ,MEMINIT_HOTPLUG , altmap, migratetype);set_zone_contiguous (zone);
mm/page_alloc.c +5 -3
@@ -448,6 +448,8 @@ defer_init(int nid, unsigned long pfn, unsigned long end_pfn)if (end_pfn <pgdat_end_pfn (NODE_DATA (nid)))return false; +if (NODE_DATA (nid)->first_deferred_pfn !=ULONG_MAX ) +return true;/* * We start only with one section of pages, more pages are added as * needed until the rest of deferred pages are initialized.
@@ -6050,7 +6052,7 @@ overlap_memmap_init(unsigned long zone, unsigned long *pfn)* zone stats (e.g., nr_isolate_pageblock) are touched. */ void __meminit memmap_init_zone (unsigned long size,int nid,unsigned long zone, -unsigned long start_pfn, +unsigned long start_pfn,unsigned long zone_end_pfn,enum meminit_context context,struct vmem_altmap *altmap,int migratetype) {
@@ -6086,7 +6088,7 @@ void __meminit memmap_init_zone(unsigned long size, int nid, unsigned long zone,if (context ==MEMINIT_EARLY ) {if (overlap_memmap_init (zone, &pfn))continue ; -if (defer_init (nid, pfn, end_pfn)) +if (defer_init (nid, pfn, zone_end_pfn))break ; }
@@ -6200,7 +6202,7 @@ void __meminit __weak memmap_init(unsigned long size, int nid,if (end_pfn > start_pfn) { size = end_pfn - start_pfn; -memmap_init_zone (size, nid, zone, start_pfn, +memmap_init_zone (size, nid, zone, start_pfn, range_end_pfn,MEMINIT_EARLY ,NULL ,MIGRATE_MOVABLE ); } }
net/ethtool/channels.c +4 -2
@@ -194,8 +194,9 @@ int ethnl_set_channels(struct sk_buff *skb, struct genl_info *info)if (netif_is_rxfh_configured (dev) && !ethtool_get_max_rxfh_channel (dev, &max_rx_in_use) && (channels.combined_count + channels.rx_count) <= max_rx_in_use) { + ret = -EINVAL ;GENL_SET_ERR_MSG (info,"requested channel counts are too low for existing indirection table settings" ); -return -EINVAL ; + goto out_ops; }/* Disabling channels, query zero-copy AF_XDP sockets */
@@ -203,8 +204,9 @@ int ethnl_set_channels(struct sk_buff *skb, struct genl_info *info)min (channels.rx_count, channels.tx_count);for (i = from_channel; i < old_total; i++)if (xsk_get_pool_from_qid (dev, i)) { + ret = -EINVAL ;GENL_SET_ERR_MSG (info,"requested channel counts are too low for existing zerocopy AF_XDP sockets" ); -return -EINVAL ; + goto out_ops; } ret = dev->ethtool_ops->set_channels (dev, &channels);
net/ethtool/strset.c +1 -1
@@ -182,7 +182,7 @@ static int strset_parse_request(struct ethnl_req_info *req_base, ret =strset_get_id (attr, &id, extack);if (ret <0 )return ret; -if (ret >=ETH_SS_COUNT ) { +if (id >=ETH_SS_COUNT ) {NL_SET_ERR_MSG_ATTR (extack, attr,"unknown string set id" );return -EOPNOTSUPP ;
net/mptcp/protocol.c +2 -0
@@ -2081,6 +2081,8 @@ struct sock *mptcp_sk_clone(const struct sock *sk,sock_reset_flag (nsk,SOCK_RCU_FREE );/* will be fully established after successful MPC subflow creation */ inet_sk_state_store (nsk,TCP_SYN_RECV ); + +security_inet_csk_clone (nsk, req);bh_unlock_sock (nsk);/* keep a single reference */
net/sched/sch_taprio.c +16 -1
@@ -1596,6 +1596,21 @@ static int taprio_change(struct Qdisc *sch, struct nlattr *opt,return err; } +static void taprio_reset (struct Qdisc *sch) +{ +struct taprio_sched *q =qdisc_priv (sch); +struct net_device *dev =qdisc_dev (sch); +int i; + +hrtimer_cancel (&q->advance_timer); +if (q->qdiscs) { +for (i =0 ; i < dev->num_tx_queues && q->qdiscs[i]; i++) +qdisc_reset (q->qdiscs[i]); + } + sch->qstats.backlog =0 ; + sch->q.qlen =0 ; +} +static void taprio_destroy (struct Qdisc *sch) {struct taprio_sched *q =qdisc_priv (sch);
@@ -1606,7 +1621,6 @@ static void taprio_destroy(struct Qdisc *sch)list_del (&q->taprio_list);spin_unlock (&taprio_list_lock); -hrtimer_cancel (&q->advance_timer);taprio_disable_offload (dev, q,NULL );
@@ -1953,6 +1967,7 @@ static struct Qdisc_ops taprio_qdisc_ops __read_mostly = { .init = taprio_init, .change = taprio_change, .destroy = taprio_destroy, + .reset = taprio_reset, .peek = taprio_peek, .dequeue = taprio_dequeue, .enqueue = taprio_enqueue,
sound/core/pcm_native.c +7 -2
@@ -755,8 +755,13 @@ static int snd_pcm_hw_params(struct snd_pcm_substream *substream, runtime->boundary *=2 ;/* clear the buffer for avoiding possible kernel info leaks */ -if (runtime->dma_area && !substream->ops->copy_user) -memset (runtime->dma_area,0 , runtime->dma_bytes); +if (runtime->dma_area && !substream->ops->copy_user) { +size_t size = runtime->dma_bytes; + +if (runtime->info &SNDRV_PCM_INFO_MMAP ) + size =PAGE_ALIGN (size); +memset (runtime->dma_area,0 , size); + }snd_pcm_timer_resolution_change (substream);snd_pcm_set_state (substream,SNDRV_PCM_STATE_SETUP );
sound/core/rawmidi.c +35 -14
117 lines not on this page · raw message
sound/core/seq/seq_queue.h +4 -4
@@ -26,10 +26,10 @@ struct snd_seq_queue {struct snd_seq_timer *timer;/* time keeper for this queue */ int owner;/* client that 'owns' the timer */ - unsigned int locked:1, /* timer is only accesibble by owner if set */ - klocked:1, /* kernel lock (after START) */ - check_again:1, - check_blocked:1; +bool locked;/* timer is only accesibble by owner if set */ +bool klocked;/* kernel lock (after START) */ +bool check_again;/* concurrent access happened during check */ +bool check_blocked;/* queue being checked */ unsigned int flags;/* status flags */ unsigned int info_flags;/* info for sync */
tools/include/uapi/linux/const.h +5 -0
@@ -28,4 +28,9 @@#define _BITUL (x) (_UL(1) << (x))#define _BITULL (x) (_ULL(1) << (x)) +#define __ALIGN_KERNEL (x, a) __ALIGN_KERNEL_MASK(x, (typeof(x))(a) - 1) +#define __ALIGN_KERNEL_MASK (x, mask) (((x) + (mask)) & ~(mask)) + +#define __KERNEL_DIV_ROUND_UP (n, d) (((n) + (d) - 1) / (d)) +#endif /* _UAPI_LINUX_CONST_H */