Re: [PATCH 2/5] KEYS: user_defined: sanitize key payloads

2017-04-21 Thread David Howells
Eric Biggers wrote: > - kfree_rcu(zap, rcu); > + call_rcu(&zap->rcu, user_free_payload_rcu); Add kzfree_rcu()? David

Re: [PATCH] ceph: Fix file open flags on ppc64

2017-04-21 Thread Alexander Graf
On 21.04.17 15:46, Jeff Layton wrote: On Thu, 2017-04-20 at 14:40 +0200, Alexander Graf wrote: The file open flags (O_foo) are platform specific and should never go out to an interface that is not local to the system. Unfortunately these flags have leaked out onto the wire in the cephfs imple

Re: [PATCH] ceph: Fix file open flags on ppc64

2017-04-21 Thread Alexander Graf
On 21.04.17 04:22, Yan, Zheng wrote: On 20 Apr 2017, at 20:40, Alexander Graf wrote: The file open flags (O_foo) are platform specific and should never go out to an interface that is not local to the system. Unfortunately these flags have leaked out onto the wire in the cephfs implementati

Re: [PATCH 3/6] ima: Simplify policy_func_show.

2017-04-21 Thread Mimi Zohar
On Thu, 2017-04-20 at 17:40 -0300, Thiago Jung Bauermann wrote: > Am Donnerstag, 20. April 2017, 08:13:23 BRT schrieb Mimi Zohar: > > On Tue, 2017-04-18 at 17:17 -0300, Thiago Jung Bauermann wrote: > > > If the func_tokens array uses the same indices as enum ima_hooks, > > > policy_func_show can be

Re: [PATCH v6] Allow user probes on versioned symbols

2017-04-21 Thread Masami Hiramatsu
On Thu, 13 Apr 2017 12:03:13 -0500 Paul Clarke wrote: > Symbol versioning, as in glibc, results in symbols being defined as: > @[@] > (Note that "@@" identifies a default symbol, if the symbol name > is repeated.) > > perf is currently unable to deal with this, and is unable to create > user pro

[PATCH, 3.18-stable regression] ARM: psci: fix header file

2017-04-21 Thread Arnd Bergmann
Commit be95485a0b828 was incorrectly backported to 3.18 and now causes a different build error when CONFIG_SMP is disabled: arch/arm/kernel/psci.c:287:12: error: redefinition of 'psci_init' This version is how it should be on 3.18, with the main psci code built for both SMP and UP, but the psci_

[PATCH] MAINTAINERS: update file entry for HSI subsystem

2017-04-21 Thread Tobias Klauser
The HSI documentation was moved into Documentation/driver-api/hsi.rst in commit 5e995786850e ("docs: split up serial-interfaces.rst"). Update the corresponding file entry in MAINTAINERS. Signed-off-by: Tobias Klauser --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --g

[PATCH 1/2] nohz: Fix again collision between tick and other hrtimers

2017-04-21 Thread Frederic Weisbecker
(This restores commit 24b91e360ef521a2808771633d76ebc68bd5604b that got reverted by commit 558e8e27e73f53f8a512485be538b07115fe5f3c due to a regression where CPUs spuriously stopped ticking. The issue happened when a tick fired too early past its expected expiration: on IRQ exit the tick was schedu

[PATCH 2/2] tick: Make sure tick timer is active when bypassing reprogramming

2017-04-21 Thread Frederic Weisbecker
So far we have run into too much troubles with the optimization path that skips reprogramming the clock on IRQ exit when the expiration deadline hasn't changed. If by accident the cached deadline happens to be out of sync with the hardware deadline, the buggy result and its cause are hard to invest

[PATCH 0/2] nohz: Deal with clock reprogram skipping issues v2

2017-04-21 Thread Frederic Weisbecker
As suggested by Thomas Gleixner, the second patch now integrates a fix in case the sanity check fails and the clockevent isn't programmed as expected. Frederic Weisbecker (2): nohz: Fix again collision between tick and other hrtimers tick: Make sure tick timer is active when bypassing reprogra

Re: [PATCH 0/5] v2: block subsystem refcounter conversions

2017-04-21 Thread Jens Axboe
On 04/21/2017 04:55 AM, Reshetova, Elena wrote: Please don't send any more conversions until those have been resolved. >> >> Like I suggested months ago, how about doing an efficient implementation of >> refcount_t which doesn't use the bloated cmpxchg loop? Then there would be >> no >> need

[RFC PATCH 07/14] cgroup: Move debug cgroup to its own file

2017-04-21 Thread Waiman Long
The debug cgroup currently resides within cgroup-v1.c and is enabled only for v1 cgroup. To enable the debug cgroup also for v2, it makes sense to put the code into its own file as it will no longer be v1 specific. The only change in this patch is the expansion of cgroup_task_count() within the deb

[RFC PATCH 08/14] cgroup: Keep accurate count of tasks in each css_set

2017-04-21 Thread Waiman Long
The reference count in the css_set data structure was used as a proxy of the number of tasks attached to that css_set. However, that count is actually not an accurate measure especially with thread mode support. So a new variable task_count is added to the css_set to keep track of the actual task c

[RFC PATCH 10/14] cgroup: Implement new thread mode semantics

2017-04-21 Thread Waiman Long
The current thread mode semantics aren't sufficient to fully support threaded controllers like cpu. The main problem is that when thread mode is enabled at root (mainly for performance reason), all the non-threaded controllers cannot be supported at all. To alleviate this problem, the roles of thr

[RFC PATCH 02/14] cgroup: add @flags to css_task_iter_start() and implement CSS_TASK_ITER_PROCS

2017-04-21 Thread Waiman Long
From: Tejun Heo css_task_iter currently always walks all tasks. With the scheduled cgroup v2 thread support, the iterator would need to handle multiple types of iteration. As a preparation, add @flags to css_task_iter_start() and implement CSS_TASK_ITER_PROCS. If the flag is not specified, it

[RFC PATCH 13/14] sched: Make cpu/cpuacct threaded controllers

2017-04-21 Thread Waiman Long
Make cpu and cpuacct cgroup controllers usable within a threaded cgroup. Signed-off-by: Waiman Long --- kernel/sched/core.c| 1 + kernel/sched/cpuacct.c | 1 + 2 files changed, 2 insertions(+) diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 78dfcaa..9d8beda 100644 --- a/kernel/

[RFC PATCH 12/14] sched: Implement interface for cgroup unified hierarchy

2017-04-21 Thread Waiman Long
From: Tejun Heo While the cpu controller doesn't have any functional problems, there are a couple interface issues which can be addressed in the v2 interface. * cpuacct being a separate controller. This separation is artificial and rather pointless as demonstrated by most use cases co-mountin

[RFC PATCH 14/14] cgroup: Enable separate control knobs for thread root internal processes

2017-04-21 Thread Waiman Long
Internal processes are allowed in a thread root of the cgroup v2 default hierarchy. For those resource domain controllers that don't want to deal with resource competition between internal processes and child cgroups, there is now the option of specifying the sep_res_domain flag in their cgroup_sub

[RFC PATCH 11/14] sched: Misc preps for cgroup unified hierarchy interface

2017-04-21 Thread Waiman Long
From: Tejun Heo Make the following changes in preparation for the cpu controller interface implementation for the unified hierarchy. This patch doesn't cause any functional differences. * s/cpu_stats_show()/cpu_cfs_stats_show()/ * s/cpu_files/cpu_legacy_files/ * Separate out cpuacct_stats_rea

[RFC PATCH 09/14] cgroup: Make debug cgroup support v2 and thread mode

2017-04-21 Thread Waiman Long
Besides supporting cgroup v2 and thread mode, the following changes are also made: 1) current_* cgroup files now resides only at the root as we don't need duplicated files of the same function all over the cgroup hierarchy. 2) The cgroup_css_links_read() function is modified to report

[RFC PATCH 06/14] cgroup: Fix reference counting bug in cgroup_procs_write()

2017-04-21 Thread Waiman Long
The cgroup_procs_write_start() took a reference to the task structure which was not properly released within cgroup_procs_write() and so on. So a put_task_struct() call is added to cgroup_procs_write_finish() to match the get_task_struct() in cgroup_procs_write_start() to fix this reference countin

re: mtip32xx: add a status field to struct mtip_cmd

2017-04-21 Thread Colin Ian King
Hi, CoverityScan found an issue with the following part of the patch: - if (likely(!reserv)) - blk_mq_complete_request(rq, -ENODEV); - else if (test_bit(MTIP_PF_IC_ACTIVE_BIT, &dd->port->flags)) { + if (likely(!reserv)) { + cmd->status = -ENODEV; +

Linux 4.11: Reported regressions as of Friday, 2017-04-21

2017-04-21 Thread Thorsten Leemhuis
Hi! Find below my fourth regression report for Linux 4.11. It lists 10 regressions I'm currently aware of. 7 regressions mentioned in last weeks report got fixed. As always: Are you aware of any other regressions? Then please let me know (simply CC regressi...@leemhuis.info). And please tell me if

[RFC PATCH 05/14] cgroup: implement cgroup v2 thread support

2017-04-21 Thread Waiman Long
From: Tejun Heo This patch implements cgroup v2 thread support. The goal of the thread mode is supporting hierarchical accounting and control at thread granularity while staying inside the resource domain model which allows coordination across different resource controllers and handling of anony

[RFC PATCH 00/14] cgroup: Implement cgroup v2 thread mode & CPU controller

2017-04-21 Thread Waiman Long
This patchset incorporates the following 2 patchsets from Tejun Heo: 1) cgroup v2 thread mode patchset (5 patches) https://lkml.org/lkml/2017/2/2/592 2) CPU Controller on Control Group v2 (2 patches) https://lkml.org/lkml/2016/8/5/368 Additional patches are then layered on top to implem

[RFC PATCH 04/14] cgroup: implement CSS_TASK_ITER_THREADED

2017-04-21 Thread Waiman Long
From: Tejun Heo cgroup v2 is in the process of growing thread granularity support. Once thread mode is enabled, the root cgroup of the subtree serves as the proc_cgrp to which the processes of the subtree conceptually belong and domain-level resource consumptions not tied to any specific task are

[RFC PATCH 03/14] cgroup: introduce cgroup->proc_cgrp and threaded css_set handling

2017-04-21 Thread Waiman Long
From: Tejun Heo cgroup v2 is in the process of growing thread granularity support. Once thread mode is enabled, the root cgroup of the subtree serves as the proc_cgrp to which the processes of the subtree conceptually belong and domain-level resource consumptions not tied to any specific task are

Re: [PATCH -mm -v9 1/3] mm, THP, swap: Delay splitting THP during swap out

2017-04-21 Thread Johannes Weiner
On Fri, Apr 21, 2017 at 04:11:36PM +1000, Balbir Singh wrote: > > In the future of THP swap optimization, some information of the > > swapped out THP (such as compound map count) will be recorded in the > > swap_cluster_info data structure. > > > > The mem cgroup swap accounting functions are enha

[RFC PATCH 01/14] cgroup: reorganize cgroup.procs / task write path

2017-04-21 Thread Waiman Long
From: Tejun Heo Currently, writes "cgroup.procs" and "cgroup.tasks" files are all handled by __cgroup_procs_write() on both v1 and v2. This patch reoragnizes the write path so that there are common helper functions that different write paths use. While this somewhat increases LOC, the different

[PATCH v3 01/29] x86: boot/copy, remove unused functions

2017-04-21 Thread Jiri Slaby
copy_from_gs and copy_to_gs are unused in the boot code. They have actually never been used -- they were always commented out since their addition in 5be865661516 ("String-handling functions for the new x86 setup code.") in 2007. So remove them -- they can be restored from history if need be. Sign

[PATCH v3 03/29] x86_64: boot, extract efi_pe_entry from startup_64

2017-04-21 Thread Jiri Slaby
efi_pe_entry body is somehow squashed into startup_64. In the old days, we forced startup_64 to start at offset 0x200 and efi_pe_entry to start at 0x210. But this requirement was removed in 99f857db8857 ("x86, build: Dynamically find entry points in compressed startup code") long time ago. The way

[PATCH v3 19/29] x86: um, annotate data appropriatelly

2017-04-21 Thread Jiri Slaby
Use the new SYM_DATA_START and SYM_DATA_END_LABEL macros for vdso_start. We get: 2376 OBJECT GLOBAL DEFAULT4 vdso_start 0948 0 OBJECT GLOBAL DEFAULT4 vdso_end Signed-off-by: Jiri Slaby Cc: Jeff Dike Cc: Richard Weinberger Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Pe

[PATCH v3 27/29] x86_32: assembly, change all ENTRY to SYM_FUNC_START

2017-04-21 Thread Jiri Slaby
These are all functions which are invoked from elsewhere, so we annotate them as global using the new SYM_FUNC_START (and their ENDPROC's by SYM_FUNC_END.) Signed-off-by: Jiri Slaby Cc: "H. Peter Anvin" Cc: Thomas Gleixner Cc: Ingo Molnar Cc: x...@kernel.org Cc: Herbert Xu Cc: "David S. Mille

[PATCH v3 15/29] x86: assembly, annotate aliases

2017-04-21 Thread Jiri Slaby
_key_expansion_128 is an alias to _key_expansion_256a, __memcpy to memcpy, xen_syscall32_target to xen_sysenter_target, and so on. Annotate them all using the new SYM_FUNC_START_ALIAS, SYM_FUNC_START_LOCAL_ALIAS, and SYM_FUNC_END_ALIAS. This will make the tools generating the debuginfo happy. Sign

[PATCH v3 18/29] x86: boot, annotate data appropriatelly

2017-04-21 Thread Jiri Slaby
Use the new SYM_DATA_SIMPLE, SYM_DATA_START, and SYM_DATA_END* macros for data. Now, the data in the object file look sane: Value Size TypeBind Vis Ndx Name 10 OBJECT GLOBAL DEFAULT3 efi32_boot_gdt 000a10 OBJECT LOCAL DEFAULT3 save_gdt 0014 8 OBJECT L

[PATCH v3 28/29] x86_32: lguest, use SYM_ENTRY

2017-04-21 Thread Jiri Slaby
The last user of ENTRY is in lguest. ENTRY is going away, so switch them to SYM_ENTRY. Now, we can finally force ENTRY/ENDPROC to be undefined on X86. Signed-off-by: Jiri Slaby Cc: Rusty Russell Cc: lgu...@lists.ozlabs.org --- drivers/lguest/x86/switcher_32.S | 4 ++-- include/linux/linkage.h

[PATCH v2 2/3] rtmutex: update rt-mutex

2017-04-21 Thread Alex Shi
The rtmutex remove a pending owner bit in in rt_mutex::owner, in commit 8161239a8bcc ("rtmutex: Simplify PI algorithm and make highest prio task get lock") But the document was changed accordingly. Updating it to a meaningful state. BTW, as 'Steven Rostedt' mentioned: There is still technically a

[PATCH v2 1/3] rtmutex: update rt-mutex-design

2017-04-21 Thread Alex Shi
The rt-mutex-design documents didn't gotten meaningful update from its first version. Even after owner's pending bit was removed in commit 8161239a8bcc ("rtmutex: Simplify PI algorithm and make highest prio task get lock") and priority list 'plist' changed to rbtree. So the documents are far late o

Re: mtip32xx: add a status field to struct mtip_cmd

2017-04-21 Thread Jens Axboe
On 04/21/2017 08:06 AM, Colin Ian King wrote: > Hi, > > CoverityScan found an issue with the following part of the patch: > > - if (likely(!reserv)) > - blk_mq_complete_request(rq, -ENODEV); > - else if (test_bit(MTIP_PF_IC_ACTIVE_BIT, &dd->port->flags)) { > + if (

[PATCH v3 17/29] x86: head, annotate data appropriatelly

2017-04-21 Thread Jiri Slaby
Use the new SYM_DATA_SIMPLE and SYM_DATA_END in both 32 and 64 bit heads. In the 64-bit version, define also SYM_DATA_START_PAGE_ALIGNED locally using the new SYM_START. It is used in the code instead of NEXT_PAGE() which was defined in this file and has been using the obsolete macro GLOBAL(). Now

RE: [PATCH V8 4/5] PCI/ASPM: save power on values during bridge init

2017-04-21 Thread Patel, Mayurkumar
> >On 4/21/2017 3:46 AM, Patel, Mayurkumar wrote: >> If we want to follow above approach then shall we consider having something >> similar as following? > >Do you see this problem if you boot with pcie_aspm.policy=powersave option? > No problems. with pcie_aspm.policy=powersave(L1SS are not enab

[PATCH v2 3/3] rtmutex: remove unnecessary adjust prio

2017-04-21 Thread Alex Shi
We don't need to adjust prio before new pi_waiter adding. The prio only need update after pi_waiter change or task priority change. Signed-off-by: Alex Shi Cc: Steven Rostedt Cc: Sebastian Siewior To: linux-kernel@vger.kernel.org To: Ingo Molnar To: Peter Zijlstra Cc: Thomas Gleixner --- ke

Re: [PATCH v3] scsi/bfa: use designated initializers

2017-04-21 Thread Martin K. Petersen
Kees Cook writes: Kees, > Prepare to mark sensitive kernel structures for randomization by > making sure they're using designated initializers. This also > initializes the array members using the enum used to look up > __port_action entries. Applied to 4.12/scsi-queue. Thanks! -- Martin K. P

[PATCH v3 16/29] x86: entry, annotate interrupt symbols properly

2017-04-21 Thread Jiri Slaby
* annotate local functions properly by SYM_FUNC_START_LOCAL and SYM_FUNC_END * use SYM_FUNC_INNER_LABEL for functions being in the middle of others * mark the end of common_interrupt by SYM_FUNC_END Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: ---

Re: [tip:x86/mm] x86/mm/gup: Switch GUP to the generic get_user_page_fast() implementation

2017-04-21 Thread Kirill A. Shutemov
On Thu, Apr 20, 2017 at 02:46:51PM -0700, Dan Williams wrote: > On Sat, Mar 18, 2017 at 2:52 AM, tip-bot for Kirill A. Shutemov > wrote: > > Commit-ID: 2947ba054a4dabbd82848728d765346886050029 > > Gitweb: > > http://git.kernel.org/tip/2947ba054a4dabbd82848728d765346886050029 > > Author:

[PATCH v3 21/29] x86: purgatory, start using annotations

2017-04-21 Thread Jiri Slaby
purgatory used no annotations. So include linux/linkage.h and annotate everything: * functions by SYM_FUNC_* * data by SYM_DATA_* Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: x...@kernel.org --- arch/x86/purgatory/entry64.S | 21 -

[PATCH v3 25/29] x86: assembly, make some functions local

2017-04-21 Thread Jiri Slaby
There is couple of assembly functions, which are invoked only locally in a file they are defined. In C, we mark them "static". Annotate them here using SYM_FUNC_START_LOCAL (and switch their ENDPROC to SYM_FUNC_END too). Signed-off-by: Jiri Slaby Cc: "H. Peter Anvin" Cc: Thomas Gleixner Cc: Ing

[PATCH v3 20/29] x86: xen-pvh, annotate data appropriatelly

2017-04-21 Thread Jiri Slaby
Use the new SYM_DATA_START_LOCAL, and SYM_DATA_END* macros: 8 OBJECT LOCAL DEFAULT6 gdt 000832 OBJECT LOCAL DEFAULT6 gdt_start 0028 0 OBJECT LOCAL DEFAULT6 gdt_end 0028 256 OBJECT LOCAL DEFAULT6 early_stack 0128 0 OBJECT LOCAL DEFAULT6

[PATCH v3 22/29] x86: assembly, use SYM_FUNC_INNER_LABEL instead of GLOBAL

2017-04-21 Thread Jiri Slaby
GLOBAL had several meanings and is going away. In this patch, convert all the inner functions labels marked with GLOBAL to use SYM_FUNC_INNER_LABEL instead. Note that retint_user needs not be global, perhaps since commit 2ec67971facc ("x86/entry/64/compat: Remove most of the fast system call machi

[PATCH v3 23/29] x86: realmode, use SYM_DATA_* instead of GLOBAL

2017-04-21 Thread Jiri Slaby
GLOBAL had several meanings and is going away. In this patch, convert all the data marked using GLOBAL to use SYM_DATA_START or SYM_DATA_SIMPLE instead. Notes: * SYM_DATA_END_LABEL is used to generate tr_gdt_end too. * wakeup_idt is marked as LOCAL now as it is used only locally. Since we removed

Re: [PATCH v1] net: phy: fix auto-negotiation stall due to unavailable interrupt

2017-04-21 Thread Roger Quadros
On 20/04/17 14:00, Alexander Kochetkov wrote: > The Ethernet link on an interrupt driven PHY was not coming up if the Ethernet > cable was plugged before the Ethernet interface was brought up. > > The patch trigger PHY state machine to update link state if PHY was requested > to > do auto-negotia

[PATCH v3 24/29] x86: assembly, remove GLOBAL macro

2017-04-21 Thread Jiri Slaby
Convert the remaining 32bit users and remove GLOBAL macro finally. In particular, this means to use SYM_ENTRY for the singlestepping hack region. Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: x...@kernel.org --- arch/x86/entry/entry_32.S | 4 ++--

Re: [PATCH 1/1] fs: Allows for xattr support to be compiled out

2017-04-21 Thread kbuild test robot
Hi Brian, [auto build test WARNING on linus/master] [also build test WARNING on v4.11-rc7 next-20170421] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Brian-Ashworth/fs-Allows-for-xattr

Re: [PATCH v13 03/10] mux: minimal mux subsystem and gpio-based mux controller

2017-04-21 Thread Philipp Zabel
Hi Peter, On Thu, 2017-04-13 at 18:43 +0200, Peter Rosin wrote: [...] > +int mux_control_select(struct mux_control *mux, int state) state could be unsigned int for the consumer facing API. > +{ > + int ret; And mux_control_select should check that (0 <= state < mux->states). regards Philip

[PATCH] nfs/filelayout: fix NULL pointer dereference in fl_pnfs_update_layout()

2017-04-21 Thread Artem Savkov
Calling pnfs_put_lset on an IS_ERR pointer results in a NULL pointer dereference like the one below. fl_pnfs_update_layout()'s output is checked after each call so it doesn't seem that it should try to handle these errors on it's own. [ 3000.636161] BUG: unable to handle kernel NULL pointer derefe

[PATCH v3 26/29] x86_64: assembly, change all ENTRY to SYM_FUNC_START

2017-04-21 Thread Jiri Slaby
These are all functions which are invoked from elsewhere, so we annotate them as global using the new SYM_FUNC_START (and their ENDPROC's by SYM_FUNC_END.) And make sure ENTRY/ENDPROC is not defined on X86_64. Signed-off-by: Jiri Slaby Cc: "H. Peter Anvin" Cc: Thomas Gleixner Cc: Ingo Molnar

[PATCH v3 29/29] x86: assembly, replace WEAK uses

2017-04-21 Thread Jiri Slaby
Use the new SYM_FUNC_INNER_LABEL for WEAK entries in the middle of x86 assembly functions. And make sure WEAK is not defined for X86. Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: x...@kernel.org --- arch/x86/kernel/ftrace_32.S | 2 +- arch/x86/kernel

[PATCH v3 12/29] x86: assembly, annotate local functions

2017-04-21 Thread Jiri Slaby
Use the newly added SYM_FUNC_START_LOCAL to annotate starts of all functions which do not have ".globl" annotation. This is needed to balance SYM_FUNC_END for tools that are about to generate debuginfo. Note that some functions already had ENDPROC -- switch to the new SYM_FUNC_END too. [v3] annot

[PATCH v3 14/29] x86: boot, annotate local functions

2017-04-21 Thread Jiri Slaby
relocated and no_longmode are self-standing local functions, annotate them as such. Signed-off-by: Jiri Slaby Cc: "H. Peter Anvin" Cc: Thomas Gleixner Cc: Ingo Molnar Cc: x...@kernel.org --- arch/x86/boot/compressed/head_32.S | 3 ++- arch/x86/boot/compressed/head_64.S | 7 +-- 2 files ch

[PATCH v3 13/29] x86: crypto, annotate local functions

2017-04-21 Thread Jiri Slaby
Use the newly added SYM_FUNC_START_LOCAL to annotate starts of all functions which do not have ".globl" annotation, but their ends are annotated by ENDPROC. This is needed to balance ENDPROC for tools that are about to generate debuginfo. We also convert their ENDPROCs to the new SYM_FUNC_END. Si

[PATCH v3 07/29] x86: bpf_jit, use ENTRY+ENDPROC

2017-04-21 Thread Jiri Slaby
Do not use a custom macro FUNC for starts of the global functions, use ENTRY instead. And while at it, annotate also ends of the functions by ENDPROC. Signed-off-by: Jiri Slaby Cc: "David S. Miller" Cc: Alexey Kuznetsov Cc: James Morris Cc: Hideaki YOSHIFUJI Cc: Patrick McHardy Cc: Thomas G

[PATCH v3 09/29] x86: assembly, use DATA_SIMPLE for data

2017-04-21 Thread Jiri Slaby
This is a start of series to cleanup macros used for starting functions, data, globals etc. across x86. When we have all this sorted out, this will help to inject DWARF unwinding info by objtool later. The goal is forcing SYM_FUNC_START to emit .cfi_startproc and SYM_FUNC_END to emit .cfi_endproc.

[PATCH v3 08/29] linkage: new macros for assembler symbols

2017-04-21 Thread Jiri Slaby
Introduce new C macros for annotations of functions and data in assembly. There is a long-term mess in macros like ENTRY, END, ENDPROC and similar. They are used in different manners and sometimes incorrectly. So introduce macros with clear use to annotate assembly as follows: a) Support macros

[PATCH v3 10/29] x86: assembly, annotate relocate_kernel

2017-04-21 Thread Jiri Slaby
Annotate all functions in relocate_kernel by SYM_FUNC_START, SYM_FUNC_START_LOCAL, and SYM_FUNC_END properly. We get in return: 108 FUNCGLOBAL DEFAULT1 relocate_kernel 0070 165 FUNCLOCAL DEFAULT1 identity_mapped 012053 FUNCLOCAL DEFAULT1 virtual_mapped

[PATCH v3 04/29] x86: assembly, use ENDPROC for functions

2017-04-21 Thread Jiri Slaby
Somewhere END was used to end a function. It is not intended to be used for functions, because it does not mark the actual symbols as functions. Use ENDPROC in such cases which does the right job. Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Cc: Boris

[PATCH v3 11/29] x86: entry, annotate THUNKs

2017-04-21 Thread Jiri Slaby
Place SYM_FUNC_START and SYM_FUNC_END around the THUNK macro body, given it generates functions. Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: --- arch/x86/entry/thunk_32.S | 4 ++-- arch/x86/entry/thunk_64.S | 5 ++--- 2 files changed, 4 insertions(+

[PATCH v3 06/29] x86: assembly, annotate functions by ENTRY, not GLOBAL

2017-04-21 Thread Jiri Slaby
GLOBAL is meant for global symbols, but not functions. Use ENTRY which is dedicated for global functions: * it aligns the functions properly * it is expected to have a corresponding ENDPROC too. startup_64, which uses .globl explicitly, is converted too. Besides that, x86's custom GLOBAL macro is

Re: [PATCH v2 00/11] Documentation: Add ABI to the admin guide

2017-04-21 Thread Mauro Carvalho Chehab
Em Fri, 21 Apr 2017 08:37:45 +0200 Markus Heiser escreveu: > Am 21.04.2017 um 01:21 schrieb Mauro Carvalho Chehab > : > > > - I'm not a python programmer ;-) I just took Markus "generic" kernel-cmd > > code, hardcoding there a call to the script. > > > > With (a lot of) time, I would likely

[PATCH v3 05/29] x86: assembly, add ENDPROC to functions

2017-04-21 Thread Jiri Slaby
Some functions are annotated as ENTRY or GLOBAL, but their ends are not annotated at all. This means: * the annotations are not paired and we cannot deal with such functions e.g. in objtool * the symbols are not marked as functions in the object file * there are no sizes of the functions in the o

Re: [PATCH v13 03/10] mux: minimal mux subsystem and gpio-based mux controller

2017-04-21 Thread Philipp Zabel
On Thu, 2017-04-13 at 18:43 +0200, Peter Rosin wrote: [...] > +int mux_chip_register(struct mux_chip *mux_chip) > +{ > + int i; > + int ret; > + > + for (i = 0; i < mux_chip->controllers; ++i) { > + struct mux_control *mux = &mux_chip->mux[i]; > + > + if (mux->id

[PATCH v3 02/29] x86_32: boot, extract efi_pe_entry from startup_32

2017-04-21 Thread Jiri Slaby
efi_pe_entry body is somehow squashed into startup_32. In the old days, we forced startup_32 to start at offset 0x00 and efi_pe_entry to start at 0x10. But this requirement was removed in 99f857db8857 ("x86, build: Dynamically find entry points in compressed startup code") long time ago. The way i

Re: [PATCH v3 09/11] x86/xen: use capabilities instead of fake cpuid values for xsave

2017-04-21 Thread Boris Ostrovsky
> +static bool __init xen_check_xsave(void) > { > - unsigned int ax, bx, cx, dx; > - unsigned int xsave_mask; > + unsigned int err, eax, edx; > > - ax = 1; > - cx = 0; > - cpuid(1, &ax, &bx, &cx, &dx); > + /* Test OSXSAVE capability via xgetbv instruction. */ > +

Re: [PATCH v17 2/3] usb: USB Type-C connector class

2017-04-21 Thread Rajaram R
On Fri, Apr 21, 2017 at 1:16 AM, Badhri Jagan Sridharan wrote: > Thanks for the responses :) > > So seems like we have a plan. > > In Type-C connector class the checks for TYPEC_PWR_MODE_PD > and pd_revision for both the port and the partner will be removed in > power_role_store and the data_role_

Re: [PATCH v2 2/2] dmaengine: Add DW AXI DMAC driver

2017-04-21 Thread Eugeniy Paltsev
Hi Andy, thanks for respond. My comments are inlined below. On Tue, 2017-04-18 at 15:31 +0300, Andy Shevchenko wrote: > On Fri, 2017-04-07 at 17:04 +0300, Eugeniy Paltsev wrote: > > This patch adds support for the DW AXI DMAC controller. > > > > DW AXI DMAC is a part of upcoming development board

Re: net: heap out-of-bounds in fib6_clean_node/rt6_fill_node/fib6_age/fib6_prune_clone

2017-04-21 Thread David Ahern
On 4/20/17 10:09 AM, Andrey Konovalov wrote: > On Thu, Apr 20, 2017 at 5:39 PM, Andrey Konovalov > wrote: >> On Thu, Apr 20, 2017 at 5:35 PM, David Ahern >> wrote: >>> On 4/20/17 9:28 AM, Andrey Konovalov wrote: This one seems to be much closer to what Dmitry reported intially. >>> does no

Re: [PATCH] x86/mpx: Correctly report do_mpx_bt_fault() failures to user-space

2017-04-21 Thread Dave Hansen
On 04/21/2017 05:19 AM, Joerg Roedel wrote: > On Thu, Apr 20, 2017 at 08:45:28AM -0700, Dave Hansen wrote: >> How about doing X86_TRAP_PF? That would at least be consistent with >> SIGBUS, which is probably the closest thing to a generic error code that >> we have. > Correct me if I am wrong, but

Re: [PATCH 1/3] arm64: extend ioremap for cacheable non-shareable memory

2017-04-21 Thread Roy Pledge
These transactions are done in HW via an ACP port which if I remember correctly only supports non coherent transactions. I will need to go back and check through email conversations I had with Catalin last year when debugging an issue using this mechanism (cacheable/nonshareable mapping) but it

Re: [PATCH 3/5] KEYS: encrypted: sanitize all key material

2017-04-21 Thread David Howells
Eric Biggers wrote: > - memzero_explicit(epayload->decrypted_data, epayload->decrypted_datalen); > - kfree(key->payload.data[0]); > + kzfree(key->payload.data[0]); Should kzfree() be using memzero_explicit() rather than memset()? David

Re: [PATCH v13 03/10] mux: minimal mux subsystem and gpio-based mux controller

2017-04-21 Thread Peter Rosin
On 2017-04-21 16:23, Philipp Zabel wrote: > On Thu, 2017-04-13 at 18:43 +0200, Peter Rosin wrote: > [...] >> +int mux_chip_register(struct mux_chip *mux_chip) >> +{ >> +int i; >> +int ret; >> + >> +for (i = 0; i < mux_chip->controllers; ++i) { >> +struct mux_control *mux = &

Re: [PATCH] scsi: BusLogic: fix incorrect spelling of adatper_reset_req

2017-04-21 Thread Khalid Aziz
On 02/21/2017 09:27 AM, Colin King wrote: > From: Colin Ian King > > trivial fix to spelling mistake, adatper_reset_req should > be adapter_reset_req. Also break up very long seq_printf statement > into multiple lines. > > Signed-off-by: Colin Ian King > --- > drivers/scsi/BusLogic.c | 14 +++

Re: [PATCH] scsi: BusLogic: fix incorrect spelling of adatper_reset_req

2017-04-21 Thread Martin K. Petersen
Khalid, >> trivial fix to spelling mistake, adatper_reset_req should be >> adapter_reset_req. Also break up very long seq_printf statement into >> multiple lines. Applied to 4.12/scsi-queue. Thanks! -- Martin K. Petersen Oracle Linux Engineering

Re: mtip32xx: add a status field to struct mtip_cmd

2017-04-21 Thread Christoph Hellwig
On Fri, Apr 21, 2017 at 08:14:03AM -0600, Jens Axboe wrote: > From: Jens Axboe > Subject: [PATCH] mtip32xx: fix dereference of stack garbage > > We need to get the command payload from the request before > we attempt to dereference it. > > Fixes: 4dda4735c581 ("mtip32xx: add a status field to st

Re: [PATCH 2/3] bus: fsl-mc: dpio: enable qbman CENA portal memory access

2017-04-21 Thread Catalin Marinas
On Thu, Apr 20, 2017 at 03:34:17PM -0400, Haiying Wang wrote: > Once we enable the cacheable portal memory, we need to do > cache flush for enqueue, vdq, buffer release, and management > commands, as well as invalidate and prefetch for the valid bit > of management command response and next index o

Re: [PATCH v3 09/11] x86/xen: use capabilities instead of fake cpuid values for xsave

2017-04-21 Thread Juergen Gross
On 21/04/17 16:24, Boris Ostrovsky wrote: > >> +static bool __init xen_check_xsave(void) >> { >> -unsigned int ax, bx, cx, dx; >> -unsigned int xsave_mask; >> +unsigned int err, eax, edx; >> >> -ax = 1; >> -cx = 0; >> -cpuid(1, &ax, &bx, &cx, &dx); >> +/* Test OSXSAV

[PATCH v1 2/8] ASoC: Intel: Skylake: Use recently introduced uuid_le_cmp_p{p}()

2017-04-21 Thread Andy Shevchenko
Recently introduced helpers take pointers to uuid_{be|le} instead of reference. Using them makes code less ugly. Cc: Liam Girdwood Cc: Mark Brown Cc: Vinod Koul Signed-off-by: Andy Shevchenko --- sound/soc/intel/skylake/skl-pcm.c | 2 +- sound/soc/intel/skylake/skl-sst-utils.c | 4 ++--

Re: [PATCH] drm: fourcc byteorder: brings header file comments in line with reality.

2017-04-21 Thread Ilia Mirkin
On Fri, Apr 21, 2017 at 3:58 AM, Gerd Hoffmann wrote: > While working on graphics support for virtual machines on ppc64 (which > exists in both little and big endian variants) I've figured the comments > for various drm fourcc formats in the header file don't match reality. > > Comments says the R

Re: [PATCH] drm: fourcc byteorder: brings header file comments in line with reality.

2017-04-21 Thread Harry Wentland
Thanks, Christian for adding me. On 2017-04-21 09:27 AM, Christian König wrote: Adding Harry to this mail thread as well, cause is one of the people really affected by this. Christian. Am 21.04.2017 um 15:21 schrieb Christian König: Am 21.04.2017 um 15:12 schrieb Gerd Hoffmann: Hi, "nat

Re: [PATCH] bus: fsl-mc: dpio: fix alter FQ state command

2017-04-21 Thread Dan Carpenter
On Fri, Apr 21, 2017 at 01:50:24PM +, Horia Geantă wrote: > Let me know whether keeping code similar would be preferred or not. > Keeping the code similar to the surrounding is never a valid argument but especially not in staging/. If only 1 line is nice in the whole file, at least that's be

Re: [PATCH 01/11] blk: remove bio_set arg from blk_queue_split()

2017-04-21 Thread Ming Lei
On Thu, Apr 20, 2017 at 1:38 PM, NeilBrown wrote: > blk_queue_split() is always called with the last arg being q->bio_split, > where 'q' is the first arg. > > Also blk_queue_split() sometimes uses the passed-in 'bs' and sometimes uses > q->bio_split. > > This is inconsistent and unnecessary. Remo

Re: [PATCH v2] dmaengine: sun4i: fix invalid argument

2017-04-21 Thread Maxime Ripard
On Fri, Apr 21, 2017 at 10:43:20AM +0200, Mason wrote: > From: Marc Gonzalez > > The "pchans_used" field is an unsigned long array. > > for_each_clear_bit_from() expects an unsigned long pointer, > not an array address. > > $ make C=2 drivers/dma/sun4i-dma.o > CHECK drivers/dma/sun4i-dma.c

Re: [PATCH 10/11] block: remove bio_clone() and all references.

2017-04-21 Thread Ming Lei
On Thu, Apr 20, 2017 at 1:38 PM, NeilBrown wrote: > bio_clone() is no longer used. > Only bio_clone_bioset() or bio_clone_fast(). > This is for the best, as bio_clone() used fs_bio_set, > and filesystems are unlikely to want to use bio_clone(). > > So remove bio_clone() and all references. > This

[PATCH v1 4/8] vfio-mdev: Use recently introduced uuid_le_cmp_p{p}()

2017-04-21 Thread Andy Shevchenko
Recently introduced helpers take pointers to uuid_{be|le} instead of reference. Using them makes code less ugly. Cc: Kirti Wankhede Cc: Alex Williamson Signed-off-by: Andy Shevchenko --- drivers/vfio/mdev/mdev_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/

Re: [patch V2 03/10] timers: Rework idle logic

2017-04-21 Thread Frederic Weisbecker
On Wed, Apr 19, 2017 at 08:50:39AM +0200, Peter Zijlstra wrote: > On Tue, Apr 18, 2017 at 01:11:05PM +0200, Thomas Gleixner wrote: > > Storing next event and determining whether the base is idle can be done in > > __next_timer_interrupt(). > > > > Preparatory patch for new call sites which need t

[PATCH v1 8/8] ACPI: Use recently introduced uuid_le_cmp_p{p}() helpers

2017-04-21 Thread Andy Shevchenko
Recently introduced helpers take pointers to uuid_{be|le} instead of reference. Using them makes code less ugly. Cc: "Rafael J. Wysocki" Signed-off-by: Andy Shevchenko --- drivers/acpi/acpi_extlog.c | 2 +- drivers/acpi/apei/ghes.c | 8 2 files changed, 5 insertions(+), 5 deletions(

Re: [PATCH v5 06/11] mm: thp: check pmd migration entry in common path

2017-04-21 Thread Zi Yan
Anshuman Khandual wrote: > On 04/21/2017 02:17 AM, Zi Yan wrote: >> From: Zi Yan >> >> If one of callers of page migration starts to handle thp, >> memory management code start to see pmd migration entry, so we need >> to prepare for it before enabling. This patch changes various code >> point w

Re: [PATCH] scsi: sas: move scsi_remove_host call into sas_remove_host

2017-04-21 Thread Martin K. Petersen
Johannes, > Move scsi_remove_host call into sas_remove_host and remove it from SAS > HBA drivers, so we don't mess up the ordering. This solves an issue > with double deleting sysfs entries that was introduced by the change > of sysfs behaviour from commit bcdde7e ("sysfs: make > __sysfs_remove_d

Re: [PATCH v2 2/2] dmaengine: Add DW AXI DMAC driver

2017-04-21 Thread Andy Shevchenko
On Fri, 2017-04-21 at 14:29 +, Eugeniy Paltsev wrote: > On Tue, 2017-04-18 at 15:31 +0300, Andy Shevchenko wrote: > > On Fri, 2017-04-07 at 17:04 +0300, Eugeniy Paltsev wrote: > > > This patch adds support for the DW AXI DMAC controller. > > > > > > +#include > > > > Are you sure you still

Re: [PATCH 1/2 v4] video: fbdev: imxfb: support AUS mode

2017-04-21 Thread Bartlomiej Zolnierkiewicz
On Friday, April 21, 2017 12:29:08 PM Martin Kaiser wrote: > Some displays require setting AUS mode in the LDCD AUS Mode Control > Register to work with the imxfb driver. Like the value of the Panel > Configuration Register, the AUS mode setting depends on the display > mode. > > Allow setting AUS

[PATCH v5 1/6] mtd: dataflash: Replace C99 types with their kernel counterparts

2017-04-21 Thread Andrey Smirnov
No functional change intended. Cc: cphe...@gmail.com Cc: David Woodhouse Cc: Brian Norris Cc: Boris Brezillon Cc: Marek Vasut Cc: Richard Weinberger Cc: Cyrille Pitchen Cc: linux-kernel@vger.kernel.org Acked-by: Marek Vasut Signed-off-by: Andrey Smirnov --- No changes since [v3], [v4] Ch

Re: [PATCH v5 08/11] mm: hwpoison: soft offline supports thp migration

2017-04-21 Thread Zi Yan
Anshuman Khandual wrote: > On 04/21/2017 02:17 AM, Zi Yan wrote: >> From: Naoya Horiguchi >> >> This patch enables thp migration for soft offline. >> >> Signed-off-by: Naoya Horiguchi >> >> ChangeLog: v1 -> v5: >> - fix page isolation counting error >> >> Signed-off-by: Zi Yan >> --- >> mm/me

<    1   2   3   4   5   6   7   8   9   >