Re: [PATCH] sched,psi: fix the 'int' underflow for psi

2021-04-15 Thread Charan Teja Kalla
Thanks Johannes!! On 4/15/2021 8:12 PM, Johannes Weiner wrote: > Makes sense, it's more graceful in the event of a bug. > > But what motivates this change? Is it something you hit recently with > an upstream kernel and we should investigate? We specifically didn't hit the issue around this

[PATCH 4.14 39/68] net/ncsi: Make local function ncsi_get_filter() static

2021-04-15 Thread Greg Kroah-Hartman
From: Wei Yongjun commit 5a6d80034471d4407052c4bf3758071df5cadf33 upstream. Fixes the following sparse warnings: net/ncsi/ncsi-manage.c:41:5: warning: symbol 'ncsi_get_filter' was not declared. Should it be static? Signed-off-by: Wei Yongjun Signed-off-by: David S. Miller Cc: Guenter Roeck

[PATCH 4.14 00/68] 4.14.231-rc1 review

2021-04-15 Thread Greg Kroah-Hartman
This is the start of the stable review cycle for the 4.14.231 release. There are 68 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know. Responses should be made by Sat, 17 Apr 2021 14:44:01 +. Anything

[PATCH 4.14 40/68] net/ncsi: Improve general state logging

2021-04-15 Thread Greg Kroah-Hartman
From: Samuel Mendoza-Jonas commit 9ef8690be13d8ae3130749fbcc0cc21e4e3f738c upstream. The NCSI driver is mostly silent which becomes a headache when trying to determine what has occurred on the NCSI connection. This adds additional logging in a few key areas such as state transitions and calling

[PATCH 4.14 37/68] RDMA/cxgb4: check for ipv6 address properly while destroying listener

2021-04-15 Thread Greg Kroah-Hartman
From: Potnuri Bharat Teja [ Upstream commit 603c4690b01aaffe3a6c3605a429f6dac39852ae ] ipv6 bit is wrongly set by the below which causes fatal adapter lookup engine errors for ipv4 connections while destroying a listener. Fix it to properly check the local address for ipv6. Fixes:

[PATCH 4.14 09/68] ia64: fix user_stack_pointer() for ptrace()

2021-04-15 Thread Greg Kroah-Hartman
From: Sergei Trofimovich commit 7ad1e366167837daeb93d0bacb57dee820b0b898 upstream. ia64 has two stacks: - memory stack (or stack), pointed at by by r12 - register backing store (register stack), pointed at by ar.bsp/ar.bspstore with complications around dirty register frame on CPU.

[PATCH 4.14 38/68] clk: socfpga: fix iomem pointer cast on 64-bit

2021-04-15 Thread Greg Kroah-Hartman
From: Krzysztof Kozlowski commit 2867b9746cef78745c594894aece6f8ef826e0b4 upstream. Pointers should be cast with uintptr_t instead of integer. This fixes warning when compile testing on ARM64: drivers/clk/socfpga/clk-gate.c: In function ‘socfpga_clk_recalc_rate’:

[PATCH 4.14 08/68] net: ipv6: check for validity before dereferencing cfg->fc_nlinfo.nlh

2021-04-15 Thread Greg Kroah-Hartman
From: Muhammad Usama Anjum commit 864db232dc7036aa2de19749c3d5be0143b24f8f upstream. nlh is being checked for validtity two times when it is dereferenced in this function. Check for validity again when updating the flags through nlh pointer to make the dereferencing safe. CC:

[PATCH 4.14 05/68] nfc: fix memory leak in llcp_sock_connect()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit 7574fcdbdcb335763b6b322f6928dc0fd5730451 upstream. In llcp_sock_connect(), use kmemdup to allocate memory for "llcp_sock->service_name". The memory is not released in the sock_unlink label of the subsequent failure branch. As a result, memory leakage occurs. fix

[PATCH 4.14 28/68] ARM: dts: imx6: pbab01: Set vmmc supply for both SD interfaces

2021-04-15 Thread Greg Kroah-Hartman
From: Stefan Riedmueller [ Upstream commit f57011e72f5fe0421ec7a812beb1b57bdf4bb47f ] Setting the vmmc supplies is crucial since otherwise the supplying regulators get disabled and the SD interfaces are no longer powered which leads to system failures if the system is booted from that SD

[PATCH 4.14 24/68] amd-xgbe: Update DMA coherency values

2021-04-15 Thread Greg Kroah-Hartman
From: Shyam Sundar S K [ Upstream commit d75135082698140a26a56defe1bbc1b06f26a41f ] Based on the IOMMU configuration, the current cache control settings can result in possible coherency issues. The hardware team has recommended new settings for the PCI device path to eliminate the issue.

[PATCH 4.14 07/68] xen/evtchn: Change irq_info lock to raw_spinlock_t

2021-04-15 Thread Greg Kroah-Hartman
From: Luca Fancellu commit d120198bd5ff1d41808b6914e1eb89aff937415c upstream. Unmask operation must be called with interrupt disabled, on preempt_rt spin_lock_irqsave/spin_unlock_irqrestore don't disable/enable interrupts, so use raw_* implementation and change lock variable in struct irq_info

[PATCH 4.14 26/68] gianfar: Handle error code at MAC address change

2021-04-15 Thread Greg Kroah-Hartman
From: Claudiu Manoil [ Upstream commit bff5b62585123823842833ab20b1c0a7fa437f8c ] Handle return error code of eth_mac_addr(); Fixes: 3d23a05c75c7 ("gianfar: Enable changing mac addr when if up") Signed-off-by: Claudiu Manoil Signed-off-by: David S. Miller Signed-off-by: Sasha Levin ---

[PATCH 4.14 04/68] nfc: fix refcount leak in llcp_sock_connect()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit 8a4cd82d62b5ec7e5482333a72b58a4eea4979f0 upstream. nfc_llcp_local_get() is invoked in llcp_sock_connect(), but nfc_llcp_local_put() is not invoked in subsequent failure branches. As a result, refcount leakage occurs. To fix it, add calling nfc_llcp_local_put(). fix

[PATCH 4.14 06/68] nfc: Avoid endless loops caused by repeated llcp_sock_connect()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit 4b5db93e7f2afbdfe3b78e37879a85290187e6f1 upstream. When sock_wait_state() returns -EINPROGRESS, "sk->sk_state" is LLCP_CONNECTING. In this case, llcp_sock_connect() is repeatedly invoked, nfc_llcp_sock_link() will add sk to local->connecting_sockets twice.

[PATCH 4.14 03/68] nfc: fix refcount leak in llcp_sock_bind()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit c33b1cc62ac05c1dbb1cdafe2eb66da01c76ca8d upstream. nfc_llcp_local_get() is invoked in llcp_sock_bind(), but nfc_llcp_local_put() is not invoked in subsequent failure branches. As a result, refcount leakage occurs. To fix it, add calling nfc_llcp_local_put(). fix

[PATCH 4.14 25/68] sch_red: fix off-by-one checks in red_check_params()

2021-04-15 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 3a87571f0ffc51ba3bf3ecdb6032861d0154b164 ] This fixes following syzbot report: UBSAN: shift-out-of-bounds in ./include/net/red.h:237:23 shift exponent 32 is too large for 32-bit type 'unsigned int' CPU: 1 PID: 8418 Comm: syz-executor170 Not tainted

[PATCH 4.14 22/68] regulator: bd9571mwv: Fix AVS and DVFS voltage range

2021-04-15 Thread Greg Kroah-Hartman
From: Geert Uytterhoeven [ Upstream commit 3b6e7088afc919f5b52e4d2de8501ad34d35b09b ] According to Table 30 ("DVFS_MoniVDAC [6:0] Setting Table") in the BD9571MWV-M Datasheet Rev. 002, the valid voltage range is 600..1100 mV (settings 0x3c..0x6e). While the lower limit is taken into account

[PATCH 4.14 23/68] ASoC: wm8960: Fix wrong bclk and lrclk with pll enabled for some chips

2021-04-15 Thread Greg Kroah-Hartman
From: Shengjiu Wang [ Upstream commit 16b82e75c15a7dbd564ea3654f3feb61df9e1e6f ] The input MCLK is 12.288MHz, the desired output sysclk is 11.2896MHz and sample rate is 44100Hz, with the configuration pllprescale=2, postscale=sysclkdiv=1, some chip may have wrong bclk and lrclk output with pll

[PATCH 4.14 21/68] i2c: turn recovery error on init to debug

2021-04-15 Thread Greg Kroah-Hartman
From: Wolfram Sang commit e409a6a3e0690efdef9b8a96197bc61ff117cfaf upstream. In some configurations, recovery is optional. So, don't throw an error when it is not used because e.g. pinctrl settings for recovery are not provided. Reword the message and make it debug output. Reported-by: Klaus

Re: [PATCH v3 12/27] perf parse-events: Support no alias assigned event inside hybrid PMU

2021-04-15 Thread Jin, Yao
Hi Jiri, On 4/15/2021 10:11 PM, Jiri Olsa wrote: On Thu, Apr 15, 2021 at 09:36:16PM +0800, Jin, Yao wrote: SNIP + int n = 0; + + list_for_each(pos, list) + n++; + + return n; +} + +static int parse_events__with_hybrid_pmu(struct parse_events_state

[PATCH 4.14 20/68] usbip: synchronize event handler with sysfs code paths

2021-04-15 Thread Greg Kroah-Hartman
From: Shuah Khan commit 363eaa3a450abb4e63bd6e3ad79d1f7a0f717814 upstream. Fuzzing uncovered race condition between sysfs code paths in usbip drivers. Device connect/disconnect code paths initiated through sysfs interface are prone to races if disconnect happens during connect and vice versa.

[PATCH 4.14 18/68] usbip: add sysfs_lock to synchronize sysfs code paths

2021-04-15 Thread Greg Kroah-Hartman
From: Shuah Khan commit 4e9c93af7279b059faf5bb1897ee90512b258a12 upstream. Fuzzing uncovered race condition between sysfs code paths in usbip drivers. Device connect/disconnect code paths initiated through sysfs interface are prone to races if disconnect happens during connect and vice versa.

[PATCH 4.14 02/68] ASoC: intel: atom: Stop advertising non working S24LE support

2021-04-15 Thread Greg Kroah-Hartman
From: Hans de Goede commit aa65bacdb70e549a81de03ec72338e1047842883 upstream. The SST firmware's media and deep-buffer inputs are hardcoded to S16LE, the corresponding DAIs don't have a hw_params callback and their prepare callback also does not take the format into account. So far the

[PATCH 4.14 19/68] usbip: stub-dev synchronize sysfs code paths

2021-04-15 Thread Greg Kroah-Hartman
From: Shuah Khan commit 9dbf34a834563dada91366c2ac266f32ff34641a upstream. Fuzzing uncovered race condition between sysfs code paths in usbip drivers. Device connect/disconnect code paths initiated through sysfs interface are prone to races if disconnect happens during connect and vice versa.

[PATCH 4.14 17/68] net: sched: sch_teql: fix null-pointer dereference

2021-04-15 Thread Greg Kroah-Hartman
From: Pavel Tikhomirov commit 1ffbc7ea91606e4abd10eb60de5367f1c86daf5e upstream. Reproduce: modprobe sch_teql tc qdisc add dev teql0 root teql0 This leads to (for instance in Centos 7 VM) OOPS: [ 532.366633] BUG: unable to handle kernel NULL pointer dereference at 00a8 [

[PATCH 4.14 15/68] batman-adv: initialize "struct batadv_tvlv_tt_vlan_data"->reserved field

2021-04-15 Thread Greg Kroah-Hartman
From: Tetsuo Handa commit 08c27f3322fec11950b8f1384aa0f3b11d028528 upstream. KMSAN found uninitialized value at batadv_tt_prepare_tvlv_local_data() [1], for commit ced72933a5e8ab52 ("batman-adv: use CRC32C instead of CRC16 in TT code") inserted 'reserved' field into "struct batadv_tvlv_tt_data"

[PATCH 4.14 16/68] net: ensure mac header is set in virtio_net_hdr_to_skb()

2021-04-15 Thread Greg Kroah-Hartman
From: Eric Dumazet commit 61431a5907fc36d0738e9a547c7e1556349a03e9 upstream. Commit 924a9bc362a5 ("net: check if protocol extracted by virtio_net_hdr_set_proto is correct") added a call to dev_parse_header_protocol() but mac_header is not yet set. This means that eth_hdr() reads complete

Re: [PATCH 11/11] mm/page_alloc: Embed per_cpu_pages locking within the per-cpu structure

2021-04-15 Thread Vlastimil Babka
On 4/14/21 3:39 PM, Mel Gorman wrote: > struct per_cpu_pages is protected by the pagesets lock but it can be > embedded within struct per_cpu_pages at a minor cost. This is possible > because per-cpu lookups are based on offsets. Paraphrasing an explanation > from Peter Ziljstra > > The whole

[PATCH 4.14 14/68] ARM: dts: turris-omnia: configure LED[2]/INTn pin as interrupt pin

2021-04-15 Thread Greg Kroah-Hartman
From: Marek Behún commit a26c56ae67fa9fbb45a8a232dcd7ebaa7af16086 upstream. Use the `marvell,reg-init` DT property to configure the LED[2]/INTn pin of the Marvell 88E1514 ethernet PHY on Turris Omnia into interrupt mode. Without this the pin is by default in LED[2] mode, and the Marvell PHY

[PATCH 4.14 13/68] parisc: avoid a warning on u8 cast for cmpxchg on u8 pointers

2021-04-15 Thread Greg Kroah-Hartman
From: Gao Xiang commit 4d752e5af63753ab5140fc282929b98eaa4bd12e upstream. commit b344d6a83d01 ("parisc: add support for cmpxchg on u8 pointers") can generate a sparse warning ("cast truncates bits from constant value"), which has been reported several times [1] [2] [3]. The original code

[PATCH 4.14 12/68] parisc: parisc-agp requires SBA IOMMU driver

2021-04-15 Thread Greg Kroah-Hartman
From: Helge Deller commit 9054284e8846b0105aad43a4e7174ca29fffbc44 upstream. Add a dependency to the SBA IOMMU driver to avoid: ERROR: modpost: "sba_list" [drivers/char/agp/parisc-agp.ko] undefined! Reported-by: kernel test robot Cc: sta...@vger.kernel.org Signed-off-by: Helge Deller

[PATCH 4.14 10/68] ocfs2: fix deadlock between setattr and dio_end_io_write

2021-04-15 Thread Greg Kroah-Hartman
From: Wengang Wang commit 90bd070aae6c4fb5d302f9c4b9c88be60c8197ec upstream. The following deadlock is detected: truncate -> setattr path is waiting for pending direct IO to be done (inode->i_dio_count become zero) with inode->i_rwsem held (down_write). PID: 14827 TASK: 881686a9af80

[PATCH 4.14 11/68] fs: direct-io: fix missing sdio->boundary

2021-04-15 Thread Greg Kroah-Hartman
From: Jack Qiu commit df41872b68601059dd4a84858952dcae58acd331 upstream. I encountered a hung task issue, but not a performance one. I run DIO on a device (need lba continuous, for example open channel ssd), maybe hungtask in below case: DIO:

[PATCH 4.14 01/68] ALSA: aloop: Fix initialization of controls

2021-04-15 Thread Greg Kroah-Hartman
From: Jonas Holmberg commit 168632a495f49f33a18c2d502fc249d7610375e9 upstream. Add a control to the card before copying the id so that the numid field is initialized in the copy. Otherwise the numid field of active_id, format_id, rate_id and channels_id will be the same (0) and snd_ctl_notify()

[PATCH 4.9 27/47] mm: add cond_resched() in gather_pte_stats()

2021-04-15 Thread Greg Kroah-Hartman
From: Hugh Dickins commit a66c0410b97c07a5708881198528ce724f7a3226 upstream. The other pagetable walks in task_mmu.c have a cond_resched() after walking their ptes: add a cond_resched() in gather_pte_stats() too, for reading /proc//numa_maps. Only pagemap_pmd_range() has a cond_resched() in

[PATCH 4.9 36/47] net: ieee802154: fix nl802154 del llsec dev

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 3d1eac2f45585690d942cf47fd7fbd04093ebd1b upstream. This patch fixes a nullpointer dereference if NL802154_ATTR_SEC_DEVICE is not set by the user. If this is the case nl802154 will return -EINVAL. Reported-by: syzbot+d946223c2e751d136...@syzkaller.appspotmail.com

[PATCH 4.9 35/47] net: ieee802154: fix nl802154 del llsec key

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 37feaaf5ceb2245e474369312bb7b922ce7bce69 upstream. This patch fixes a nullpointer dereference if NL802154_ATTR_SEC_KEY is not set by the user. If this is the case nl802154 will return -EINVAL. Reported-by: syzbot+ac5c11d2959a8b3c4...@syzkaller.appspotmail.com

[PATCH 4.9 32/47] drivers: net: fix memory leak in peak_usb_create_dev

2021-04-15 Thread Greg Kroah-Hartman
From: Pavel Skripkin commit a0b96b4a62745397aee662670cfc2157bac03f55 upstream. syzbot reported memory leak in peak_usb. The problem was in case of failure after calling ->dev_init()[2] in peak_usb_create_dev()[1]. The data allocated int dev_init() wasn't freed, so simple ->dev_free() call fix

[PATCH 4.9 34/47] net: ieee802154: nl-mac: fix check on panid

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 6f7f657f24405f426212c09260bf7fe8a52cef33 upstream. This patch fixes a null pointer derefence for panid handle by move the check for the netlink variable directly before accessing them. Reported-by: syzbot+d4c07de0144f6f63b...@syzkaller.appspotmail.com

[PATCH 4.9 33/47] net: mac802154: Fix general protection fault

2021-04-15 Thread Greg Kroah-Hartman
From: Pavel Skripkin commit 1165affd484889d4986cf3b724318935a0b120d8 upstream. syzbot found general protection fault in crypto_destroy_tfm()[1]. It was caused by wrong clean up loop in llsec_key_alloc(). If one of the tfm array members is in IS_ERR() range it will cause general protection fault

[PATCH 4.9 31/47] drivers: net: fix memory leak in atusb_probe

2021-04-15 Thread Greg Kroah-Hartman
From: Pavel Skripkin commit 6b9fbe16955152626557ec6f439f3407b7769941 upstream. syzbot reported memory leak in atusb_probe()[1]. The problem was in atusb_alloc_urbs(). Since urb is anchored, we need to release the reference to correctly free the urb backtrace: [] kmalloc

[PATCH 4.9 37/47] net: ieee802154: fix nl802154 add llsec key

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 20d5fe2d7103f5c43ad11a3d6d259e9d61165c35 upstream. This patch fixes a nullpointer dereference if NL802154_ATTR_SEC_KEY is not set by the user. If this is the case nl802154 will return -EINVAL. Reported-by: syzbot+ce4e062c2d51977dd...@syzkaller.appspotmail.com

[PATCH 4.9 28/47] usbip: fix vudc usbip_sockfd_store races leading to gpf

2021-04-15 Thread Greg Kroah-Hartman
From: Shuah Khan commit 46613c9dfa964c0c60b5385dbdf5aaa18be52a9c upstream. usbip_sockfd_store() is invoked when user requests attach (import) detach (unimport) usb gadget device from usbip host. vhci_hcd sends import request and usbip_sockfd_store() exports the device if it is free for export.

[PATCH 4.9 09/47] xen/evtchn: Change irq_info lock to raw_spinlock_t

2021-04-15 Thread Greg Kroah-Hartman
From: Luca Fancellu commit d120198bd5ff1d41808b6914e1eb89aff937415c upstream. Unmask operation must be called with interrupt disabled, on preempt_rt spin_lock_irqsave/spin_unlock_irqrestore don't disable/enable interrupts, so use raw_* implementation and change lock variable in struct irq_info

[PATCH 4.9 00/47] 4.9.267-rc1 review

2021-04-15 Thread Greg Kroah-Hartman
This is the start of the stable review cycle for the 4.9.267 release. There are 47 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know. Responses should be made by Sat, 17 Apr 2021 14:44:01 +. Anything

[PATCH 4.9 08/47] nfc: Avoid endless loops caused by repeated llcp_sock_connect()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit 4b5db93e7f2afbdfe3b78e37879a85290187e6f1 upstream. When sock_wait_state() returns -EINPROGRESS, "sk->sk_state" is LLCP_CONNECTING. In this case, llcp_sock_connect() is repeatedly invoked, nfc_llcp_sock_link() will add sk to local->connecting_sockets twice.

[PATCH 4.9 29/47] cfg80211: remove WARN_ON() in cfg80211_sme_connect

2021-04-15 Thread Greg Kroah-Hartman
From: Du Cheng commit 1b5ab825d9acc0f27d2f25c6252f3526832a9626 upstream. A WARN_ON(wdev->conn) would trigger in cfg80211_sme_connect(), if multiple send_msg(NL80211_CMD_CONNECT) system calls are made from the userland, which should be anticipated and handled by the wireless driver. Remove this

[PATCH 4.9 30/47] net: tun: set tun->dev->addr_len during TUNSETLINK processing

2021-04-15 Thread Greg Kroah-Hartman
From: Phillip Potter commit cca8ea3b05c972ffb5295367e6c544369b45fbdd upstream. When changing type with TUNSETLINK ioctl command, set tun->dev->addr_len to match the appropriate type, using new tun_get_addr_len utility function which returns appropriate address length for given type. Fixes a

Re: [PATCH] cifs: remove unnecessary copies of tcon->crfid.fid

2021-04-15 Thread Muhammad Usama Anjum
On Wed, 2021-04-14 at 14:00 +0200, Aurélien Aptel wrote: > Muhammad Usama Anjum writes: > > pfid is being set to tcon->crfid.fid and they are copied in each other > > multiple times. Remove the memcopy between same pointers. > > > > Addresses-Coverity: ("Overlapped copy") > > Fixes: 9e81e8ff74b9

[PATCH 4.9 47/47] xen/events: fix setting irq affinity

2021-04-15 Thread Greg Kroah-Hartman
From: Juergen Gross The backport of upstream patch 25da4618af240fbec61 ("xen/events: don't unmask an event channel when an eoi is pending") introduced a regression for stable kernels 5.10 and older: setting IRQ affinity for IRQs related to interdomain events would no longer work, as moving the

[PATCH 4.9 46/47] perf map: Tighten snprintf() string precision to pass gcc check on some 32-bit arches

2021-04-15 Thread Greg Kroah-Hartman
From: Arnaldo Carvalho de Melo commit 77d02bd00cea9f1a87afe58113fa75b983d6c23a upstream. Noticed on a debian:experimental mips and mipsel cross build build environment: perfbuilder@ec265a086e9b:~$ mips-linux-gnu-gcc --version | head -1 mips-linux-gnu-gcc (Debian 10.2.1-3) 10.2.1 20201224

[PATCH 4.9 45/47] netfilter: x_tables: fix compat match/target pad out-of-bound write

2021-04-15 Thread Greg Kroah-Hartman
From: Florian Westphal commit b29c457a6511435960115c0f548c4360d5f4801d upstream. xt_compat_match/target_from_user doesn't check that zeroing the area to start of next rule won't write past end of allocated ruleset blob. Remove this code and zero the entire blob beforehand. Reported-by:

[PATCH 4.9 44/47] gfs2: report "already frozen/thawed" errors

2021-04-15 Thread Greg Kroah-Hartman
From: Bob Peterson [ Upstream commit ff132c5f93c06bd4432bbab5c369e468653bdec4 ] Before this patch, gfs2's freeze function failed to report an error when the target file system was already frozen as it should (and as generic vfs function freeze_super does. Similarly, gfs2's thaw function failed

[PATCH 4.9 42/47] Revert "cifs: Set CIFS_MOUNT_USE_PREFIX_PATH flag on setting cifs_sb->prepath."

2021-04-15 Thread Greg Kroah-Hartman
From: Greg Kroah-Hartman This reverts commit 742300e32db00f008e944acafaeba9a12730eff0 which is commit a738c93fb1c17e386a09304b517b1c6b2a6a5a8b upstream. It is reported to cause problems in older kernels, so revert it for now until we can figure it out... Reported-by: Salvatore Bonaccorso

[PATCH 4.9 43/47] drm/imx: imx-ldb: fix out of bounds array access warning

2021-04-15 Thread Greg Kroah-Hartman
From: Arnd Bergmann [ Upstream commit 33ce7f2f95cabb5834cf0906308a5cb6103976da ] When CONFIG_OF is disabled, building with 'make W=1' produces warnings about out of bounds array access: drivers/gpu/drm/imx/imx-ldb.c: In function 'imx_ldb_set_clock.constprop':

[PATCH 4.9 41/47] net: ieee802154: stop dump llsec params for monitors

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 1534efc7bbc1121e92c86c2dabebaf2c9dcece19 upstream. This patch stops dumping llsec params for monitors which we don't support yet. Otherwise we will access llsec mib which isn't initialized for monitors. Reported-by:

Re: [PATCH v3 1/2] perf/core: Share an event with multiple cgroups

2021-04-15 Thread Peter Zijlstra
On Tue, Apr 13, 2021 at 08:53:36AM -0700, Namhyung Kim wrote: > As we can run many jobs (in container) on a big machine, we want to > measure each job's performance during the run. To do that, the > perf_event can be associated to a cgroup to measure it only. > > However such cgroup events need

[PATCH 4.9 40/47] net: ieee802154: forbid monitor for del llsec seclevel

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 9dde130937e95b72adfae64ab21d6e7e707e2dac upstream. This patch forbids to del llsec seclevel for monitor interfaces which we don't support yet. Otherwise we will access llsec mib which isn't initialized for monitors. Reported-by:

[PATCH 4.9 39/47] net: ieee802154: forbid monitor for set llsec params

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 88c17855ac4291fb462e13a86b7516773b6c932e upstream. This patch forbids to set llsec params for monitor interfaces which we don't support yet. Reported-by: syzbot+8b6719da8a04beeaf...@syzkaller.appspotmail.com Signed-off-by: Alexander Aring Link:

[PATCH 4.9 38/47] net: ieee802154: fix nl802154 del llsec devkey

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 27c746869e1a135dffc2f2a80715bb7aa00445b4 upstream. This patch fixes a nullpointer dereference if NL802154_ATTR_SEC_DEVKEY is not set by the user. If this is the case nl802154 will return -EINVAL. Reported-by: syzbot+368672e0da240db53...@syzkaller.appspotmail.com

[PATCH 4.9 07/47] nfc: fix memory leak in llcp_sock_connect()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit 7574fcdbdcb335763b6b322f6928dc0fd5730451 upstream. In llcp_sock_connect(), use kmemdup to allocate memory for "llcp_sock->service_name". The memory is not released in the sock_unlink label of the subsequent failure branch. As a result, memory leakage occurs. fix

[PATCH 4.9 06/47] nfc: fix refcount leak in llcp_sock_connect()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit 8a4cd82d62b5ec7e5482333a72b58a4eea4979f0 upstream. nfc_llcp_local_get() is invoked in llcp_sock_connect(), but nfc_llcp_local_put() is not invoked in subsequent failure branches. As a result, refcount leakage occurs. To fix it, add calling nfc_llcp_local_put(). fix

[PATCH 4.9 04/47] ASoC: intel: atom: Stop advertising non working S24LE support

2021-04-15 Thread Greg Kroah-Hartman
From: Hans de Goede commit aa65bacdb70e549a81de03ec72338e1047842883 upstream. The SST firmware's media and deep-buffer inputs are hardcoded to S16LE, the corresponding DAIs don't have a hw_params callback and their prepare callback also does not take the format into account. So far the

[PATCH 4.9 05/47] nfc: fix refcount leak in llcp_sock_bind()

2021-04-15 Thread Greg Kroah-Hartman
From: Xiaoming Ni commit c33b1cc62ac05c1dbb1cdafe2eb66da01c76ca8d upstream. nfc_llcp_local_get() is invoked in llcp_sock_bind(), but nfc_llcp_local_put() is not invoked in subsequent failure branches. As a result, refcount leakage occurs. To fix it, add calling nfc_llcp_local_put(). fix

[PATCH 4.9 03/47] ALSA: aloop: Fix initialization of controls

2021-04-15 Thread Greg Kroah-Hartman
From: Jonas Holmberg commit 168632a495f49f33a18c2d502fc249d7610375e9 upstream. Add a control to the card before copying the id so that the numid field is initialized in the copy. Otherwise the numid field of active_id, format_id, rate_id and channels_id will be the same (0) and snd_ctl_notify()

[PATCH 4.9 26/47] clk: socfpga: fix iomem pointer cast on 64-bit

2021-04-15 Thread Greg Kroah-Hartman
From: Krzysztof Kozlowski commit 2867b9746cef78745c594894aece6f8ef826e0b4 upstream. Pointers should be cast with uintptr_t instead of integer. This fixes warning when compile testing on ARM64: drivers/clk/socfpga/clk-gate.c: In function ‘socfpga_clk_recalc_rate’:

[PATCH 4.9 25/47] RDMA/cxgb4: check for ipv6 address properly while destroying listener

2021-04-15 Thread Greg Kroah-Hartman
From: Potnuri Bharat Teja [ Upstream commit 603c4690b01aaffe3a6c3605a429f6dac39852ae ] ipv6 bit is wrongly set by the below which causes fatal adapter lookup engine errors for ipv4 connections while destroying a listener. Fix it to properly check the local address for ipv6. Fixes:

[PATCH 4.9 24/47] s390/cpcmd: fix inline assembly register clobbering

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Gordeev [ Upstream commit 7a2f91441b2c1d81b77c1cd816a4659f4abc9cbe ] Register variables initialized using arithmetic. That leads to kasan instrumentaton code corrupting the registers contents. Follow GCC guidlines and use temporary variables for assigning init values to register

[PATCH 4.9 23/47] workqueue: Move the position of debug_work_activate() in __queue_work()

2021-04-15 Thread Greg Kroah-Hartman
From: Zqiang [ Upstream commit 0687c66b5f666b5ad433f4e94251590d9bc9d10e ] The debug_work_activate() is called on the premise that the work can be inserted, because if wq be in WQ_DRAINING status, insert work may be failed. Fixes: e41e704bc4f4 ("workqueue: improve destroy_workqueue()

[PATCH 4.9 22/47] clk: fix invalid usage of list cursor in unregister

2021-04-15 Thread Greg Kroah-Hartman
From: Lukasz Bartosik [ Upstream commit 7045465500e465b09f09d6e5bdc260a9f1aab97b ] Fix invalid usage of a list_for_each_entry cursor in clk_notifier_unregister(). When list is empty or if the list is completely traversed (without breaking from the loop on one of the entries) then the list

[PATCH 4.9 21/47] soc/fsl: qbman: fix conflicting alignment attributes

2021-04-15 Thread Greg Kroah-Hartman
From: Arnd Bergmann [ Upstream commit 040f31196e8b2609613f399793b9225271b79471 ] When building with W=1, gcc points out that the __packed attribute on struct qm_eqcr_entry conflicts with the 8-byte alignment attribute on struct qm_fd inside it: drivers/soc/fsl/qbman/qman.c:189:1: error:

[PATCH 4.9 20/47] net:tipc: Fix a double free in tipc_sk_mcast_rcv

2021-04-15 Thread Greg Kroah-Hartman
From: Lv Yunlong [ Upstream commit 6bf24dc0cc0cc43b29ba344b66d78590e687e046 ] In the if(skb_peek(arrvq) == skb) branch, it calls __skb_dequeue(arrvq) to get the skb by skb = skb_peek(arrvq). Then __skb_dequeue() unlinks the skb from arrvq and returns the skb which equals to skb_peek(arrvq).

[PATCH 4.9 02/47] iio: hid-sensor-prox: Fix scale not correct issue

2021-04-15 Thread Greg Kroah-Hartman
From: Ye Xiang commit d68c592e02f6f49a88e705f13dfc1883432cf300 upstream Currently, the proxy sensor scale is zero because it just return the exponent directly. To fix this issue, this patch use hid_sensor_format_scale to process the scale first then return the output. Fixes: 39a3a0138f61

[PATCH 4.9 19/47] gianfar: Handle error code at MAC address change

2021-04-15 Thread Greg Kroah-Hartman
From: Claudiu Manoil [ Upstream commit bff5b62585123823842833ab20b1c0a7fa437f8c ] Handle return error code of eth_mac_addr(); Fixes: 3d23a05c75c7 ("gianfar: Enable changing mac addr when if up") Signed-off-by: Claudiu Manoil Signed-off-by: David S. Miller Signed-off-by: Sasha Levin ---

[PATCH 4.9 17/47] net: sched: sch_teql: fix null-pointer dereference

2021-04-15 Thread Greg Kroah-Hartman
From: Pavel Tikhomirov commit 1ffbc7ea91606e4abd10eb60de5367f1c86daf5e upstream. Reproduce: modprobe sch_teql tc qdisc add dev teql0 root teql0 This leads to (for instance in Centos 7 VM) OOPS: [ 532.366633] BUG: unable to handle kernel NULL pointer dereference at 00a8 [

[PATCH 4.9 18/47] sch_red: fix off-by-one checks in red_check_params()

2021-04-15 Thread Greg Kroah-Hartman
From: Eric Dumazet [ Upstream commit 3a87571f0ffc51ba3bf3ecdb6032861d0154b164 ] This fixes following syzbot report: UBSAN: shift-out-of-bounds in ./include/net/red.h:237:23 shift exponent 32 is too large for 32-bit type 'unsigned int' CPU: 1 PID: 8418 Comm: syz-executor170 Not tainted

[PATCH 4.9 16/47] batman-adv: initialize "struct batadv_tvlv_tt_vlan_data"->reserved field

2021-04-15 Thread Greg Kroah-Hartman
From: Tetsuo Handa commit 08c27f3322fec11950b8f1384aa0f3b11d028528 upstream. KMSAN found uninitialized value at batadv_tt_prepare_tvlv_local_data() [1], for commit ced72933a5e8ab52 ("batman-adv: use CRC32C instead of CRC16 in TT code") inserted 'reserved' field into "struct batadv_tvlv_tt_data"

[PATCH 4.9 15/47] parisc: avoid a warning on u8 cast for cmpxchg on u8 pointers

2021-04-15 Thread Greg Kroah-Hartman
From: Gao Xiang commit 4d752e5af63753ab5140fc282929b98eaa4bd12e upstream. commit b344d6a83d01 ("parisc: add support for cmpxchg on u8 pointers") can generate a sparse warning ("cast truncates bits from constant value"), which has been reported several times [1] [2] [3]. The original code

[PATCH 4.9 14/47] parisc: parisc-agp requires SBA IOMMU driver

2021-04-15 Thread Greg Kroah-Hartman
From: Helge Deller commit 9054284e8846b0105aad43a4e7174ca29fffbc44 upstream. Add a dependency to the SBA IOMMU driver to avoid: ERROR: modpost: "sba_list" [drivers/char/agp/parisc-agp.ko] undefined! Reported-by: kernel test robot Cc: sta...@vger.kernel.org Signed-off-by: Helge Deller

[PATCH 4.9 13/47] fs: direct-io: fix missing sdio->boundary

2021-04-15 Thread Greg Kroah-Hartman
From: Jack Qiu commit df41872b68601059dd4a84858952dcae58acd331 upstream. I encountered a hung task issue, but not a performance one. I run DIO on a device (need lba continuous, for example open channel ssd), maybe hungtask in below case: DIO:

[PATCH 4.9 12/47] ocfs2: fix deadlock between setattr and dio_end_io_write

2021-04-15 Thread Greg Kroah-Hartman
From: Wengang Wang commit 90bd070aae6c4fb5d302f9c4b9c88be60c8197ec upstream. The following deadlock is detected: truncate -> setattr path is waiting for pending direct IO to be done (inode->i_dio_count become zero) with inode->i_rwsem held (down_write). PID: 14827 TASK: 881686a9af80

[PATCH 4.9 10/47] net: ipv6: check for validity before dereferencing cfg->fc_nlinfo.nlh

2021-04-15 Thread Greg Kroah-Hartman
From: Muhammad Usama Anjum commit 864db232dc7036aa2de19749c3d5be0143b24f8f upstream. nlh is being checked for validtity two times when it is dereferenced in this function. Check for validity again when updating the flags through nlh pointer to make the dereferencing safe. CC:

[PATCH 4.9 11/47] ia64: fix user_stack_pointer() for ptrace()

2021-04-15 Thread Greg Kroah-Hartman
From: Sergei Trofimovich commit 7ad1e366167837daeb93d0bacb57dee820b0b898 upstream. ia64 has two stacks: - memory stack (or stack), pointed at by by r12 - register backing store (register stack), pointed at by ar.bsp/ar.bspstore with complications around dirty register frame on CPU.

[PATCH 4.9 01/47] ARM: 8723/2: always assume the "unified" syntax for assembly code

2021-04-15 Thread Greg Kroah-Hartman
From: Nicolas Pitre commit 75fea300d73ae5b18957949a53ec770daaeb6fc2 upstream. The GNU assembler has implemented the "unified syntax" parsing since 2005. This "unified" syntax is required when the kernel is built in Thumb2 mode. However the "unified" syntax is a mixed bag of features, including

[PATCH 4.4 27/38] net: ieee802154: nl-mac: fix check on panid

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 6f7f657f24405f426212c09260bf7fe8a52cef33 upstream. This patch fixes a null pointer derefence for panid handle by move the check for the netlink variable directly before accessing them. Reported-by: syzbot+d4c07de0144f6f63b...@syzkaller.appspotmail.com

[PATCH 4.4 35/38] drm/imx: imx-ldb: fix out of bounds array access warning

2021-04-15 Thread Greg Kroah-Hartman
From: Arnd Bergmann [ Upstream commit 33ce7f2f95cabb5834cf0906308a5cb6103976da ] When CONFIG_OF is disabled, building with 'make W=1' produces warnings about out of bounds array access: drivers/gpu/drm/imx/imx-ldb.c: In function 'imx_ldb_set_clock.constprop':

[PATCH 4.4 34/38] net: ieee802154: stop dump llsec params for monitors

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 1534efc7bbc1121e92c86c2dabebaf2c9dcece19 upstream. This patch stops dumping llsec params for monitors which we don't support yet. Otherwise we will access llsec mib which isn't initialized for monitors. Reported-by:

[PATCH 4.4 36/38] netfilter: x_tables: fix compat match/target pad out-of-bound write

2021-04-15 Thread Greg Kroah-Hartman
From: Florian Westphal commit b29c457a6511435960115c0f548c4360d5f4801d upstream. xt_compat_match/target_from_user doesn't check that zeroing the area to start of next rule won't write past end of allocated ruleset blob. Remove this code and zero the entire blob beforehand. Reported-by:

[PATCH 4.4 33/38] net: ieee802154: forbid monitor for del llsec seclevel

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 9dde130937e95b72adfae64ab21d6e7e707e2dac upstream. This patch forbids to del llsec seclevel for monitor interfaces which we don't support yet. Otherwise we will access llsec mib which isn't initialized for monitors. Reported-by:

[PATCH v3 3/4] dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers

2021-04-15 Thread Aswath Govindraju
Add binding documentation for TI TCAN104x CAN transceivers. Signed-off-by: Aswath Govindraju --- .../bindings/phy/ti,tcan104x-can.yaml | 56 +++ MAINTAINERS | 1 + 2 files changed, 57 insertions(+) create mode 100644

[PATCH v3 4/4] phy: phy-can-transceiver: Add support for generic CAN transceiver driver

2021-04-15 Thread Aswath Govindraju
The driver adds support for generic CAN transceivers. Currently the modes supported by this driver are standby and normal modes for TI TCAN1042 and TCAN1043 CAN transceivers. The transceiver is modelled as a phy with pins controlled by gpios, to put the transceiver in various device functional

[PATCH 4.4 32/38] net: ieee802154: forbid monitor for set llsec params

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 88c17855ac4291fb462e13a86b7516773b6c932e upstream. This patch forbids to set llsec params for monitor interfaces which we don't support yet. Reported-by: syzbot+8b6719da8a04beeaf...@syzkaller.appspotmail.com Signed-off-by: Alexander Aring Link:

[PATCH v3 2/4] phy: Add API for devm_of_phy_optional_get_by_index

2021-04-15 Thread Aswath Govindraju
Add API for devm_of_phy_optional_get_by_index, to obtain a reference to an optional phy by index. Signed-off-by: Aswath Govindraju --- drivers/phy/phy-core.c | 26 ++ include/linux/phy/phy.h | 2 ++ 2 files changed, 28 insertions(+) diff --git a/drivers/phy/phy-core.c

[PATCH 4.4 31/38] net: ieee802154: fix nl802154 del llsec devkey

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 27c746869e1a135dffc2f2a80715bb7aa00445b4 upstream. This patch fixes a nullpointer dereference if NL802154_ATTR_SEC_DEVKEY is not set by the user. If this is the case nl802154 will return -EINVAL. Reported-by: syzbot+368672e0da240db53...@syzkaller.appspotmail.com

[PATCH 4.4 29/38] net: ieee802154: fix nl802154 del llsec dev

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 3d1eac2f45585690d942cf47fd7fbd04093ebd1b upstream. This patch fixes a nullpointer dereference if NL802154_ATTR_SEC_DEVICE is not set by the user. If this is the case nl802154 will return -EINVAL. Reported-by: syzbot+d946223c2e751d136...@syzkaller.appspotmail.com

[PATCH v3 0/4] CAN TRANSCEIVER: Add support for CAN transceivers

2021-04-15 Thread Aswath Govindraju
The following series of patches add support for CAN transceivers. TCAN1042 has a standby signal that needs to be pulled high for sending/receiving messages[1]. TCAN1043 has a enable signal along with standby signal that needs to be pulled up for sending/receiving messages[2], and other

[PATCH 4.4 30/38] net: ieee802154: fix nl802154 add llsec key

2021-04-15 Thread Greg Kroah-Hartman
From: Alexander Aring commit 20d5fe2d7103f5c43ad11a3d6d259e9d61165c35 upstream. This patch fixes a nullpointer dereference if NL802154_ATTR_SEC_KEY is not set by the user. If this is the case nl802154 will return -EINVAL. Reported-by: syzbot+ce4e062c2d51977dd...@syzkaller.appspotmail.com

[PATCH v3 1/4] phy: core: Reword the comment specifying the units of max_link_rate to be Mbps

2021-04-15 Thread Aswath Govindraju
In some subsystems (eg. CAN, SPI), the max link rate supported can be less than 1 Mbps and if the unit for max_link_rate is Mbps then it can't be used. Therefore, leave the decision of units to be used, to the producer and consumer. Signed-off-by: Aswath Govindraju --- include/linux/phy/phy.h |

[PATCH 4.4 38/38] xen/events: fix setting irq affinity

2021-04-15 Thread Greg Kroah-Hartman
From: Juergen Gross The backport of upstream patch 25da4618af240fbec61 ("xen/events: don't unmask an event channel when an eoi is pending") introduced a regression for stable kernels 5.10 and older: setting IRQ affinity for IRQs related to interdomain events would no longer work, as moving the

<    4   5   6   7   8   9   10   11   12   13   >